Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: Use the recommended 'persist-credentials: false' setting #1143

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

mem
Copy link
Contributor

@mem mem commented Jan 15, 2025

The GitHub checkout action has this persist-credentials setting.

It's described like this:

# Whether to configure the token or SSH key with the local git config
# Default: true
persist-credentials: ''

Sounds harmless, right? It almosts makes it sound as if it's going to modify ~/.gitconfig.

This default of true causes credentials to end up in the working copy's .git/config, which interacts badly with other stuff happening in GHA.

Set it to false just in case.

@mem mem requested a review from a team as a code owner January 15, 2025 16:26
The GitHub checkout action has this `persist-credentials` setting.

It's described like this:

    # Whether to configure the token or SSH key with the local git config
    # Default: true
    persist-credentials: ''

Sounds harmless, right? It almosts makes it sound as if it's going to
modify `~/.gitconfig`.

This default of `true` causes credentials to end up in the working
copy's `.git/config`, which interacts badly with other stuff happening
in GHA.

Set it to false just in case.

Signed-off-by: Marcelo E. Magallon <[email protected]>
@mem mem force-pushed the mem/persist-credentials-false branch from b772551 to 5bfbdd5 Compare January 15, 2025 17:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant