diff options
| author | Gaëtan Gilbert | 2020-12-16 10:22:56 +0100 |
|---|---|---|
| committer | Gaëtan Gilbert | 2020-12-16 10:25:55 +0100 |
| commit | faafe8bfb97e7b05afbcc903cc946d9fca038df5 (patch) | |
| tree | 34ffdd5643de382ebc2f597abff09ff7732c20d7 /dev | |
| parent | 46c55ced3d1a78f63b3b50fc12d9760663e87e57 (diff) | |
Fix overlay system: projects need to be loaded before overlays.
Also fixes is_in_projects
Diffstat (limited to 'dev')
| -rwxr-xr-x | dev/ci/ci-basic-overlay.sh | 7 | ||||
| -rw-r--r-- | dev/ci/ci-common.sh | 6 |
2 files changed, 6 insertions, 7 deletions
diff --git a/dev/ci/ci-basic-overlay.sh b/dev/ci/ci-basic-overlay.sh index dd683c96a9..18c58c423d 100755 --- a/dev/ci/ci-basic-overlay.sh +++ b/dev/ci/ci-basic-overlay.sh @@ -7,11 +7,10 @@ declare -a projects # the list of project repos that can be be overlayed # checks if the given argument is a known project function is_in_projects { - local rc=1 - for x in ${projects[@]}; do - if [ "$1" = "$x" ]; then rc=0; fi; + for x in "${projects[@]}"; do + if [ "$1" = "$x" ]; then return 0; fi; done - return rc + return 1 } # project <name> <giturl> <ref> [<archiveurl>] diff --git a/dev/ci/ci-common.sh b/dev/ci/ci-common.sh index fdba690155..8d8f78e10c 100644 --- a/dev/ci/ci-common.sh +++ b/dev/ci/ci-common.sh @@ -73,14 +73,14 @@ function overlay() } set +x +# shellcheck source=ci-basic-overlay.sh +. "${ci_dir}/ci-basic-overlay.sh" + for overlay in "${ci_dir}"/user-overlays/*.sh; do # shellcheck source=/dev/null # the directoy can be empty if [ -e "${overlay}" ]; then . "${overlay}"; fi done - -# shellcheck source=ci-basic-overlay.sh -. "${ci_dir}/ci-basic-overlay.sh" set -x # [git_download project] will download [project] and unpack it |
