|
Michal Domonkos |
835709 |
From fdb2de52f24111b64b7e41ab052e8751f0ec3df9 Mon Sep 17 00:00:00 2001
|
|
Michal Domonkos |
835709 |
From: Michal Domonkos <mdomonko@redhat.com>
|
|
Michal Domonkos |
835709 |
Date: Mon, 11 Jul 2022 13:14:49 +0200
|
|
Michal Domonkos |
835709 |
Subject: [PATCH 1/2] Use explicit default branch in %autosetup -S git
|
|
Michal Domonkos |
835709 |
|
|
Michal Domonkos |
835709 |
Commit 3a6b1d8fbf846d3f1b139d343fdfddebe99ae42b assumed "master" as the
|
|
Michal Domonkos |
835709 |
default git branch to track, however the name can be changed globally,
|
|
Michal Domonkos |
835709 |
so make it explicit.
|
|
Michal Domonkos |
835709 |
|
|
Michal Domonkos |
835709 |
Given the choice now, go with "main" as the general trend, e.g:
|
|
Michal Domonkos |
835709 |
https://fedoraproject.org/wiki/Changes/GitRepos-master-to-main
|
|
Michal Domonkos |
835709 |
---
|
|
Michal Domonkos |
835709 |
macros.in | 4 ++--
|
|
Michal Domonkos |
835709 |
1 file changed, 2 insertions(+), 2 deletions(-)
|
|
Michal Domonkos |
835709 |
|
|
Michal Domonkos |
835709 |
diff --git a/macros.in b/macros.in
|
|
Michal Domonkos |
835709 |
index 6177e6fec..db5f5b11f 100644
|
|
Michal Domonkos |
835709 |
--- a/macros.in
|
|
Michal Domonkos |
835709 |
+++ b/macros.in
|
|
Michal Domonkos |
835709 |
@@ -1166,7 +1166,7 @@ package or when debugging this package.\
|
|
Michal Domonkos |
835709 |
|
|
Michal Domonkos |
835709 |
# Git
|
|
Michal Domonkos |
835709 |
%__scm_setup_git(q)\
|
|
Michal Domonkos |
835709 |
-%{__git} init %{-q}\
|
|
Michal Domonkos |
835709 |
+%{__git} init %{-q} --initial-branch=main\
|
|
Michal Domonkos |
835709 |
%{__git} config user.name "%{__scm_username}"\
|
|
Michal Domonkos |
835709 |
%{__git} config user.email "%{__scm_usermail}"\
|
|
Michal Domonkos |
835709 |
%{__git} config gc.auto 0\
|
|
Michal Domonkos |
835709 |
@@ -1175,7 +1175,7 @@ package or when debugging this package.\
|
|
Michal Domonkos |
835709 |
--author "%{__scm_author}" -m "%{NAME}-%{VERSION} base"\
|
|
Michal Domonkos |
835709 |
%{__git} branch rpm-build \
|
|
Michal Domonkos |
835709 |
%{__git} checkout rpm-build \
|
|
Michal Domonkos |
835709 |
-%{__git} branch --set-upstream-to=master
|
|
Michal Domonkos |
835709 |
+%{__git} branch --set-upstream-to=main
|
|
Michal Domonkos |
835709 |
|
|
Michal Domonkos |
835709 |
%__scm_apply_git(qp:m:)\
|
|
Michal Domonkos |
835709 |
%{__git} apply --index --reject %{-p:-p%{-p*}} -\
|
|
Michal Domonkos |
835709 |
--
|
|
Michal Domonkos |
835709 |
2.36.1
|
|
Michal Domonkos |
835709 |
|