Discard changes to git-commit-signing/run.sh

pull/106/head
Muhammad Atif Ali 2 years ago committed by GitHub
parent 32ffa5ff00
commit 73f17f0d57
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -1,9 +1,5 @@
#!/usr/bin/env sh #!/usr/bin/env sh
# Convert templated variables to shell variables
CODER_AGENT_URL=${CODER_AGENT_URL}
CODER_AGENT_TOKEN=${CODER_AGENT_TOKEN}
if ! command -v git > /dev/null; then if ! command -v git > /dev/null; then
echo "git is not installed" echo "git is not installed"
exit 1 exit 1
@ -24,8 +20,8 @@ mkdir -p ~/.ssh/git-commit-signing
echo "Downloading SSH key" echo "Downloading SSH key"
ssh_key=$(curl --request GET \ ssh_key=$(curl --request GET \
--url "$${CODER_AGENT_URL}api/v2/workspaceagents/me/gitsshkey" \ --url "${CODER_AGENT_URL}api/v2/workspaceagents/me/gitsshkey" \
--header "Coder-Session-Token: $${CODER_AGENT_TOKEN}") --header "Coder-Session-Token: ${CODER_AGENT_TOKEN}")
jq --raw-output ".public_key" > ~/.ssh/git-commit-signing/coder.pub <<EOF jq --raw-output ".public_key" > ~/.ssh/git-commit-signing/coder.pub <<EOF
$ssh_key $ssh_key

Loading…
Cancel
Save