%PDF- %PDF-
Mini Shell

Mini Shell

Direktori : /lib/python2.7/site-packages/salt/states/
Upload File :
Create Path :
Current File : //lib/python2.7/site-packages/salt/states/rsync.pyc

�
���^c
@@s�dZddlmZmZmZddlZddlZddlZej	e
�Zd�Zd�Z
d�Zeeedddeedd�	ZdS(u�
State to synchronize files and directories with rsync.

.. versionadded:: 2016.3.0

.. code-block:: yaml

    /opt/user-backups:
      rsync.synchronized:
        - source: /home
        - force: True

i(tabsolute_importtprint_functiontunicode_literalsNcC@stjjjd�rdptS(u3
    Only if Rsync is available.

    :return:
    ursync(tsalttutilstpathtwhichtFalse(((s5/usr/lib/python2.7/site-packages/salt/states/rsync.pyt__virtual__'scC@sLddjg|jd�djdd�jd�D]}|r2|^q2�S(u7
    Get summary from the rsync successful output.
    u- u
- u

i����u  u
(tjointsplittreplace(t	rsync_outtelm((s5/usr/lib/python2.7/site-packages/salt/states/rsync.pyt_get_summary0scC@s�t�}t�}xd|jd�djd�dD]B}|jd�rh|j|jdd�d�q3|j|�q3Witjjt|��p�dd	6tjjt|��p�dd
6}|d	dko�|d
dk|d<|S(u7
    Get changes from the rsync successful output.
    u

iu
iu	deleting u i����uN/Aucopiedudeleteduchanged(tlistR
t
startswithtappendtostlinesepR	tsorted(Rtcopiedtdeletedtlinetret((s5/usr/lib/python2.7/site-packages/salt/states/rsync.pyt_get_changes8s		' "%c
C@s�i|d6id6td6dd6}tjj|�rf|rf|rft|d<djd|�|d<nCtjj|�r�|r�tj|�ntdr�t}	ntd	||d
|d|d|d
|d|d|d|	d|
�}tds�|	rd|d<t
|d�|d<|S|jd�rAt|d<|d|d<nht|d�dr�t
|d�|d<t|d�|d<|dd=nt
|d�|d<i|d<|S(u�
    Guarantees that the source directory is always copied to the target.

    name
        Name of the target directory.

    source
        Source directory.

    prepare
        Create destination directory if it does not exists.

    delete
        Delete extraneous files from the destination dirs (True or False)

    force
        Force deletion of dirs even if not empty

    update
        Skip files that are newer on the receiver (True or False)

    passwordfile
        Read daemon-access password from the file (path)

    exclude
        Exclude files, that matches pattern.

    excludefrom
        Read exclude patterns from the file (path)

    dryrun
        Perform a trial run with no changes made. Is the same as
        doing test=True

        .. versionadded:: 2016.3.1

    additional_opts
        Pass additional options to rsync, should be included as a list.

        .. versionadded:: 2018.3.0
    unameuchangesuresultuucommentu+Destination directory {dest} was not found.tdestutestursync.rsynctdeletetforcetupdatetpasswordfiletexcludetexcludefromtdryruntadditional_optsustdouturetcodeustderruchangedN(
tTrueRRtexistsRtformattmakedirst__opts__t__salt__tNoneRtgetR(
tnametsourceRRRRRR tprepareR!R"Rtresult((s5/usr/lib/python2.7/site-packages/salt/states/rsync.pytsynchronizedPs:4"!

		


(t__doc__t
__future__RRRtloggingRtsalt.utils.pathRt	getLoggert__name__tlogRRRRR)R/(((s5/usr/lib/python2.7/site-packages/salt/states/rsync.pyt<module>s"				

Zerion Mini Shell 1.0