gosec/entrypoint.sh

12 lines
395 B
Bash
Raw Normal View History

#!/usr/bin/env bash
2021-10-14 08:54:32 +01:00
# Expand the arguments into an array of strings. This is required because the GitHub action
# provides all arguments concatenated as a single string.
ARGS=("$@")
if [[ ! -z "${GITHUB_AUTHENTICATION_TOKEN}" ]]; then
git config --global --add url."https://x-access-token:${GITHUB_AUTHENTICATION_TOKEN}@github.com/".insteadOf "https://github.com/"
fi
/bin/gosec ${ARGS[*]}