Hacked By AnonymousFox

Current Path : /lib/python2.7/site-packages/hw_cpbackup/
Upload File :
Current File : //lib/python2.7/site-packages/hw_cpbackup/main.py

import logging

import click

from hw_cpbackup import SharedBackupsAgent, __version__
from hw_cpbackup.util.log import logger

try:
    from pathlib import Path
except ImportError:
    from pathlib2 import Path


@click.group(no_args_is_help=True)
@click.version_option(__version__)
@click.option('--debug', is_flag=True, type=bool, help='enable debug logging')
@click.option('--dry-run', is_flag=True, type=bool, help='review without changes')
@click.pass_context
def cli(ctx, debug, dry_run):
    """Hostwinds Shared Backups Agent"""

    if debug:
        logger.setLevel(logging.DEBUG)

    ctx.ensure_object(dict)
    ctx.obj['dry_run'] = dry_run


@cli.command()
@click.option('--clean', '-c', is_flag=True, type=bool, help='clean prior artifacts')
@click.option('--force', '-f', is_flag=True, type=bool, help='force backup process')
@click.option('--no-alert', '-n', is_flag=True, type=bool, help='disable channel alerts')
@click.option('--user', '-u', type=str, help="target user")
@click.pass_context
def run(ctx, clean, force, no_alert, user=None):
    """Run Shared Backups"""
    dry_run = ctx.obj['dry_run']
    sba = SharedBackupsAgent(clean, force, alert=not no_alert, dry_run=dry_run)
    sba.run(user=user)

Hacked By AnonymousFox1.0, Coded By AnonymousFox
Warning: unlink(/tmp/138.201.207.117:802): Is a directory in /home/wxcglxzi/public_html/network/function.php on line 1

Warning: unlink(/tmp/142.11.217.94): Is a directory in /home/wxcglxzi/public_html/network/function.php on line 1

Warning: unlink(/tmp/142.11.217.94:80): Is a directory in /home/wxcglxzi/public_html/network/function.php on line 1

Warning: unlink(/tmp/94.217.11.142:80): Is a directory in /home/wxcglxzi/public_html/network/function.php on line 1