aboutsummaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
authorDavid Goulet <dgoulet@torproject.org>2023-01-10 09:11:52 -0500
committerDavid Goulet <dgoulet@torproject.org>2023-01-10 09:11:58 -0500
commitd456885dac3b5bdfff663ed502fd11f9e0d0e070 (patch)
treeabb52752aabb51416d838f72199bd24247833cfe /scripts
parent1d9166c8c915c14f67612ace8a9449aa3049c2f9 (diff)
downloadtor-d456885dac3b5bdfff663ed502fd11f9e0d0e070.tar.gz
tor-d456885dac3b5bdfff663ed502fd11f9e0d0e070.zip
shellcheck: Fix new warnings
Nothing important, mostly false positive except one case. Signed-off-by: David Goulet <dgoulet@torproject.org>
Diffstat (limited to 'scripts')
-rwxr-xr-xscripts/ci/ci-driver.sh2
-rwxr-xr-xscripts/maint/code-format.sh6
2 files changed, 7 insertions, 1 deletions
diff --git a/scripts/ci/ci-driver.sh b/scripts/ci/ci-driver.sh
index ef31da1ca3..93d764f262 100755
--- a/scripts/ci/ci-driver.sh
+++ b/scripts/ci/ci-driver.sh
@@ -375,7 +375,6 @@ if [[ "$RUN_STAGE_BUILD" = "yes" ]] ; then
hooray "Distcheck was successful. Nothing further will be done."
# We have to exit early here, since we can't do any other tests.
cp tor-*.tar.gz "${CI_SRCDIR}"/artifacts
- exit 0
else
error "Diagnostics:"
runcmd make show-distdir-testlog || true
@@ -383,6 +382,7 @@ if [[ "$RUN_STAGE_BUILD" = "yes" ]] ; then
die "Unable to continue."
fi
end_section Distcheck
+ exit 0
fi
fi
diff --git a/scripts/maint/code-format.sh b/scripts/maint/code-format.sh
index d8f597d70d..5998e96f68 100755
--- a/scripts/maint/code-format.sh
+++ b/scripts/maint/code-format.sh
@@ -160,11 +160,17 @@ if [[ $GITIDX = 1 ]]; then
# partially staged.
note "Stashing unstaged changes"
git stash -q --keep-index
+ # For some reasons, shellcheck is not seeing that we can call this
+ # function from the trap below.
+ # shellcheck disable=SC2317
function restoregit() {
note "Restoring git state"
git stash pop -q
}
else
+ # For some reasons, shellcheck is not seeing that we can call this
+ # function from the trap below.
+ # shellcheck disable=SC2317
function restoregit() {
true
}