%PDF- %PDF-
Mini Shell

Mini Shell

Direktori : /usr/lib/python2.7/site-packages/salt/modules/
Upload File :
Create Path :
Current File : //usr/lib/python2.7/site-packages/salt/modules/wordpress.pyc

�
���^c@@s�dZddlmZmZmZddlZddlZddlm	Z	ej
dd�Zd�Zd�Z
d	�Zd
�Zd�Zd�Zdd
�Zd�ZdS(ud
This module is used to manage Wordpress installations

:depends: wp binary from http://wp-cli.org/
i(tabsolute_importtprint_functiontunicode_literalsN(tmapuPluginuname status update versinocC@stjjjd�rtStS(Nuwp(tsalttutilstpathtwhichtTruetFalse(((s:/usr/lib/python2.7/site-packages/salt/modules/wordpress.pyt__virtual__scC@s
t|�S(N(tPlugin(tstuff((s:/usr/lib/python2.7/site-packages/salt/modules/wordpress.pyt_get_pluginsscC@s|g}tddj|�d|�}x1|jd�dD]}|j|jd��q9Wgtt|�D]}|j^qiS(u
    List plugins in an installed wordpress path

    path
        path to wordpress install location

    user
        user to run the command as

    CLI Example:

    .. code-block:: bash

        salt '*' wordpress.list_plugins /var/www/html apache
    u	cmd.shelluwp --path={0} plugin listtrunasu
iu	(t__salt__tformattsplittappendRR
t__dict__(Rtusertrettresptlinetplugin((s:/usr/lib/python2.7/site-packages/salt/modules/wordpress.pytlist_pluginsscC@s�i|d6}tddj||�d|�jd�}xf|D]^}d|krq|jd�dj�|d	<q?d
|kr?|jd�dj�|d<q?q?W|S(uF
    Show a plugin in a wordpress install and check if it is installed

    name
        Wordpress plugin name

    path
        path to wordpress install location

    user
        user to run the command as

    CLI Example:

    .. code-block:: bash

        salt '*' wordpress.show_plugin HyperDB /var/www/html apache
    unameu	cmd.shelluwp --path={0} plugin status {1}Ru
uStatusu i����ustatusuVersionuversion(RRRtlower(tnameRRRRR((s:/usr/lib/python2.7/site-packages/salt/modules/wordpress.pytshow_plugin6s

 $cC@s|t|||�}|ddkr&dStddj||�d|�}d|krXtSt|||�ddkrxtStS(u
    Activate a wordpress plugin

    name
        Wordpress plugin name

    path
        path to wordpress install location

    user
        user to run the command as

    CLI Example:

    .. code-block:: bash

        salt '*' wordpress.activate HyperDB /var/www/html apache
    ustatusuactiveu	cmd.shellu!wp --path={0} plugin activate {1}RuSuccessN(RtNoneRRRR	(RRRtcheckR((s:/usr/lib/python2.7/site-packages/salt/modules/wordpress.pytactivateUscC@s|t|||�}|ddkr&dStddj||�d|�}d|krXtSt|||�ddkrxtStS(u!
    Deactivate a wordpress plugin

    name
        Wordpress plugin name

    path
        path to wordpress install location

    user
        user to run the command as

    CLI Example:

    .. code-block:: bash

        salt '*' wordpress.deactivate HyperDB /var/www/html apache
    ustatusuinactiveu	cmd.shellu#wp --path={0} plugin deactivate {1}RuSuccessN(RRRRRR	(RRRRR((s:/usr/lib/python2.7/site-packages/salt/modules/wordpress.pyt
deactivatevscC@s3tddj|�d|�}|dkr/tStS(u�
    Check if wordpress is installed and setup

    path
        path to wordpress install location

    user
        user to run the command as

    CLI Example:

    .. code-block:: bash

        salt '*' wordpress.is_installed /var/www/html apache
    ucmd.retcodeuwp --path={0} core is-installedRi(RRRR	(RRtretcode((s:/usr/lib/python2.7/site-packages/salt/modules/wordpress.pytis_installed�scC@sBtddj||||||�d|�}|dkr>tStS(u�
    Run the initial setup functions for a wordpress install

    path
        path to wordpress install location

    user
        user to run the command as

    admin_user
        Username for the Administrative user for the wordpress install

    admin_password
        Initial Password for the Administrative user for the wordpress install

    admin_email
        Email for the Administrative user for the wordpress install

    title
        Title of the wordpress website for the wordpress install

    url
        Url for the wordpress install

    CLI Example:

    .. code-block:: bash

        salt '*' wordpress.install /var/www/html apache dwallace password123             dwallace@example.com "Daniel's Awesome Blog" https://blog.dwallace.com
    ucmd.retcodeulwp --path={0} core install --title="{1}" --admin_user={2} --admin_password='{3}' --admin_email={4} --url={5}Ri(RRRR	(RRt
admin_usertadmin_passwordtadmin_emailttitleturlR!((s:/usr/lib/python2.7/site-packages/salt/modules/wordpress.pytinstall�s 		(t__doc__t
__future__RRRtcollectionstsalt.utils.pathRtsalt.ext.six.movesRt
namedtupleRR
R
RRRR RR"R((((s:/usr/lib/python2.7/site-packages/salt/modules/wordpress.pyt<module>s					!	!

Zerion Mini Shell 1.0