-
Notifications
You must be signed in to change notification settings - Fork 55
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Format shell scripts consistently in this repository (#3791)
- Loading branch information
Showing
10 changed files
with
82 additions
and
81 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,9 @@ | ||
#!/bin/bash | ||
|
||
if [ $# -ne 2 ]; then | ||
echo "Error: This script requires exactly two arguments." | ||
echo "./bom-line-test.sh <LINE> <comma separated list of plugins>" | ||
exit 1 | ||
if [[ $# -ne 2 ]]; then | ||
echo "Error: This script requires exactly two arguments." | ||
echo "./bom-line-test.sh <LINE> <comma separated list of plugins>" | ||
exit 1 | ||
fi | ||
|
||
LINE=$1 PLUGINS=$2 TEST=InjectedTest bash ../local-test.sh | ||
LINE=$1 PLUGINS=$2 TEST=InjectedTest bash ../local-test.sh |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
10 changes: 5 additions & 5 deletions
10
release-manager-scripts/bom-release-issue-add-release-comment.sh
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,12 @@ | ||
#!/bin/bash | ||
|
||
if [ $# -ne 1 ]; then | ||
echo "Error: This script requires exactly one argument." | ||
echo "./bom-release-issue-add-release-comment.sh <GitHub issue id>" | ||
exit 1 | ||
if [[ $# -ne 1 ]]; then | ||
echo "Error: This script requires exactly one argument." | ||
echo "./bom-release-issue-add-release-comment.sh <GitHub issue id>" | ||
exit 1 | ||
fi | ||
|
||
git checkout master | ||
git pull | ||
releaseName=$(gh release list --limit 1 --json isLatest,name --jq ".[].name") | ||
gh issue comment $1 --body "New release: [https://github.com/jenkinsci/bom/releases/tag/$releaseName](https://github.com/jenkinsci/bom/releases/tag/$releaseName)" | ||
gh issue comment $1 --body "New release: [https://github.com/jenkinsci/bom/releases/tag/$releaseName](https://github.com/jenkinsci/bom/releases/tag/$releaseName)" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,12 @@ | ||
#!/bin/bash | ||
|
||
if [ $# -ne 1 ]; then | ||
echo "Error: This script requires exactly one argument." | ||
echo "./bom-release-issue-close.sh <GitHub issue id>" | ||
exit 1 | ||
if [[ $# -ne 1 ]]; then | ||
echo "Error: This script requires exactly one argument." | ||
echo "./bom-release-issue-close.sh <GitHub issue id>" | ||
exit 1 | ||
fi | ||
|
||
git checkout master | ||
git pull | ||
gh issue unpin $1 | ||
gh issue close $1 | ||
gh issue close $1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,32 +1,33 @@ | ||
#!/bin/bash | ||
|
||
if [ $# -ne 2 ]; then | ||
echo "Error: This script requires exactly two arguments." | ||
echo "./bom-release-issue-create.sh <yyyy-MM-dd> <GitHub id>" | ||
exit 1 | ||
if [[ $# -ne 2 ]]; then | ||
echo "Error: This script requires exactly two arguments." | ||
echo "./bom-release-issue-create.sh <yyyy-MM-dd> <GitHub id>" | ||
exit 1 | ||
fi | ||
|
||
git checkout master | ||
git pull | ||
releaseManager=$2 | ||
bodyValue=$(cat <<-EOM | ||
A new release is being scheduled. | ||
Release manager: @$2 | ||
bodyValue=$( | ||
cat <<-EOM | ||
A new release is being scheduled. | ||
Release manager: @$2 | ||
# Release progress | ||
- [ ] Lock primary branch | ||
- [ ] Trigger [Jenkins build](https://ci.jenkins.io/job/Tools/job/bom/job/master/BUILDNUMBER/) | ||
- [ ] Unlock primary branch | ||
EOM | ||
# Release progress | ||
- [ ] Lock primary branch | ||
- [ ] Trigger [Jenkins build](https://ci.jenkins.io/job/Tools/job/bom/job/master/BUILDNUMBER/) | ||
- [ ] Unlock primary branch | ||
EOM | ||
) | ||
issueNumber=$(gh api \ | ||
--method POST \ | ||
-H "Accept: application/vnd.github+json" \ | ||
-H "X-GitHub-Api-Version: 2022-11-28" \ | ||
/repos/jenkinsci/bom/issues \ | ||
-f "title=[RELEASE] New release for $1" \ | ||
-f "body=$bodyValue" \ | ||
-f "assignees[]=$2" \ | ||
--jq ".number") | ||
--method POST \ | ||
-H "Accept: application/vnd.github+json" \ | ||
-H "X-GitHub-Api-Version: 2022-11-28" \ | ||
/repos/jenkinsci/bom/issues \ | ||
-f "title=[RELEASE] New release for $1" \ | ||
-f "body=$bodyValue" \ | ||
-f "assignees[]=$2" \ | ||
--jq ".number") | ||
echo $issueNumber | ||
gh issue pin $issueNumber | ||
gh issue pin $issueNumber |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,12 @@ | ||
#!/bin/bash | ||
|
||
if [ $# -ne 2 ]; then | ||
echo "Error: This script requires exactly two arguments." | ||
echo "./bom-release-issue-job-running.sh <GitHub issue id> <Jenkins build number>" | ||
exit 1 | ||
if [[ $# -ne 2 ]]; then | ||
echo "Error: This script requires exactly two arguments." | ||
echo "./bom-release-issue-job-running.sh <GitHub issue id> <Jenkins build number>" | ||
exit 1 | ||
fi | ||
|
||
git checkout master | ||
git pull | ||
updatedBody=$(gh issue view $1 --json body --jq ".body" | sed 's/\[\ \] Trigger/[x] Trigger/' | sed "s/BUILDNUMBER/$2/") | ||
gh issue edit $1 --body $updatedBody | ||
gh issue edit $1 --body $updatedBody |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,12 @@ | ||
#!/bin/bash | ||
|
||
if [ $# -ne 1 ]; then | ||
echo "Error: This script requires exactly one argument." | ||
echo "./bom-test-all-lines.sh <comma separated list of plugins>" | ||
exit 1 | ||
if [[ $# -ne 1 ]]; then | ||
echo "Error: This script requires exactly one argument." | ||
echo "./bom-test-all-lines.sh <comma separated list of plugins>" | ||
exit 1 | ||
fi | ||
|
||
./bom-line-test.sh weekly $1 | ||
./bom-line-test.sh 2.479.x $1 | ||
./bom-line-test.sh 2.462.x $1 | ||
./bom-line-test.sh 2.452.x $1 | ||
./bom-line-test.sh 2.452.x $1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters