Skip to content

fix proxy (#231)

fix proxy (#231) #39

Workflow file for this run

name: 'Post Merge'
on:
push:
branches:
- master
jobs:
write-info:
runs-on: ubuntu-latest
name: 'Write Info'
outputs:
version: ${{ steps.push-file.outputs.version }}
steps:
- uses: actions/checkout@v3
with:
token: ${{ secrets.VERSION_BUMP}}
- name: 'Get Info'
run: |
echo "shortCommit=$(git rev-parse --short HEAD)" >> $GITHUB_ENV
echo "currentVersion=$(cat info.json | jq -r '.version')" >> $GITHUB_ENV
- name: 'Calc Next Version'
id: next-version
shell: bash
run: |
split=(${VERSION//.// })
index=$((${#split[@]}-1))
nexPatchVersion=$((${split[$index]} + 1))
echo nextVersion=${{format('{0}.{1}.{2}', '${split[0]/\//}', '${split[1]/\//}', '$nexPatchVersion')}} >> $GITHUB_ENV
env:
VERSION: ${{ env.currentVersion }}
- name: 'Update Short Commit'
uses: jossef/[email protected]
with:
file: info.json
field: shortCommit
value: ${{ env.shortCommit }}
- name: 'Update New Version'
uses: jossef/[email protected]
with:
file: info.json
field: version
value: ${{ env.nextVersion }}
- name: 'Get Data from Github'
run: |
echo GITHUB_EMAIL=$(git --no-pager show -s --format=\'%ae\') >> $GITHUB_ENV
echo GITHUB_COMMIT_MESSAGE=$(git log -1 --pretty=%B) >> $GITHUB_ENV
- name: 'Setup GIT'
run: |
echo "Setting email to: ${GITHUB_EMAIL}"
echo "Setting user to: ${GITHUB_ACTOR}"
echo "Commit message: $GITHUB_COMMIT_MESSAGE"
git config user.email "$GITHUB_EMAIL"
git config user.name "$GITHUB_ACTOR"
- name: 'Push Info File'
id: push-file
if: contains(env.GITHUB_COMMIT_MESSAGE, 'bumping release v') == false
run: |
git add -A
git commit -m "docs(): bumping release v$VERSION"
git push "https://[email protected]/$GITHUB_REPOSITORY"
echo "version=$VERSION" >> $GITHUB_OUTPUT
env:
VERSION: ${{ env.nextVersion }}
create-tag:
runs-on: ubuntu-latest
needs: write-info
if: needs.write-info.outputs.version != null
steps:
- uses: actions/checkout@v3
- uses: rickstaa/[email protected]
with:
tag: ${{ needs.write-info.outputs.version }}