mirror of
https://github.com/gomods/athens
synced 2026-02-03 08:40:31 +00:00
Switching to using the main default branch (#1628)
* Switching to using the main default branch * changing links to main branch, not master branch * Changing a few links to relative * Bumping chart version Co-authored-by: Marwan Sulaiman <marwan.sameer@gmail.com>
This commit is contained in:
committed by
GitHub
parent
f01c645305
commit
c2c5daf61a
@@ -10,13 +10,13 @@
|
||||
# the script will exit with code 1 on finding any matches, causing the
|
||||
# CI build to fail. Merge conflict artifacts must be removed before continuing.
|
||||
|
||||
git remote set-branches --add origin master && git fetch
|
||||
COUNT=$(git diff origin/master -- . ':!*.go' ':!go.mod' ':!go.sum' | grep -Ec "^\+[<>=]{7}\w{0,}")
|
||||
git remote set-branches --add origin main && git fetch
|
||||
COUNT=$(git diff origin/main -- . ':!*.go' ':!go.mod' ':!go.sum' | grep -Ec "^\+[<>=]{7}\w{0,}")
|
||||
|
||||
if (($COUNT > 0));then
|
||||
echo "************************************************************"
|
||||
echo "The following files contained merge conflict artifacts:\n"
|
||||
exec git diff --name-only -G'^[<>=]{7}\w?' origin/master -- . ':!*.go' ':!go.mod' ':!go.sum'
|
||||
exec git diff --name-only -G'^[<>=]{7}\w?' origin/main -- . ':!*.go' ':!go.mod' ':!go.sum'
|
||||
echo "************************************************************"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
@@ -11,8 +11,8 @@
|
||||
# before a pull request can be merged.
|
||||
set -xeuo pipefail
|
||||
|
||||
git remote set-branches --add origin master && git fetch
|
||||
ChangedFiles=`git diff --name-only origin/master`
|
||||
git remote set-branches --add origin main && git fetch
|
||||
ChangedFiles=`git diff --name-only origin/main`
|
||||
|
||||
# in the case that ChangedFiles contains go.mod or go.sum run go mod verify
|
||||
case "$ChangedFiles" in
|
||||
|
||||
@@ -7,8 +7,8 @@
|
||||
# to check for any conflicts in versions or digests
|
||||
# which on any exit code > 0 would suggest that action should be taken
|
||||
# before a pull request can be merged.
|
||||
git remote set-branches --add origin master ; git fetch
|
||||
$ChangedFiles=$(git diff --name-only origin/master)
|
||||
git remote set-branches --add origin main ; git fetch
|
||||
$ChangedFiles=$(git diff --name-only origin/main)
|
||||
|
||||
# in the case that ChangedFiles contains go.mod or go.sum run go mod verify
|
||||
$contains= $ChangedFiles | Select-String -Pattern "go.mod|go.sum"
|
||||
|
||||
@@ -14,8 +14,8 @@ if [[ "${MUTABLE_TAG:-}" == "" ]]; then
|
||||
# tagged builds
|
||||
if [[ "$VERSION" =~ ^v[0-9]+\.[0-9]+\.[0-9]+ ]]; then
|
||||
MUTABLE_TAG="latest"
|
||||
# master build
|
||||
elif [[ "$BRANCH" == "master" ]]; then
|
||||
# main branch build
|
||||
elif [[ "$BRANCH" == "main" ]]; then
|
||||
MUTABLE_TAG="canary"
|
||||
# branch build
|
||||
else
|
||||
|
||||
Reference in New Issue
Block a user