mirror of
https://github.com/freedomofpress/dangerzone.git
synced 2025-04-29 10:12:38 +02:00
sort imports with isort linter
This commit is contained in:
parent
90a51a0004
commit
4d8e4c53e3
18 changed files with 69 additions and 56 deletions
|
@ -12,12 +12,12 @@ pixels_to_pdf:
|
||||||
- 95%-100%: Compress the final PDF
|
- 95%-100%: Compress the final PDF
|
||||||
"""
|
"""
|
||||||
|
|
||||||
import sys
|
|
||||||
import subprocess
|
|
||||||
import glob
|
import glob
|
||||||
import os
|
|
||||||
import json
|
import json
|
||||||
|
import os
|
||||||
import shutil
|
import shutil
|
||||||
|
import subprocess
|
||||||
|
import sys
|
||||||
|
|
||||||
import magic
|
import magic
|
||||||
from PIL import Image
|
from PIL import Image
|
||||||
|
|
|
@ -1,13 +1,14 @@
|
||||||
|
import json
|
||||||
|
import logging
|
||||||
import os
|
import os
|
||||||
import sys
|
import sys
|
||||||
import json
|
|
||||||
import click
|
import click
|
||||||
import logging
|
|
||||||
from colorama import Fore, Style
|
from colorama import Fore, Style
|
||||||
|
|
||||||
from .global_common import GlobalCommon
|
|
||||||
from .common import Common
|
from .common import Common
|
||||||
from .container import convert
|
from .container import convert
|
||||||
|
from .global_common import GlobalCommon
|
||||||
|
|
||||||
|
|
||||||
def print_header(s):
|
def print_header(s):
|
||||||
|
|
|
@ -1,7 +1,8 @@
|
||||||
import os
|
import os
|
||||||
import stat
|
|
||||||
import platform
|
import platform
|
||||||
|
import stat
|
||||||
import tempfile
|
import tempfile
|
||||||
|
|
||||||
import appdirs
|
import appdirs
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -1,10 +1,11 @@
|
||||||
import platform
|
|
||||||
import subprocess
|
|
||||||
import pipes
|
|
||||||
import shutil
|
|
||||||
import logging
|
import logging
|
||||||
import os
|
import os
|
||||||
|
import pipes
|
||||||
|
import platform
|
||||||
|
import shutil
|
||||||
|
import subprocess
|
||||||
import tempfile
|
import tempfile
|
||||||
|
|
||||||
import appdirs
|
import appdirs
|
||||||
|
|
||||||
# What container tech is used for this platform?
|
# What container tech is used for this platform?
|
||||||
|
|
|
@ -1,17 +1,20 @@
|
||||||
import sys
|
import gzip
|
||||||
import appdirs
|
import inspect
|
||||||
|
import json
|
||||||
|
import logging
|
||||||
|
import os
|
||||||
import pathlib
|
import pathlib
|
||||||
import platform
|
import platform
|
||||||
import subprocess
|
|
||||||
import shutil
|
import shutil
|
||||||
import json
|
import subprocess
|
||||||
import gzip
|
import sys
|
||||||
import colorama
|
|
||||||
from colorama import Fore, Back, Style
|
import appdirs
|
||||||
import logging
|
import colorama
|
||||||
|
from colorama import Back, Fore, Style
|
||||||
|
|
||||||
from .settings import Settings
|
|
||||||
from .container import convert
|
from .container import convert
|
||||||
|
from .settings import Settings
|
||||||
|
|
||||||
log = logging.getLogger(__name__)
|
log = logging.getLogger(__name__)
|
||||||
|
|
||||||
|
|
|
@ -1,16 +1,17 @@
|
||||||
import os
|
|
||||||
import sys
|
|
||||||
import signal
|
|
||||||
import platform
|
|
||||||
import click
|
|
||||||
import uuid
|
|
||||||
import logging
|
import logging
|
||||||
|
import os
|
||||||
|
import platform
|
||||||
|
import signal
|
||||||
|
import sys
|
||||||
|
import uuid
|
||||||
|
|
||||||
|
import click
|
||||||
from PySide2 import QtCore, QtWidgets
|
from PySide2 import QtCore, QtWidgets
|
||||||
|
|
||||||
|
from ..global_common import GlobalCommon
|
||||||
from .common import GuiCommon
|
from .common import GuiCommon
|
||||||
from .main_window import MainWindow
|
from .main_window import MainWindow
|
||||||
from .systray import SysTray
|
from .systray import SysTray
|
||||||
from ..global_common import GlobalCommon
|
|
||||||
|
|
||||||
|
|
||||||
# For some reason, Dangerzone segfaults if I inherit from QApplication directly, so instead
|
# For some reason, Dangerzone segfaults if I inherit from QApplication directly, so instead
|
||||||
|
|
|
@ -1,11 +1,12 @@
|
||||||
import os
|
|
||||||
import platform
|
|
||||||
import subprocess
|
|
||||||
import shlex
|
|
||||||
import pipes
|
|
||||||
from PySide2 import QtCore, QtGui, QtWidgets
|
|
||||||
from colorama import Fore
|
|
||||||
import logging
|
import logging
|
||||||
|
import os
|
||||||
|
import pipes
|
||||||
|
import platform
|
||||||
|
import shlex
|
||||||
|
import subprocess
|
||||||
|
|
||||||
|
from colorama import Fore
|
||||||
|
from PySide2 import QtCore, QtGui, QtWidgets
|
||||||
|
|
||||||
if platform.system() == "Darwin":
|
if platform.system() == "Darwin":
|
||||||
import plistlib
|
import plistlib
|
||||||
|
|
|
@ -1,12 +1,13 @@
|
||||||
|
import json
|
||||||
|
import logging
|
||||||
import os
|
import os
|
||||||
import platform
|
import platform
|
||||||
import tempfile
|
|
||||||
import subprocess
|
|
||||||
import json
|
|
||||||
import shutil
|
import shutil
|
||||||
import logging
|
import subprocess
|
||||||
|
import tempfile
|
||||||
|
|
||||||
|
from colorama import Fore, Style
|
||||||
from PySide2 import QtCore, QtGui, QtWidgets
|
from PySide2 import QtCore, QtGui, QtWidgets
|
||||||
from colorama import Style, Fore
|
|
||||||
|
|
||||||
from ..common import Common
|
from ..common import Common
|
||||||
from ..container import convert
|
from ..container import convert
|
||||||
|
|
|
@ -1,4 +1,5 @@
|
||||||
import platform
|
import platform
|
||||||
|
|
||||||
from PySide2 import QtWidgets
|
from PySide2 import QtWidgets
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -1,7 +1,6 @@
|
||||||
import os
|
|
||||||
import json
|
import json
|
||||||
import appdirs
|
|
||||||
import logging
|
import logging
|
||||||
|
import os
|
||||||
|
|
||||||
log = logging.getLogger(__name__)
|
log = logging.getLogger(__name__)
|
||||||
|
|
||||||
|
|
|
@ -2,7 +2,8 @@
|
||||||
# -*- coding: utf-8 -*-
|
# -*- coding: utf-8 -*-
|
||||||
|
|
||||||
# Load dangerzone module and resources from the source code tree
|
# Load dangerzone module and resources from the source code tree
|
||||||
import os, sys
|
import os
|
||||||
|
import sys
|
||||||
|
|
||||||
sys.path.insert(0, os.path.dirname(os.path.dirname(os.path.abspath(__file__))))
|
sys.path.insert(0, os.path.dirname(os.path.dirname(os.path.abspath(__file__))))
|
||||||
sys.dangerzone_dev = True
|
sys.dangerzone_dev = True
|
||||||
|
|
|
@ -1,10 +1,10 @@
|
||||||
#!/usr/bin/env python3
|
#!/usr/bin/env python3
|
||||||
# -*- coding: utf-8 -*-
|
# -*- coding: utf-8 -*-
|
||||||
import os
|
|
||||||
import sys
|
|
||||||
import inspect
|
import inspect
|
||||||
import subprocess
|
import os
|
||||||
import shutil
|
import shutil
|
||||||
|
import subprocess
|
||||||
|
import sys
|
||||||
|
|
||||||
root = os.path.dirname(
|
root = os.path.dirname(
|
||||||
os.path.dirname(
|
os.path.dirname(
|
||||||
|
|
|
@ -1,11 +1,10 @@
|
||||||
#!/usr/bin/env python3
|
#!/usr/bin/env python3
|
||||||
# -*- coding: utf-8 -*-
|
# -*- coding: utf-8 -*-
|
||||||
import os
|
|
||||||
import sys
|
|
||||||
import inspect
|
import inspect
|
||||||
import subprocess
|
import os
|
||||||
import shutil
|
import shutil
|
||||||
|
import subprocess
|
||||||
|
import sys
|
||||||
|
|
||||||
root = os.path.dirname(
|
root = os.path.dirname(
|
||||||
os.path.dirname(
|
os.path.dirname(
|
||||||
|
|
|
@ -1,12 +1,12 @@
|
||||||
#!/usr/bin/env python3
|
#!/usr/bin/env python3
|
||||||
# -*- coding: utf-8 -*-
|
# -*- coding: utf-8 -*-
|
||||||
import os
|
|
||||||
import inspect
|
|
||||||
import subprocess
|
|
||||||
import shutil
|
|
||||||
import argparse
|
import argparse
|
||||||
import glob
|
import glob
|
||||||
|
import inspect
|
||||||
import itertools
|
import itertools
|
||||||
|
import os
|
||||||
|
import shutil
|
||||||
|
import subprocess
|
||||||
|
|
||||||
root = os.path.dirname(
|
root = os.path.dirname(
|
||||||
os.path.dirname(
|
os.path.dirname(
|
||||||
|
|
|
@ -5,7 +5,9 @@
|
||||||
# to open in macOS when double-clicking, not just when running from the terminal or opening
|
# to open in macOS when double-clicking, not just when running from the terminal or opening
|
||||||
# with a file.
|
# with a file.
|
||||||
import os
|
import os
|
||||||
|
|
||||||
os.environ["LANG"] = "en_US.UTF-8"
|
os.environ["LANG"] = "en_US.UTF-8"
|
||||||
|
|
||||||
import dangerzone
|
import dangerzone
|
||||||
|
|
||||||
dangerzone.main()
|
dangerzone.main()
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
import subprocess
|
|
||||||
import gzip
|
import gzip
|
||||||
import os
|
import os
|
||||||
|
import subprocess
|
||||||
|
|
||||||
|
|
||||||
def main():
|
def main():
|
||||||
|
|
|
@ -1,6 +1,7 @@
|
||||||
#!/usr/bin/env python3
|
#!/usr/bin/env python3
|
||||||
import os
|
import os
|
||||||
from cx_Freeze import setup, Executable
|
|
||||||
|
from cx_Freeze import Executable, setup
|
||||||
|
|
||||||
with open("share/version.txt") as f:
|
with open("share/version.txt") as f:
|
||||||
version = f.read().strip()
|
version = f.read().strip()
|
||||||
|
|
3
setup.py
3
setup.py
|
@ -1,8 +1,9 @@
|
||||||
#!/usr/bin/env python3
|
#!/usr/bin/env python3
|
||||||
import setuptools
|
|
||||||
import os
|
import os
|
||||||
import sys
|
import sys
|
||||||
|
|
||||||
|
import setuptools
|
||||||
|
|
||||||
with open("share/version.txt") as f:
|
with open("share/version.txt") as f:
|
||||||
version = f.read().strip()
|
version = f.read().strip()
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue