Open
Description
Downstream consumers of actions shouldn't see noise about that git itself is changing its default branch. When actions/checkout
is used, it will be given a specific branch (or similar) to check things out...
Run actions/checkout@v2.0.0
with:
fetch-depth: 2
repository: org/repo
token: ***
persist-credentials: true
clean: true
lfs: false
Syncing repository: org/repo
Working directory is '/home/runner/work/org/repo'
/usr/bin/git version
git version 2.30.0
Deleting the contents of '/home/runner/work/org/repo'
/usr/bin/git init /home/runner/work/org/repo
hint: Using 'master' as the name for the initial branch. This default branch name
hint: is subject to change. To configure the initial branch name to use in all
hint: of your new repositories, which will suppress this warning, call:
hint:
hint: git config --global init.defaultBranch <name>
hint:
hint: Names commonly chosen instead of 'master' are 'main', 'trunk' and
hint: 'development'. The just-created branch can be renamed via this command:
hint:
hint: git branch -m <name>
Initialized empty Git repository in /home/runner/work/org/repo/.git/
Metadata
Metadata
Assignees
Labels
No labels
Activity
Set initial-branch (actions#427)
snowshoes commentedon Jan 31, 2022
Git should not mess political correctness sht with open source world, you are correcting nothing but sht
Set initial-branch (actions#427)
Set initial-branch (actions#427)
Set initial-branch (actions#427)
Set initial-branch (actions#427)
MestreLion commentedon Nov 28, 2024
@snowshoes this issue has nothing to do about "political correctness sht", but rather about suppressing a rather verbose 10-line useless warning, which can be easily done by actions/checkout by simply setting the hinted git config global setting to a dummy name