Fix issues pointed out by ruff
Signed-off-by: Alfred Wingate <parona@protonmail.com>
This commit is contained in:
@ -29,8 +29,8 @@ from portage.exception import AmbiguousPackageName
|
||||
from portage.output import green, turquoise, white, yellow
|
||||
|
||||
from euscan import CONFIG, output
|
||||
from euscan.out import progress_bar
|
||||
from euscan._version import __version__
|
||||
from euscan.out import progress_bar
|
||||
|
||||
# Globals
|
||||
isatty = os.environ.get("TERM") != "dumb" and sys.stdout.isatty()
|
||||
@ -75,7 +75,7 @@ def print_usage(_error=None, help=None):
|
||||
if _error:
|
||||
out = sys.stderr
|
||||
|
||||
if not _error in (
|
||||
if _error not in (
|
||||
"global-options",
|
||||
"packages",
|
||||
):
|
||||
@ -284,7 +284,7 @@ def parse_args():
|
||||
# apply getopts to command line, show partial help on failure
|
||||
try:
|
||||
opts, args = getopt.getopt(sys.argv[1:], short_opts, long_opts)
|
||||
except:
|
||||
except getopt.GetoptError:
|
||||
raise ParseArgsException(opts_mode + "-options")
|
||||
|
||||
# set options accordingly
|
||||
|
Reference in New Issue
Block a user