Skip to content

Commit 74eea76

Browse files
authored
Update main.sh
fix:script
1 parent 8567bcd commit 74eea76

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

src/main.sh

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -83,7 +83,11 @@ else
8383
# ssh-add can use the SSH_ASKPASS program to get a passphrase.
8484
# We create a temporary script that just echoes our passphrase.
8585
SSH_ASKPASS_SCRIPT="/tmp/askpass.sh"
86-
echo "echo \"${INPUT_SSH_PASSPHRASE}\"" > "${SSH_ASKPASS_SCRIPT}"
86+
87+
# ***** THE FIX IS HERE *****
88+
# This line now adds `#!/bin/sh` to make the script executable.
89+
echo -e "#!/bin/sh\necho \"${INPUT_SSH_PASSPHRASE}\"" > "${SSH_ASKPASS_SCRIPT}"
90+
8791
chmod +x "${SSH_ASKPASS_SCRIPT}"
8892

8993
# Set SSH_ASKPASS and DISPLAY, then call ssh-add.

0 commit comments

Comments
 (0)