feat sync-file new page view #179
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
name: build | |
on: | |
workflow_dispatch: | |
push: | |
branches: '*' | |
jobs: | |
short_sha: | |
runs-on: ubuntu-latest | |
outputs: | |
COMMIT_SHORT_SHA: ${{ steps.vars.outputs.COMMIT_SHORT_SHA }} | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Set short git commit SHA | |
id: vars | |
run: | | |
calculatedSha=$(git rev-parse --short ${{ github.sha }}) | |
echo $calculatedSha | |
echo "COMMIT_SHORT_SHA=$calculatedSha" >> $GITHUB_OUTPUT | |
generate: | |
uses: ./.github/workflows/generate.yaml | |
needs: short_sha | |
secrets: inherit | |
with: | |
releaseVersion: dev-${{ needs.short_sha.outputs.COMMIT_SHORT_SHA }} | |
deploy: | |
runs-on: ubuntu-latest | |
needs: | |
- generate | |
- short_sha | |
# allow the mod publish step to add asserts to release | |
# https://docs.github.com/en/actions/security-guides/automatic-token-authentication#permissions-for-the-github_token | |
permissions: | |
contents: write | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- uses: actions/download-artifact@v3 | |
with: | |
name: ChatBridreE-dev-${{ needs.short_sha.outputs.COMMIT_SHORT_SHA }} | |
path: out | |
- name: upload Release | |
uses: ncipollo/release-action@v1 | |
with: | |
allowUpdates: true | |
removeArtifacts: true | |
makeLatest: false | |
generateReleaseNotes: true | |
token: ${{ secrets.GITHUB_TOKEN }} | |
tag: develop | |
artifacts: 'out/*.mcdr,out/*.pyz,out/*.zip' | |
- name: update ref | |
env: | |
token: ${{ secrets.GITHUB_TOKEN }} | |
user_name: GitHub Action | |
user_email: [email protected] | |
run: | | |
git config --global user.name "$user_name" | |
git config --global user.email "$user_email" | |
git remote remove origin | |
git remote add origin https://"$token"@github.com/${{ github.event.repository.full_name }} | |
git tag -f develop; git push -f origin develop |