mirror of
https://github.com/clearlinux/common.git
synced 2026-08-26 16:28:11 +00:00
Move packages content over to main branch
World has moved to main, start updating accordingly. Signed-off-by: William Douglas <william.douglas@intel.com>
This commit is contained in:
+6
-6
@@ -132,7 +132,7 @@ $(SRPMFILE): $(SPECFILE) $(__allsources) localreponotice clean-old-content
|
||||
# initialized locally, or if the remote contains no commits.
|
||||
pullrebase:
|
||||
@if [ -z "$$SKIP_GIT" ] && [ -e .git ]; then \
|
||||
if ! git rev-parse --verify --quiet origin/master > /dev/null; then \
|
||||
if ! git rev-parse --verify --quiet origin/main > /dev/null; then \
|
||||
echo "Remote not yet initialized. Continuing."; \
|
||||
exit 0; \
|
||||
fi; \
|
||||
@@ -146,7 +146,7 @@ pullrebase:
|
||||
echo "Current branch up-to-date. Continuing."; \
|
||||
exit 0; \
|
||||
fi; \
|
||||
echo "Rebasing to origin/master"; \
|
||||
echo "Rebasing to origin/main"; \
|
||||
if git status --porcelain | grep -q '^.[^?]'; \
|
||||
then \
|
||||
git stash save; \
|
||||
@@ -310,8 +310,8 @@ prekoji-checks:
|
||||
koji: prekoji-checks kojidef
|
||||
@$(MAKE) spdxcheck
|
||||
@$(MAKE) checkblacklist
|
||||
@if [ "$(CURRENT_BRANCH)" != "master" ] && [ "$(CURRENT_BRANCH)" != "main" ]; then \
|
||||
echo "Error: Must be on the \"master\" or \"main\" branch to submit to koji" >&2; \
|
||||
@if [ "$(CURRENT_BRANCH)" != "main" ]; then \
|
||||
echo "Error: Must be on the \"main\" branch to submit to koji" >&2; \
|
||||
exit 1; \
|
||||
fi; \
|
||||
if ! git diff --quiet HEAD -- ${SPECFILE}; then \
|
||||
@@ -319,7 +319,7 @@ koji: prekoji-checks kojidef
|
||||
exit 1; \
|
||||
fi; \
|
||||
git fetch; \
|
||||
if git rev-parse --verify --quiet origin/master >/dev/null; then \
|
||||
if git rev-parse --verify --quiet origin/main >/dev/null; then \
|
||||
git pull --rebase; \
|
||||
fi; \
|
||||
if git ls-remote --tags --exit-code origin $(SRPMVERS) >/dev/null; then \
|
||||
@@ -327,7 +327,7 @@ koji: prekoji-checks kojidef
|
||||
exit 1; \
|
||||
fi
|
||||
git tag $(SRPMVERS)
|
||||
git push origin $(CURRENT_BRANCH):master refs/tags/$(SRPMVERS)
|
||||
git push origin $(CURRENT_BRANCH):main refs/tags/$(SRPMVERS)
|
||||
$(KOJI_CMD) build $$KOJI_NOWAIT $(KOJI_TAG) $(PKG_BASE_URL)/$(PKG_NAME)?#$(SRPMVERS)
|
||||
|
||||
#help rekoji: In case a previous 'make koji' failed, trigger a rebuild for the
|
||||
|
||||
+12
-7
@@ -68,13 +68,18 @@ ${PULL_PKGS}:
|
||||
if [ ! -d "$$p/.git" ]; then echo "Nothing to pull for $$p - $$p/.git missing"; exit 0; fi; \
|
||||
cd "$$p" ; \
|
||||
if git remote | grep origin >/dev/null 2>&1; then \
|
||||
O=$$(git rev-parse origin/master 2>/dev/null); \
|
||||
case "$$p" in \
|
||||
("projects/"*) BRANCH=master ;; \
|
||||
("packages/"*) BRANCH=main ;; \
|
||||
(*) BRANCH=master ;; \
|
||||
esac; \
|
||||
O=$$(git rev-parse origin/"$$BRANCH" 2>/dev/null); \
|
||||
git fetch --tags origin >/dev/null 2>&1; \
|
||||
N=$$(git rev-parse origin/master); \
|
||||
N=$$(git rev-parse origin/"$$BRANCH"); \
|
||||
if [ "$$O" != "$$N" ]; then \
|
||||
echo "Updating: $$p"; \
|
||||
if ! git merge --ff-only origin/master 2>/dev/null; then \
|
||||
echo "$$p: Cannot fast-forward $$(git rev-parse --abbrev-ref HEAD) to origin/master" ; \
|
||||
if ! git merge --ff-only origin/"$$BRANCH" 2>/dev/null; then \
|
||||
echo "$$p: Cannot fast-forward $$(git rev-parse --abbrev-ref HEAD) to origin/$$BRANCH" ; \
|
||||
fi ; \
|
||||
git --no-pager log --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset' --abbrev-commit $$O..$$N; echo; \
|
||||
fi ; \
|
||||
@@ -166,12 +171,12 @@ diff: $(PACKAGES_FILE) $(addprefix packages/,$(PKGS_LOCAL))
|
||||
(cd $$p; git status --porcelain | grep -vq '^?? ' && (echo "Uncommitted changes in: $$p"; git diff --stat); :) ;\
|
||||
done
|
||||
|
||||
#help log: Run git log origin/master..HEAD for all package repos, thus
|
||||
#help log: Run git log origin/main..HEAD for all package repos, thus
|
||||
#help displaying any committed but unpushed changes.
|
||||
log: $(PACKAGES_FILE) $(addprefix packages/,$(PKGS_LOCAL))
|
||||
@for p in projects/common $(addprefix packages/,$(PKGS_LOCAL)); do \
|
||||
( cd $$p; if [ -n "$$(git rev-list origin/master..HEAD)" ] ; then \
|
||||
echo $$p ; git --no-pager log --pretty="format:%s" origin/master..HEAD ; echo ; echo;\
|
||||
( cd $$p; if [ -n "$$(git rev-list origin/main..HEAD)" ] ; then \
|
||||
echo $$p ; git --no-pager log --pretty="format:%s" origin/main..HEAD ; echo ; echo;\
|
||||
fi ; ) \
|
||||
done
|
||||
|
||||
|
||||
@@ -23,7 +23,7 @@ Download the [user setup](user-setup.sh) script and run it on your Clear Linux
|
||||
system as an unprivileged user.
|
||||
|
||||
```
|
||||
$ curl -O https://raw.githubusercontent.com/clearlinux/common/master/user-setup.sh
|
||||
$ curl -O https://raw.githubusercontent.com/clearlinux/common/main/user-setup.sh
|
||||
$ chmod +x user-setup.sh
|
||||
$ ./user-setup.sh
|
||||
```
|
||||
|
||||
Reference in New Issue
Block a user