Use submodule path for upload-bom.sh instead of raw URL

PCB projects already check out kicad-ci as a .gitlab submodule
(GIT_SUBMODULE_STRATEGY: recursive). Using the local path keeps
the script version pinned to the submodule pointer + removes the
need for the kicad9 ref hardcoded in the curl URL.
This commit is contained in:
Tim Hadwen
2026-05-24 09:57:39 +00:00
parent bd7882f54f
commit 6a411cdc3f

View File

@@ -343,14 +343,12 @@ generate_panel:
image: curlimages/curl:8.10.1 image: curlimages/curl:8.10.1
before_script: before_script:
- apk add --no-cache bash jq - apk add --no-cache bash jq
# Fetch the upload script from the kicad-ci repo so the yml stays # Each PCB project checks out kicad-ci as a submodule under
# self-contained (GitLab's `include: project:` only ships the yml # .gitlab/ (with GIT_SUBMODULE_STRATEGY: recursive at the top of
# itself, not sibling files in the repo). The ref pins to kicad9 # this file), so scripts/upload-bom.sh is available locally —
# — bump if you move the script. # no raw-URL fetch needed, and the script's version stays in
- | # lockstep with the submodule pointer the project pins to.
curl -fsSL -o /usr/local/bin/upload-bom.sh \ - install -m 0755 "$CI_PROJECT_DIR/.gitlab/scripts/upload-bom.sh" /usr/local/bin/upload-bom.sh
"https://gitlab.com/Micromelon/education/hardware/kicad-ci/-/raw/kicad9/scripts/upload-bom.sh"
chmod +x /usr/local/bin/upload-bom.sh
astable_dev: astable_dev:
extends: .astable_base extends: .astable_base