mirror of
https://github.com/libssh2/libssh2.git
synced 2025-11-18 15:20:56 +03:00
scripts: fix shellcheck SC2046 warnings
Also: - use more `--` end-of-options markers. - checksrc.sh: use literal quotes. Closes #1739
This commit is contained in:
@@ -50,7 +50,7 @@ DISTCLEANFILES += ChangeLog
|
|||||||
|
|
||||||
dist-hook:
|
dist-hook:
|
||||||
rm -rf $(top_builddir)/tests/log
|
rm -rf $(top_builddir)/tests/log
|
||||||
find $(distdir) -name "*.dist" -exec rm {} \;
|
find $(distdir) -name "*.dist" -exec rm -- {} \;
|
||||||
(distit=`find $(srcdir) -name "*.dist"`; \
|
(distit=`find $(srcdir) -name "*.dist"`; \
|
||||||
for file in $$distit; do \
|
for file in $$distit; do \
|
||||||
strip=`echo $$file | sed -e s/^$(srcdir)// -e s/\.dist//`; \
|
strip=`echo $$file | sed -e s/^$(srcdir)// -e s/\.dist//`; \
|
||||||
|
|||||||
@@ -6,7 +6,7 @@ set -eu
|
|||||||
|
|
||||||
cd "$(dirname "$0")"/..
|
cd "$(dirname "$0")"/..
|
||||||
|
|
||||||
git ls-files "*.[ch]" "*.cc" | xargs -n1 \
|
git ls-files '*.[ch]' '*.cc' | xargs -n1 \
|
||||||
ci/checksrc.pl -i4 -m79 -AFIXME -AERRNOVAR -AFOPENMODE -ATYPEDEFSTRUCT \
|
ci/checksrc.pl -i4 -m79 -AFIXME -AERRNOVAR -AFOPENMODE -ATYPEDEFSTRUCT \
|
||||||
-aaccept \
|
-aaccept \
|
||||||
-afclose \
|
-afclose \
|
||||||
|
|||||||
@@ -57,4 +57,5 @@ cd "$(dirname "$0")"/..
|
|||||||
--max-branches 12 \
|
--max-branches 12 \
|
||||||
--max-arguments 5 \
|
--max-arguments 5 \
|
||||||
--max-localvars 15 \
|
--max-localvars 15 \
|
||||||
--max-statements 50
|
--max-statements 50 \
|
||||||
|
--
|
||||||
|
|||||||
@@ -7,7 +7,7 @@ set -eu
|
|||||||
|
|
||||||
cd "$(dirname "$0")"/..
|
cd "$(dirname "$0")"/..
|
||||||
|
|
||||||
# shellcheck disable=SC2046
|
git grep -z -l -E '^#!(/usr/bin/env bash|/bin/sh|/bin/bash)' | xargs -0 -r \
|
||||||
shellcheck --exclude=1091 \
|
shellcheck --exclude=1091 \
|
||||||
--enable=avoid-nullary-conditions,deprecate-which \
|
--enable=avoid-nullary-conditions,deprecate-which \
|
||||||
$(grep -l -E '^#!(/usr/bin/env bash|/bin/sh|/bin/bash)' $(git ls-files))
|
--
|
||||||
|
|||||||
@@ -6,7 +6,8 @@ set -eu
|
|||||||
|
|
||||||
cd "$(dirname "$0")"/..
|
cd "$(dirname "$0")"/..
|
||||||
|
|
||||||
# shellcheck disable=SC2046
|
git ls-files -z | xargs -0 -r \
|
||||||
codespell --skip='docs/AUTHORS' \
|
codespell \
|
||||||
--ignore-words='ci/codespell-ignore.words' \
|
--skip 'docs/AUTHORS' \
|
||||||
$(git ls-files)
|
--ignore-words 'ci/codespell-ignore.words' \
|
||||||
|
--
|
||||||
|
|||||||
2
maketgz
2
maketgz
@@ -124,7 +124,7 @@ retar() {
|
|||||||
mkdir "$tempdir"
|
mkdir "$tempdir"
|
||||||
cd "$tempdir"
|
cd "$tempdir"
|
||||||
gzip -dc "../$targz" | tar -xf -
|
gzip -dc "../$targz" | tar -xf -
|
||||||
find libssh2-* -depth -exec touch -c -t "$filestamp" '{}' +
|
find libssh2-* -depth -exec touch -c -t "$filestamp" -- '{}' +
|
||||||
tar --create --format=ustar --owner=0 --group=0 --numeric-owner --sort=name libssh2-* | gzip --best --no-name > out.tar.gz
|
tar --create --format=ustar --owner=0 --group=0 --numeric-owner --sort=name libssh2-* | gzip --best --no-name > out.tar.gz
|
||||||
mv out.tar.gz ../
|
mv out.tar.gz ../
|
||||||
cd ..
|
cd ..
|
||||||
|
|||||||
Reference in New Issue
Block a user