Skip to content

Instantly share code, notes, and snippets.

@nl5887
Last active June 30, 2021 11:29
Show Gist options
  • Save nl5887/e6a082d3c5fa7ed97778b5247f34a07f to your computer and use it in GitHub Desktop.
Save nl5887/e6a082d3c5fa7ed97778b5247f34a07f to your computer and use it in GitHub Desktop.
pass git credentials using environment variables
git config --global credential."https://gitlab.com".helper '!f() { test "$1" = get && echo "username=${GIT_USER}"; echo "password=${GIT_PASS}"; }; f'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment