refactor: SC3040 (warning): In POSIX sh, set option pipefail is undefined.

This commit is contained in:
Burnett01 2025-12-02 15:15:01 +00:00
parent d4d84ba02c
commit 6cb3f8196c
9 changed files with 9 additions and 9 deletions

View file

@ -1,6 +1,6 @@
#!/bin/sh #!/bin/sh
set -euo pipefail set -euo
source agent-start "${1:-default}" source agent-start "${1:-default}"
cat - | tr -d '\r' | DISPLAY=1 SSH_ASKPASS=agent-askpass ssh-add - >/dev/null cat - | tr -d '\r' | DISPLAY=1 SSH_ASKPASS=agent-askpass ssh-add - >/dev/null

View file

@ -1,5 +1,5 @@
#!/bin/sh #!/bin/sh
set -euo pipefail set -euo
echo "$SSH_PASS" echo "$SSH_PASS"

View file

@ -1,6 +1,6 @@
#!/bin/sh #!/bin/sh
set -euo pipefail set -euo
FOLDER=${1:-default} FOLDER=${1:-default}
STORE_PATH="/tmp/ssh-agent/$FOLDER" STORE_PATH="/tmp/ssh-agent/$FOLDER"

View file

@ -1,6 +1,6 @@
#!/bin/sh #!/bin/sh
set -euo pipefail set -euo
if [ ! -z "$SSH_AGENT_PID" ]; then if [ ! -z "$SSH_AGENT_PID" ]; then
# Here, the environment is set already, just kill the script. # Here, the environment is set already, just kill the script.

View file

@ -1,5 +1,5 @@
#!/bin/sh #!/bin/sh
set -euo pipefail set -euo
printf '%s\n' "$@" >> $HOME/.ssh/known_hosts printf '%s\n' "$@" >> $HOME/.ssh/known_hosts

View file

@ -1,5 +1,5 @@
#!/bin/sh #!/bin/sh
set -euo pipefail set -euo
truncate -s 0 $HOME/.ssh/known_hosts truncate -s 0 $HOME/.ssh/known_hosts

View file

@ -1,6 +1,6 @@
#!/bin/sh #!/bin/sh
set -euo pipefail set -euo
touch $HOME/.ssh/known_hosts touch $HOME/.ssh/known_hosts
chmod 600 $HOME/.ssh/known_hosts chmod 600 $HOME/.ssh/known_hosts

View file

@ -1,5 +1,5 @@
#!/bin/sh #!/bin/sh
set -euo pipefail set -euo
mkdir -m 700 $HOME/.ssh mkdir -m 700 $HOME/.ssh

View file

@ -1,6 +1,6 @@
#!/bin/sh #!/bin/sh
set -euo pipefail set -euo
if [ "${INPUT_DEBUG:-false}" = "true" ]; then if [ "${INPUT_DEBUG:-false}" = "true" ]; then
set -x set -x