Skip to content

Commit

Permalink
Add allow empty commit
Browse files Browse the repository at this point in the history
  • Loading branch information
rpoet-jh committed May 14, 2024
1 parent c309aa8 commit 1454e8b
Show file tree
Hide file tree
Showing 2 changed files with 52 additions and 52 deletions.
2 changes: 1 addition & 1 deletion .github/actions/yarn-version/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ runs:
yarn install --frozen-lockfile
yarn config set version-git-tag false
yarn version --new-version $RELEASE
git commit -am "Update version to $RELEASE"
git commit --allow-empty -am "Update version to $RELEASE"
if [ "$SKIP_TAG" == "false" ]; then
echo "Tagging yarn version $RELEASE"
git tag $RELEASE
Expand Down
102 changes: 51 additions & 51 deletions .github/workflows/pass-complete-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -91,10 +91,10 @@ jobs:
- name: Set Release/commit/tag ~ Java Repositories
if: ${{ ! env.ALL_JAVA_REPOS_TAG_EXISTS }}
run: |
(cd main && mvn versions:set -B -ntp -DnewVersion=$RELEASE && git commit -am "Update version to $RELEASE" && git tag --force $RELEASE)
(cd main && mvn versions:set -B -ntp -DnewVersion=$RELEASE && git commit --allow-empty -am "Update version to $RELEASE" && git tag --force $RELEASE)
(cd combined && mvn versions:set -B -ntp -DnewVersion=$RELEASE)
(cd combined/pass-core && git commit -am "Update version to $RELEASE" && git tag --force $RELEASE)
(cd combined/pass-support && git commit -am "Update version to $RELEASE" && git tag --force $RELEASE)
(cd combined/pass-core && git commit --allow-empty -am "Update version to $RELEASE" && git tag --force $RELEASE)
(cd combined/pass-support && git commit --allow-empty -am "Update version to $RELEASE" && git tag --force $RELEASE)
- name: Release Java modules
if: ${{ ! env.ALL_JAVA_REPOS_TAG_EXISTS }}
Expand Down Expand Up @@ -187,7 +187,7 @@ jobs:
run: |
cd combined/pass-docker
sed -i "/^PASS_VERSION/s/.*/PASS_VERSION=$RELEASE/" .env
git commit -am "Update version to $RELEASE"
git commit --allow-empty -am "Update version to $RELEASE"
git tag $RELEASE
- name: Build Release pass-docker images
Expand All @@ -211,36 +211,36 @@ jobs:
env:
GITHUB_TOKEN: ${{ secrets.JAVA_RELEASE_PAT }}

# - name: Set Snapshot/commit ~ Java Repositories
# run: |
# (cd main && mvn versions:set -B -ntp -DallowSnapshots=true -DnewVersion=$NEXT && git commit -am "Update version to $NEXT")
# (cd combined && mvn versions:set -B -ntp -DallowSnapshots=true -DnewVersion=$NEXT)
# (cd combined/pass-core && git commit -am "Update version to $NEXT")
# (cd combined/pass-support && git commit -am "Update version to $NEXT")
#
# - name: Release Snapshot Java modules
# working-directory: combined
# run: |
# mvn -B -V -ntp -P release clean deploy -DskipTests -DskipITs
# env:
# MAVEN_USERNAME: ${{ secrets.OSSRH_USERNAME }}
# MAVEN_PASSWORD: ${{ secrets.OSSRH_PASSWORD }}
# MAVEN_GPG_PASSPHRASE: ${{ secrets.MAVEN_GPG_PASSPHRASE }}
#
# - name: Push Snapshot Docker images to GHCR ~ Java Repositories
# run: |
# docker push ghcr.io/eclipse-pass/pass-core-main:$NEXT
# docker push ghcr.io/eclipse-pass/deposit-services-core:$NEXT
# docker push ghcr.io/eclipse-pass/pass-notification-service:$NEXT
# docker push ghcr.io/eclipse-pass/jhu-grant-loader:$NEXT
# docker push ghcr.io/eclipse-pass/pass-journal-loader:$NEXT
# docker push ghcr.io/eclipse-pass/pass-nihms-loader:$NEXT
#
# - name: Push the Snapshot commits ~ Java Repositories
# run: |
# (cd main && git push origin)
# (cd combined/pass-core && git push origin)
# (cd combined/pass-support && git push origin)
- name: Set Snapshot/commit ~ Java Repositories
run: |
(cd main && mvn versions:set -B -ntp -DallowSnapshots=true -DnewVersion=$NEXT && git commit --allow-empty -am "Update version to $NEXT")
(cd combined && mvn versions:set -B -ntp -DallowSnapshots=true -DnewVersion=$NEXT)
(cd combined/pass-core && git commit --allow-empty -am "Update version to $NEXT")
(cd combined/pass-support && git commit --allow-empty -am "Update version to $NEXT")
- name: Release Snapshot Java modules
working-directory: combined
run: |
mvn -B -V -ntp -P release clean deploy -DskipTests -DskipITs
env:
MAVEN_USERNAME: ${{ secrets.OSSRH_USERNAME }}
MAVEN_PASSWORD: ${{ secrets.OSSRH_PASSWORD }}
MAVEN_GPG_PASSPHRASE: ${{ secrets.MAVEN_GPG_PASSPHRASE }}

- name: Push Snapshot Docker images to GHCR ~ Java Repositories
run: |
docker push ghcr.io/eclipse-pass/pass-core-main:$NEXT
docker push ghcr.io/eclipse-pass/deposit-services-core:$NEXT
docker push ghcr.io/eclipse-pass/pass-notification-service:$NEXT
docker push ghcr.io/eclipse-pass/jhu-grant-loader:$NEXT
docker push ghcr.io/eclipse-pass/pass-journal-loader:$NEXT
docker push ghcr.io/eclipse-pass/pass-nihms-loader:$NEXT
- name: Push the Snapshot commits ~ Java Repositories
run: |
(cd main && git push origin)
(cd combined/pass-core && git push origin)
(cd combined/pass-support && git push origin)
- name: Set Snapshot/commit ~ pass-ui
uses: ./main/.github/actions/yarn-version
Expand Down Expand Up @@ -274,20 +274,20 @@ jobs:
- name: Push the Snapshot commits ~ pass-acceptance-testing
run: cd combined/pass-acceptance-testing && git push origin

# - name: Set Snapshot/commit ~ pass-docker
# run: |
# cd combined/pass-docker
# sed -i "/^PASS_VERSION/s/.*/PASS_VERSION=$NEXT/" .env
# git commit -am "Update version to $NEXT"
#
# - name: Build Snapshot pass-docker images
# working-directory: combined/pass-docker
# run: docker compose -f docker-compose.yml -f eclipse-pass.local.yml build idp ldap
#
# - name: Push Snapshot Docker images to GHCR ~ pass-docker
# run: |
# docker push ghcr.io/eclipse-pass/demo-ldap:$NEXT
# docker push ghcr.io/eclipse-pass/idp:$NEXT
#
# - name: Push the Snapshot commits ~ pass-docker
# run: cd combined/pass-docker && git push origin
- name: Set Snapshot/commit ~ pass-docker
run: |
cd combined/pass-docker
sed -i "/^PASS_VERSION/s/.*/PASS_VERSION=$NEXT/" .env
git commit --allow-empty -am "Update version to $NEXT"
- name: Build Snapshot pass-docker images
working-directory: combined/pass-docker
run: docker compose -f docker-compose.yml -f eclipse-pass.local.yml build idp ldap

- name: Push Snapshot Docker images to GHCR ~ pass-docker
run: |
docker push ghcr.io/eclipse-pass/demo-ldap:$NEXT
docker push ghcr.io/eclipse-pass/idp:$NEXT
- name: Push the Snapshot commits ~ pass-docker
run: cd combined/pass-docker && git push origin

0 comments on commit 1454e8b

Please sign in to comment.