From: "Daniel P. Berrangé" <berrange@redhat.com>
To: "Philippe Mathieu-Daudé" <philmd@redhat.com>
Cc: "Savitoj Singh" <savsingh@redhat.com>,
"Thomas Huth" <thuth@redhat.com>,
qemu-devel@nongnu.org,
"Wainer dos Santos Moschetta" <wainersm@redhat.com>,
"Philippe Mathieu-Daudé" <f4bug@amsat.org>,
"Willian Rampazzo" <willianr@redhat.com>,
"Paolo Bonzini" <pbonzini@redhat.com>,
"Alex Bennée" <alex.bennee@linaro.org>
Subject: Re: [PATCH] gitlab-ci: Be ready for new default 'main' branch name
Date: Tue, 25 May 2021 17:08:55 +0100 [thread overview]
Message-ID: <YK0hFyf17lNKHqek@redhat.com> (raw)
In-Reply-To: <20210525153826.4174157-1-philmd@redhat.com>
On Tue, May 25, 2021 at 05:38:25PM +0200, Philippe Mathieu-Daudé wrote:
> In order to be ready for the GitLab changes in using inclusive
> terminology (replacing the 'master' branch name by the 'main'
> branch name), rename our use of 'master' by the $CI_DEFAULT_BRANCH
> environment variable, so new forks won't be facing any issue.
I've no objection to the actual config change, but the description is
little inaccurate IMHO. GitLab is not forcing a branch name change
into any existing repositories. It is entirely upto QEMU to decide
when to change our branch names. Forks of QEMU also won't get a new
branch name, because any branches in forks are inherited from what
exists in repository being forked and not arbitrarily renamed.
So, AFAICT, only brand new (ie empty) repositories will get 'main'
as the new default branch name.
IOW, I'd describe this as
"We want to skip the checkpatch and DCO signoff jobs when
pushing to the default branch. Currently this branch is
called 'master', but we don't need to hardcode this in
the CI configuration, because the $CI_DEFAULT_BRANCH
env variable exposes it."
> diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
> index f718b61fa78..db4e8490483 100644
> --- a/.gitlab-ci.yml
> +++ b/.gitlab-ci.yml
> @@ -784,7 +784,7 @@ check-patch:
> script: .gitlab-ci.d/check-patch.py
> except:
> variables:
> - - $CI_PROJECT_NAMESPACE == 'qemu-project' && $CI_COMMIT_BRANCH == 'master'
> + - $CI_PROJECT_NAMESPACE == 'qemu-project' && $CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH
> variables:
> GIT_DEPTH: 1000
> allow_failure: true
> @@ -797,7 +797,7 @@ check-dco:
> script: .gitlab-ci.d/check-dco.py
> except:
> variables:
> - - $CI_PROJECT_NAMESPACE == 'qemu-project' && $CI_COMMIT_BRANCH == 'master'
> + - $CI_PROJECT_NAMESPACE == 'qemu-project' && $CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH
> variables:
> GIT_DEPTH: 1000
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Regards,
Daniel
--
|: https://berrange.com -o- https://www.flickr.com/photos/dberrange :|
|: https://libvirt.org -o- https://fstop138.berrange.com :|
|: https://entangle-photo.org -o- https://www.instagram.com/dberrange :|
next prev parent reply other threads:[~2021-05-25 17:17 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-05-25 15:38 [PATCH] gitlab-ci: Be ready for new default 'main' branch name Philippe Mathieu-Daudé
2021-05-25 16:08 ` Daniel P. Berrangé [this message]
2021-05-25 17:33 ` Philippe Mathieu-Daudé
2021-05-25 16:43 ` Willian Rampazzo
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=YK0hFyf17lNKHqek@redhat.com \
--to=berrange@redhat.com \
--cc=alex.bennee@linaro.org \
--cc=f4bug@amsat.org \
--cc=pbonzini@redhat.com \
--cc=philmd@redhat.com \
--cc=qemu-devel@nongnu.org \
--cc=savsingh@redhat.com \
--cc=thuth@redhat.com \
--cc=wainersm@redhat.com \
--cc=willianr@redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).