make: Miscellaneous minor fixes and improvements #58
60 changed files with 115 additions and 70 deletions
|
|
@ -17,6 +17,9 @@
|
|||
|
||||
[tool.isort]
|
||||
|
||||
multi_line_output = 3
|
||||
line_length = 88
|
||||
lines_after_imports = 1
|
||||
lines_between_sections = 1
|
||||
lines_between_types = 1
|
||||
|
||||
|
|
|
|||
|
|
@ -505,7 +505,8 @@ ifeq ($(CREATE_PKG_CONFIG),true)
|
|||
BUILD_PKG_CONFIGDIR = $(TOPDIR)/make
|
||||
endif
|
||||
LOCAL_PKG_CONFIG = $(PROJECT).pc
|
||||
BUILD_PKG_CONFIG = $(BUILD_PKG_CONFIGDIR)/$(LOCAL_PKG_CONFIG)
|
||||
# As of now, this is not used by any downstream project, so disable it to reduce complexity.
|
||||
#BUILD_PKG_CONFIG = $(BUILD_PKG_CONFIGDIR)/$(LOCAL_PKG_CONFIG)
|
||||
INSTALLED_PKG_CONFIG = $(addprefix $(INSTALL_PKG_CONFIGDIR)/,$(PKG_CONFIG))
|
||||
endif
|
||||
|
||||
|
|
|
|||
|
|
@ -67,7 +67,7 @@ JWB_SCRIPT_DIR := $(firstword $(wildcard $(JWBDIR)/scripts $(JWBDIR
|
|||
|
||||
include $(JWBDIR)/make/py-version.mk
|
||||
|
||||
JW_PKG_PY = $(PYTHON) $(JWB_SCRIPT_DIR)/jw-pkg.py -p $(PROJECTS_DIR) -t $(TOPDIR) --topdir-format absolute $(JW_PKG_PY_EXTRA_OPTS)
|
||||
JW_PKG_PY = $(PYTHON) $(JWB_SCRIPT_DIR)/jw-pkg.py -p $(PROJECTS_DIR) -t $(TOPDIR) $(JW_PKG_PY_EXTRA_OPTS)
|
||||
|
||||
# -- product
|
||||
|
||||
|
|
|
|||
|
|
@ -309,6 +309,8 @@ pull-all: purge git-get git-pull-all
|
|||
|
||||
diff-all diff: $(SSH_WRAPPER_SH)
|
||||
$(PGIT_SH) --porcelain diff
|
||||
diff-projects:
|
||||
PGIT_SH_PROJECTS="$(patsubst %/.git,%,$(wildcard $(addsuffix /.git,$(shell make -s build-order))))" $(PGIT_SH) --porcelain diff
|
||||
|
||||
get-official: git-get-official
|
||||
get-maintainer: git-get-maintainer
|
||||
|
|
|
|||
|
|
@ -29,6 +29,10 @@ ifndef PY_CHECK_RUFF
|
|||
endif
|
||||
endif
|
||||
|
||||
ifndef PY_CHECK_ISORT
|
||||
PY_CHECK_ISORT := $(firstword $(wildcard /usr/bin/isort))
|
||||
endif
|
||||
|
||||
ifndef PY_CHECK_YAPF
|
||||
PY_CHECK_YAPF := $(firstword $(wildcard /usr/bin/yapf /usr/bin/yapf3))
|
||||
endif
|
||||
|
|
@ -67,6 +71,9 @@ endif
|
|||
py-format:
|
||||
find . -type f -name '*.py' -print0 | \
|
||||
xargs -0 sed -i -E '1{/^# -\*- coding: utf-8 -\*-$$/{:a;N;/\n[[:space:]]*$$/ba;s/^# -\*- coding: utf-8 -\*-\n([[:space:]]*\n)*/ /;s/^ //}}'
|
||||
ifneq ($(PY_CHECK_ISORT),)
|
||||
$(PY_CHECK_ISORT) $(PY_CHECK_ROOTS)
|
||||
endif
|
||||
ifneq ($(PY_CHECK_YAPF),)
|
||||
$(PY_CHECK_YAPF) --in-place --recursive $(PY_CHECK_ROOTS)
|
||||
endif
|
||||
|
|
|
|||
|
|
@ -10,7 +10,7 @@ import sys
|
|||
|
||||
from enum import Enum, auto
|
||||
from functools import cache
|
||||
from typing import Any, cast, override, TYPE_CHECKING
|
||||
from typing import TYPE_CHECKING, Any, cast, override
|
||||
|
||||
from .lib.App import App as Base
|
||||
from .lib.Distro import Distro
|
||||
|
|
@ -19,8 +19,8 @@ from .lib.ProjectConf import ProjectConf
|
|||
|
||||
if TYPE_CHECKING:
|
||||
import argparse
|
||||
from argparse import ArgumentParser
|
||||
|
||||
from argparse import ArgumentParser
|
||||
from typing import TypeAlias
|
||||
|
||||
from .lib.ExecContext import ExecContext
|
||||
|
|
|
|||
|
|
@ -1,4 +1,5 @@
|
|||
from typing import override
|
||||
|
||||
from .App import App
|
||||
from .lib.Cmd import Cmd as Base
|
||||
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
from __future__ import annotations
|
||||
|
||||
from typing import override, TYPE_CHECKING
|
||||
from typing import TYPE_CHECKING, override
|
||||
|
||||
from ..App import App as Parent
|
||||
from ..CmdBase import CmdBase as Base
|
||||
|
|
@ -8,6 +8,7 @@ from ..CmdBase import CmdBase as Base
|
|||
if TYPE_CHECKING:
|
||||
from argparse import Namespace
|
||||
from typing import Iterable
|
||||
|
||||
from ..lib.Distro import Distro
|
||||
|
||||
class Cmd(Base): # export
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
from __future__ import annotations
|
||||
|
||||
from typing import override, TYPE_CHECKING
|
||||
from typing import TYPE_CHECKING, override
|
||||
|
||||
from .Cmd import Cmd, Parent
|
||||
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
from __future__ import annotations
|
||||
|
||||
from typing import override, TYPE_CHECKING
|
||||
from typing import TYPE_CHECKING, override
|
||||
|
||||
from ...CmdBase import CmdBase as Base
|
||||
from ..CmdPosix import CmdPosix as Parent
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
from __future__ import annotations
|
||||
|
||||
from contextlib import asynccontextmanager
|
||||
from typing import Any, override, TYPE_CHECKING
|
||||
from typing import TYPE_CHECKING, Any, override
|
||||
|
||||
from ....CmdBase import CmdBase as Base
|
||||
from ....lib.FileContext import FileContext
|
||||
|
|
|
|||
|
|
@ -1,8 +1,9 @@
|
|||
from __future__ import annotations
|
||||
|
||||
from typing import TYPE_CHECKING, override
|
||||
|
||||
from ....lib.log import DEBUG, log
|
||||
from .Cmd import Cmd, Parent
|
||||
from typing import TYPE_CHECKING, override
|
||||
|
||||
if TYPE_CHECKING:
|
||||
from argparse import ArgumentParser, Namespace
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
from __future__ import annotations
|
||||
|
||||
from typing import override, TYPE_CHECKING
|
||||
from typing import TYPE_CHECKING, override
|
||||
|
||||
from ...CmdBase import CmdBase as Base
|
||||
from ..CmdProjects import CmdProjects as Parent
|
||||
|
|
|
|||
|
|
@ -2,10 +2,9 @@ from __future__ import annotations
|
|||
|
||||
from typing import TYPE_CHECKING, override
|
||||
|
||||
from ...lib.base import InputMode
|
||||
from ...lib.base import InputMode, Result
|
||||
from ...lib.log import NOTICE, log
|
||||
from .Cmd import Cmd, Parent
|
||||
from ...lib.base import Result
|
||||
|
||||
if TYPE_CHECKING:
|
||||
from argparse import ArgumentParser, Namespace
|
||||
|
|
|
|||
|
|
@ -1,8 +1,9 @@
|
|||
from __future__ import annotations
|
||||
|
||||
from typing import TYPE_CHECKING, override
|
||||
|
||||
from ...App import Scope
|
||||
from .Cmd import Cmd, Parent
|
||||
from typing import TYPE_CHECKING, override
|
||||
|
||||
if TYPE_CHECKING:
|
||||
from argparse import ArgumentParser, Namespace
|
||||
|
|
|
|||
|
|
@ -1,8 +1,9 @@
|
|||
from __future__ import annotations
|
||||
|
||||
from .Cmd import Cmd, Parent
|
||||
from typing import TYPE_CHECKING, override
|
||||
|
||||
from .Cmd import Cmd, Parent
|
||||
|
||||
if TYPE_CHECKING:
|
||||
from argparse import ArgumentParser, Namespace
|
||||
|
||||
|
|
|
|||
|
|
@ -1,8 +1,9 @@
|
|||
from __future__ import annotations
|
||||
|
||||
from .Cmd import Cmd, Parent
|
||||
from typing import TYPE_CHECKING, override
|
||||
|
||||
from .Cmd import Cmd, Parent
|
||||
|
||||
if TYPE_CHECKING:
|
||||
from argparse import ArgumentParser, Namespace
|
||||
|
||||
|
|
|
|||
|
|
@ -1,8 +1,9 @@
|
|||
from __future__ import annotations
|
||||
|
||||
from typing import TYPE_CHECKING, override
|
||||
|
||||
from ...App import Scope
|
||||
from .Cmd import Cmd, Parent
|
||||
from typing import TYPE_CHECKING, override
|
||||
|
||||
if TYPE_CHECKING:
|
||||
from argparse import ArgumentParser, Namespace
|
||||
|
|
|
|||
|
|
@ -1,11 +1,13 @@
|
|||
from __future__ import annotations
|
||||
|
||||
import os
|
||||
import re
|
||||
|
||||
from typing import TYPE_CHECKING, override
|
||||
|
||||
from ...lib.log import DEBUG, log
|
||||
from ...lib.Uri import Uri
|
||||
from .Cmd import Cmd, Parent
|
||||
from typing import TYPE_CHECKING, override
|
||||
|
||||
if TYPE_CHECKING:
|
||||
from argparse import ArgumentParser, Namespace
|
||||
|
|
|
|||
|
|
@ -1,8 +1,9 @@
|
|||
from __future__ import annotations
|
||||
|
||||
from .Cmd import Cmd, Parent
|
||||
from typing import TYPE_CHECKING, override
|
||||
|
||||
from .Cmd import Cmd, Parent
|
||||
|
||||
if TYPE_CHECKING:
|
||||
from argparse import ArgumentParser, Namespace
|
||||
|
||||
|
|
|
|||
Some files were not shown because too many files have changed in this diff Show more
Loading…
Reference in a new issue