mirror of
https://github.com/storytold/craft-libs.git
synced 2026-11-25 15:44:29 +00:00
chore(ci): use [[ ]] in shell scripts (SonarCloud S7688) (#2304)
This commit is contained in:
@@ -2,11 +2,11 @@
|
||||
# Restore both runtime feature configurations, docs and ordinary example linking, without fuzz caps.
|
||||
set -euo pipefail
|
||||
unset CRAFT_HOSTILE_DIVISOR PROPTEST_CASES
|
||||
if [ "${RUNNER_OS:-}" = Windows ]; then
|
||||
if [[ "${RUNNER_OS:-}" = Windows ]]; then
|
||||
powershell.exe -NoProfile -Command '$ErrorActionPreference = "Stop"; Start-Service Spooler; Add-PrinterDriver -Name "Generic / Text Only"'
|
||||
fi
|
||||
# Windows cannot spawn one rustfmt command with every workspace target (#2200).
|
||||
if [ "${RUNNER_OS:-}" = Windows ]; then
|
||||
if [[ "${RUNNER_OS:-}" = Windows ]]; then
|
||||
python scripts/ci-format-workspace.py
|
||||
else
|
||||
cargo fmt --check
|
||||
|
||||
@@ -13,7 +13,7 @@ set -euo pipefail
|
||||
photocraft=74330157cb601573ae4523a95bb9132822fc3918
|
||||
fetcher=.test-inputs/photocraft
|
||||
|
||||
if [ -z "$(ls -A "$fetcher/corpus" 2>/dev/null)" ]; then
|
||||
if [[ -z "$(ls -A "$fetcher/corpus" 2>/dev/null)" ]]; then
|
||||
rm -rf "$fetcher"
|
||||
mkdir -p "$fetcher"
|
||||
git -C "$fetcher" init --quiet
|
||||
|
||||
Reference in New Issue
Block a user