Skip to content

Commit d983c67

Browse files
authored
Merge pull request #989 from Homebrew/core_main
install.sh: Homebrew/core uses `main` default branch.
2 parents c8f1d39 + c8e0537 commit d983c67

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

install.sh

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -993,15 +993,16 @@ ohai "Downloading and installing Homebrew..."
993993
execute "${MKDIR[@]}" "${HOMEBREW_CORE}"
994994
cd "${HOMEBREW_CORE}" >/dev/null || return
995995

996-
execute "${USABLE_GIT}" "-c" "init.defaultBranch=master" "init" "--quiet"
996+
execute "${USABLE_GIT}" "-c" "init.defaultBranch=main" "init" "--quiet"
997997
execute "${USABLE_GIT}" "config" "remote.origin.url" "${HOMEBREW_CORE_GIT_REMOTE}"
998998
execute "${USABLE_GIT}" "config" "remote.origin.fetch" "+refs/heads/*:refs/remotes/origin/*"
999+
execute "${USABLE_GIT}" "config" "--bool" "fetch.prune" "true"
9991000
execute "${USABLE_GIT}" "config" "--bool" "core.autocrlf" "false"
10001001
execute "${USABLE_GIT}" "config" "--bool" "core.symlinks" "true"
10011002
retry 5 "${USABLE_GIT}" "fetch" "--force" "${quiet_progress[@]}" \
1002-
"origin" "refs/heads/master:refs/remotes/origin/master"
1003+
"origin" "refs/heads/main:refs/remotes/origin/main"
10031004
execute "${USABLE_GIT}" "remote" "set-head" "origin" "--auto" >/dev/null
1004-
execute "${USABLE_GIT}" "reset" "--hard" "origin/master"
1005+
execute "${USABLE_GIT}" "reset" "--hard" "origin/main"
10051006

10061007
cd "${HOMEBREW_REPOSITORY}" >/dev/null || return
10071008
) || exit 1

0 commit comments

Comments
 (0)