From e956467ae464afe06def044bffb726aa3f9bfe73 Mon Sep 17 00:00:00 2001 From: Sjors Provoost Date: Fri, 27 Jun 2025 09:23:58 +0200 Subject: [PATCH 1/3] ci: export LC_ALL Explicitly opt out of locale dependence. --- ci/scripts/ci.sh | 2 ++ ci/scripts/run.sh | 2 ++ 2 files changed, 4 insertions(+) diff --git a/ci/scripts/ci.sh b/ci/scripts/ci.sh index d636af2c..4d0376b8 100755 --- a/ci/scripts/ci.sh +++ b/ci/scripts/ci.sh @@ -1,4 +1,6 @@ #!/usr/bin/env bash +export LC_ALL=C.UTF-8 + set -o errexit -o nounset -o pipefail -o xtrace [ "${CI_CONFIG+x}" ] && source "$CI_CONFIG" diff --git a/ci/scripts/run.sh b/ci/scripts/run.sh index 5f5e30d1..1160cdfe 100755 --- a/ci/scripts/run.sh +++ b/ci/scripts/run.sh @@ -1,4 +1,6 @@ #!/usr/bin/env bash +export LC_ALL=C.UTF-8 + set -o errexit -o nounset -o pipefail -o xtrace [ "${CI_CONFIG+x}" ] && source "$CI_CONFIG" From 401e0ce1d9c34ad375428190ee7c46ba6456c0e7 Mon Sep 17 00:00:00 2001 From: Sjors Provoost Date: Fri, 27 Jun 2025 17:01:24 +0200 Subject: [PATCH 2/3] ci: add copyright to bash scripts --- ci/scripts/ci.sh | 5 +++++ ci/scripts/run.sh | 5 +++++ 2 files changed, 10 insertions(+) diff --git a/ci/scripts/ci.sh b/ci/scripts/ci.sh index 4d0376b8..23c4cc13 100755 --- a/ci/scripts/ci.sh +++ b/ci/scripts/ci.sh @@ -1,4 +1,9 @@ #!/usr/bin/env bash +# +# Copyright (c) The Bitcoin Core developers +# Distributed under the MIT software license, see the accompanying +# file COPYING or http://www.opensource.org/licenses/mit-license.php. + export LC_ALL=C.UTF-8 set -o errexit -o nounset -o pipefail -o xtrace diff --git a/ci/scripts/run.sh b/ci/scripts/run.sh index 1160cdfe..11b91845 100755 --- a/ci/scripts/run.sh +++ b/ci/scripts/run.sh @@ -1,4 +1,9 @@ #!/usr/bin/env bash +# +# Copyright (c) The Bitcoin Core developers +# Distributed under the MIT software license, see the accompanying +# file COPYING or http://www.opensource.org/licenses/mit-license.php. + export LC_ALL=C.UTF-8 set -o errexit -o nounset -o pipefail -o xtrace From 3a6db38e561f7645c6e14dd053ee15eb06347d20 Mon Sep 17 00:00:00 2001 From: Sjors Provoost Date: Fri, 27 Jun 2025 17:08:32 +0200 Subject: [PATCH 3/3] ci: rename configs to .bash Avoids locale linting error and indicates that the config files must use bash, not some other variant of shell script. --- .github/workflows/ci.yml | 2 +- ci/README.md | 6 +++--- ci/configs/{default.sh => default.bash} | 0 ci/configs/{gnu32.sh => gnu32.bash} | 0 ci/configs/{llvm.sh => llvm.bash} | 0 5 files changed, 4 insertions(+), 4 deletions(-) rename ci/configs/{default.sh => default.bash} (100%) rename ci/configs/{gnu32.sh => gnu32.bash} (100%) rename ci/configs/{llvm.sh => llvm.bash} (100%) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index a92e59a2..4933588c 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -25,5 +25,5 @@ jobs: - name: Run CI script env: - CI_CONFIG: ci/configs/${{ matrix.config }}.sh + CI_CONFIG: ci/configs/${{ matrix.config }}.bash run: ci/scripts/run.sh diff --git a/ci/README.md b/ci/README.md index 95599128..72eebba8 100644 --- a/ci/README.md +++ b/ci/README.md @@ -16,9 +16,9 @@ All CI is just bash and nix. To run jobs locally: ```bash -CI_CONFIG=ci/configs/default.sh ci/scripts/run.sh -CI_CONFIG=ci/configs/llvm.sh ci/scripts/run.sh -CI_CONFIG=ci/configs/gnu32.sh ci/scripts/run.sh +CI_CONFIG=ci/configs/default.bash ci/scripts/run.sh +CI_CONFIG=ci/configs/llvm.bash ci/scripts/run.sh +CI_CONFIG=ci/configs/gnu32.bash ci/scripts/run.sh ``` By default CI jobs will reuse their build directories. `CI_CLEAN=1` can be specified to delete them before running instead. diff --git a/ci/configs/default.sh b/ci/configs/default.bash similarity index 100% rename from ci/configs/default.sh rename to ci/configs/default.bash diff --git a/ci/configs/gnu32.sh b/ci/configs/gnu32.bash similarity index 100% rename from ci/configs/gnu32.sh rename to ci/configs/gnu32.bash diff --git a/ci/configs/llvm.sh b/ci/configs/llvm.bash similarity index 100% rename from ci/configs/llvm.sh rename to ci/configs/llvm.bash