diff --git a/.github/workflows/pybridge-c8s.yml b/.github/workflows/pybridge-c8s.yml index 7c1f1a6f380f..899d7ca1094b 100644 --- a/.github/workflows/pybridge-c8s.yml +++ b/.github/workflows/pybridge-c8s.yml @@ -20,7 +20,7 @@ jobs: run: git config --global --add safe.directory /__w/cockpit/cockpit - name: Install submodules - run: modules/checkout + run: vendor/checkout - name: Check --help run: PYTHONPATH=src python3 -m cockpit.bridge --help diff --git a/.github/workflows/tox.yaml b/.github/workflows/tox.yaml index a5a08ff10496..b235c92ee851 100644 --- a/.github/workflows/tox.yaml +++ b/.github/workflows/tox.yaml @@ -15,7 +15,7 @@ jobs: uses: actions/checkout@v3 - name: Checkout submodules - run: modules/checkout + run: vendor/checkout - name: Run venv tests run: runuser -u tox -- tox --colored=yes -m venv -- --color=yes diff --git a/.gitmodules b/.gitmodules index 55b3988b7fe0..08dd6ce4a129 100644 --- a/.gitmodules +++ b/.gitmodules @@ -1,5 +1,5 @@ [submodule "modules/systemd_ctypes"] - path = modules/systemd_ctypes + path = vendor/systemd_ctypes url = https://github.com/allisonkarlitskaya/systemd_ctypes.git [submodule "node_modules"] path = node_modules @@ -9,9 +9,9 @@ url = https://github.com/cockpit-project/pixel-test-reference branch = empty [submodule "modules/ferny"] - path = modules/ferny + path = vendor/ferny url = https://github.com/allisonkarlitskaya/ferny [submodule "modules/beipack"] - path = modules/beipack + path = vendor/beipack url = https://github.com/allisonkarlitskaya/beipack branch = main diff --git a/containers/unit-tests/start b/containers/unit-tests/start index 1a3d2322af43..e01cb66370ad 100755 --- a/containers/unit-tests/start +++ b/containers/unit-tests/start @@ -71,7 +71,7 @@ class SourceDirectory(PodmanTemporaryDirectory): else: opts = [] - git('clone', '--recurse-submodule=modules/*', *opts, '.', self.name) + git('clone', '--recurse-submodule=vendor/*', *opts, '.', self.name) if not args.head and not args.branch: if stash := git_output('stash', 'create'): diff --git a/modules/checkout b/modules/checkout deleted file mode 100755 index 4930253cb50b..000000000000 --- a/modules/checkout +++ /dev/null @@ -1,9 +0,0 @@ -#!/bin/sh - -set -eu -cd "${0%/*}/.." - -# Nothing missing? Do nothing. -git submodule status modules | grep -q ^- || exit 0 - -git submodule update --init --checkout 'modules/*' diff --git a/src/build_backend.py b/src/build_backend.py index d8af9fae0527..74dbab113dd9 100644 --- a/src/build_backend.py +++ b/src/build_backend.py @@ -18,7 +18,7 @@ def find_sources(*, srcpkg: bool) -> Iterable[str]: try: - subprocess.check_call(['modules/checkout'], stdout=2) # Needed for git builds... + subprocess.check_call(['vendor/checkout'], stdout=2) # Needed for git builds... except FileNotFoundError: # ...but not present in tarball... pass # ...and not needed either, because... assert os.path.exists('src/cockpit/_vendor/ferny/__init__.py') # ...the code should exist there already. diff --git a/src/cockpit/_vendor/bei b/src/cockpit/_vendor/bei index 54fb1dcc02d7..23a8bac0323b 120000 --- a/src/cockpit/_vendor/bei +++ b/src/cockpit/_vendor/bei @@ -1 +1 @@ -../../../modules/beipack/src/bei \ No newline at end of file +../../../vendor/beipack/src/bei \ No newline at end of file diff --git a/src/cockpit/_vendor/ferny b/src/cockpit/_vendor/ferny index 059f6a872bf3..5f299b3ab849 120000 --- a/src/cockpit/_vendor/ferny +++ b/src/cockpit/_vendor/ferny @@ -1 +1 @@ -../../../modules/ferny/src/ferny \ No newline at end of file +../../../vendor/ferny/src/ferny \ No newline at end of file diff --git a/src/cockpit/_vendor/systemd_ctypes b/src/cockpit/_vendor/systemd_ctypes index 19f1fbd6a939..0a3f9ef81d67 120000 --- a/src/cockpit/_vendor/systemd_ctypes +++ b/src/cockpit/_vendor/systemd_ctypes @@ -1 +1 @@ -../../../modules/systemd_ctypes/src/systemd_ctypes \ No newline at end of file +../../../vendor/systemd_ctypes/src/systemd_ctypes \ No newline at end of file diff --git a/modules/beipack b/vendor/beipack similarity index 100% rename from modules/beipack rename to vendor/beipack diff --git a/vendor/checkout b/vendor/checkout new file mode 100755 index 000000000000..fb922eee4684 --- /dev/null +++ b/vendor/checkout @@ -0,0 +1,9 @@ +#!/bin/sh + +set -eu +cd "${0%/*}/.." + +# Nothing missing? Do nothing. +git submodule status vendor | grep -q ^- || exit 0 + +git submodule update --init --checkout 'vendor/*' diff --git a/modules/ferny b/vendor/ferny similarity index 100% rename from modules/ferny rename to vendor/ferny diff --git a/modules/systemd_ctypes b/vendor/systemd_ctypes similarity index 100% rename from modules/systemd_ctypes rename to vendor/systemd_ctypes