Skip to content

Commit

Permalink
Allow to test the update-dist-repo process
Browse files Browse the repository at this point in the history
  • Loading branch information
cmuench committed Jan 31, 2024
1 parent 189d344 commit d10d800
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ on:
tags:
# only tags with semver format
- '[0-9]+.[0-9]+.[0-9]+'
workflow_dispatch:

jobs:
create-signed-phar-file:
Expand Down Expand Up @@ -140,7 +141,6 @@ jobs:
update-dist-repo:
runs-on: ubuntu-latest
needs: [ "create-signed-phar-file" ]
if: startsWith(github.ref, 'refs/tags/')
steps:
- name: Checkout HEAD
uses: actions/checkout@v4
Expand All @@ -155,7 +155,7 @@ jobs:
env:
GIT_USER_EMAIL: ${{ secrets.GIT_USER_EMAIL }}
GIT_USER_NAME: ${{ secrets.GIT_USER_NAME }}
run: .github/workflows/update-dist-repo.sh
run: bash .github/workflows/update-dist-repo.sh

create-github-release:
runs-on: ubuntu-latest
Expand Down
5 changes: 5 additions & 0 deletions .github/workflows/update-dist-repo.sh
Original file line number Diff line number Diff line change
Expand Up @@ -25,9 +25,14 @@ git commit -m "Version: $TAG" ./n98-magerun;
git tag "$TAG";

if [ "$REF_TYPE" = 'tags' ]; then
echo "----------------------------------------------------"
echo "Pushing to dist repo."
echo "----------------------------------------------------"
git push;
git push --tags;
else
echo "----------------------------------------------------"
echo " Dry run. Not pushing to dist repo."
echo "----------------------------------------------------"
git push --dry-run;
fi

0 comments on commit d10d800

Please sign in to comment.