Skip to content

Suppress hint: Using 'master' as the name for the initial branch. This default branch name #427

Open
@jsoref

Description

@jsoref

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

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions