Skip to content

Commit

Permalink
avoid useless warnings in CI
Browse files Browse the repository at this point in the history
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>
  • Loading branch information
praiskup committed Aug 30, 2024
1 parent 844893a commit 04fa057
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions container/cmd
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,8 @@ fi
if test "$GITHUB_EVENT_NAME" = 'pull_request'; then
git config --global --add safe.directory '*'
git config --global advice.detachedHead false
git config --global init.defaultBranch main

git fetch origin "$target_branch:$target_branch" &>/dev/null

test -z "$INPUT_SUBDIRECTORY" || INPUT_SUBDIRECTORIES=$INPUT_SUBDIRECTORY
Expand Down

0 comments on commit 04fa057

Please sign in to comment.