Run isort over the source

This commit is contained in:
Luke Murphy 2019-05-13 23:39:10 +02:00
parent b94dbff216
commit 1c0dc3f904
No known key found for this signature in database
GPG key ID: 5E2EF5A63E3718CC
33 changed files with 38 additions and 54 deletions

View file

@ -5,7 +5,6 @@ import subprocess
from borgmatic.borg import extract
from borgmatic.logger import get_logger
DEFAULT_CHECKS = ('repository', 'archives')
DEFAULT_PREFIX = '{hostname}-'

View file

@ -7,7 +7,6 @@ import tempfile
from borgmatic.borg.execute import execute_command
from borgmatic.logger import get_logger
logger = get_logger(__name__)

View file

@ -2,7 +2,6 @@ import subprocess
from borgmatic.logger import get_logger
logger = get_logger(__name__)

View file

@ -1,10 +1,9 @@
import logging
import sys
import subprocess
import sys
from borgmatic.logger import get_logger
logger = get_logger(__name__)

View file

@ -3,7 +3,6 @@ import logging
from borgmatic.borg.execute import execute_command
from borgmatic.logger import get_logger
logger = get_logger(__name__)

View file

@ -3,7 +3,6 @@ import logging
from borgmatic.borg.execute import execute_command
from borgmatic.logger import get_logger
logger = get_logger(__name__)

View file

@ -3,7 +3,6 @@ import subprocess
from borgmatic.logger import get_logger
logger = get_logger(__name__)

View file

@ -1,31 +1,28 @@
from argparse import ArgumentParser
import collections
import colorama
import json
import logging
import os
from subprocess import CalledProcessError
import sys
from argparse import ArgumentParser
from subprocess import CalledProcessError
import colorama
import pkg_resources
from borgmatic.borg import (
check as borg_check,
create as borg_create,
environment as borg_environment,
prune as borg_prune,
extract as borg_extract,
list as borg_list,
info as borg_info,
init as borg_init,
)
from borgmatic.borg import check as borg_check
from borgmatic.borg import create as borg_create
from borgmatic.borg import environment as borg_environment
from borgmatic.borg import extract as borg_extract
from borgmatic.borg import info as borg_info
from borgmatic.borg import init as borg_init
from borgmatic.borg import list as borg_list
from borgmatic.borg import prune as borg_prune
from borgmatic.commands import hook
from borgmatic.config import checks, collect, convert, validate
from borgmatic.logger import should_do_markup, get_logger
from borgmatic.logger import get_logger, should_do_markup
from borgmatic.signals import configure_signals
from borgmatic.verbosity import verbosity_to_log_level
logger = get_logger(__name__)
LEGACY_CONFIG_PATH = '/etc/borgmatic/config'

View file

@ -1,13 +1,12 @@
from argparse import ArgumentParser
import os
import sys
import textwrap
from argparse import ArgumentParser
from ruamel import yaml
from borgmatic.config import convert, generate, legacy, validate
DEFAULT_SOURCE_CONFIG_FILENAME = '/etc/borgmatic/config'
DEFAULT_SOURCE_EXCLUDES_FILENAME = '/etc/borgmatic/excludes'
DEFAULT_DESTINATION_CONFIG_FILENAME = '/etc/borgmatic/config.yaml'

View file

@ -1,9 +1,8 @@
from argparse import ArgumentParser
import sys
from argparse import ArgumentParser
from borgmatic.config import generate, validate
DEFAULT_DESTINATION_CONFIG_FILENAME = '/etc/borgmatic/config.yaml'

View file

@ -2,7 +2,6 @@ import subprocess
from borgmatic.logger import get_logger
logger = get_logger(__name__)

View file

@ -1,6 +1,6 @@
from argparse import ArgumentParser
import sys
import logging
import sys
from argparse import ArgumentParser
from borgmatic.config import collect, validate
from borgmatic.logger import get_logger

View file

@ -2,7 +2,6 @@ import os
from ruamel import yaml
INDENT = 4

View file

@ -1,7 +1,6 @@
from collections import OrderedDict, namedtuple
from configparser import RawConfigParser
Section_format = namedtuple('Section_format', ('name', 'options'))
Config_option = namedtuple('Config_option', ('name', 'value_type', 'required'))

View file

@ -4,7 +4,6 @@ import ruamel.yaml
from borgmatic.logger import get_logger
logger = get_logger(__name__)

View file

@ -8,7 +8,6 @@ import ruamel.yaml
from borgmatic.config import load
from borgmatic.logger import get_logger
logger = get_logger(__name__)

View file

@ -1,6 +1,5 @@
import logging
VERBOSITY_WARNING = 0
VERBOSITY_SOME = 1
VERBOSITY_LOTS = 2

View file

@ -1,5 +1,4 @@
from setuptools import setup, find_packages
from setuptools import find_packages, setup
VERSION = '1.3.4.dev0'

View file

@ -1,7 +1,7 @@
import subprocess
from flexmock import flexmock
import pytest
from flexmock import flexmock
from borgmatic.commands import borgmatic as module

View file

@ -1,7 +1,7 @@
import os
from flexmock import flexmock
import pytest
from flexmock import flexmock
from borgmatic.commands import convert_config as module

View file

@ -1,9 +1,9 @@
from io import StringIO
import os
import sys
from io import StringIO
from flexmock import flexmock
import pytest
from flexmock import flexmock
from borgmatic.config import generate as module

View file

@ -1,7 +1,6 @@
from io import StringIO
from collections import OrderedDict
import string
from collections import OrderedDict
from io import StringIO
from borgmatic.config import legacy as module

View file

@ -2,8 +2,8 @@ import io
import string
import sys
from flexmock import flexmock
import pytest
from flexmock import flexmock
from borgmatic.config import validate as module

View file

@ -1,11 +1,12 @@
from subprocess import STDOUT
import logging
import sys
from subprocess import STDOUT
from flexmock import flexmock
import pytest
from flexmock import flexmock
from borgmatic.borg import check as module
from ..test_verbosity import insert_logging_mock

View file

@ -3,6 +3,7 @@ import logging
from flexmock import flexmock
from borgmatic.borg import create as module
from ..test_verbosity import insert_logging_mock

View file

@ -1,4 +1,5 @@
from flexmock import flexmock
from borgmatic.borg import execute as module

View file

@ -4,6 +4,7 @@ import sys
from flexmock import flexmock
from borgmatic.borg import extract as module
from ..test_verbosity import insert_logging_mock

View file

@ -3,8 +3,8 @@ import logging
from flexmock import flexmock
from borgmatic.borg import info as module
from ..test_verbosity import insert_logging_mock
from ..test_verbosity import insert_logging_mock
INFO_COMMAND = ('borg', 'info', 'repo')

View file

@ -3,8 +3,8 @@ import logging
from flexmock import flexmock
from borgmatic.borg import init as module
from ..test_verbosity import insert_logging_mock
from ..test_verbosity import insert_logging_mock
INFO_REPOSITORY_EXISTS_RESPONSE_CODE = 0
INFO_REPOSITORY_NOT_FOUND_RESPONSE_CODE = 2

View file

@ -3,8 +3,8 @@ import logging
from flexmock import flexmock
from borgmatic.borg import list as module
from ..test_verbosity import insert_logging_mock
from ..test_verbosity import insert_logging_mock
LIST_COMMAND = ('borg', 'list', 'repo')

View file

@ -4,6 +4,7 @@ from collections import OrderedDict
from flexmock import flexmock
from borgmatic.borg import prune as module
from ..test_verbosity import insert_logging_mock

View file

@ -1,12 +1,11 @@
from collections import defaultdict, OrderedDict, namedtuple
import os
from collections import OrderedDict, defaultdict, namedtuple
from flexmock import flexmock
import pytest
from flexmock import flexmock
from borgmatic.config import convert as module
Parsed_config = namedtuple('Parsed_config', ('location', 'storage', 'retention', 'consistency'))

View file

@ -1,7 +1,7 @@
from collections import OrderedDict
from flexmock import flexmock
import pytest
from flexmock import flexmock
from borgmatic.config import legacy as module