Skip to content

Commit

Permalink
ci: trying to patch up the release stage again
Browse files Browse the repository at this point in the history
  • Loading branch information
Alorel committed Nov 28, 2022
1 parent 3dce275 commit 6f7c562
Showing 1 changed file with 21 additions and 2 deletions.
23 changes: 21 additions & 2 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@ jobs:
name: Get changelog
id: get-body
with:
result-encoding: string
script: return context.payload.release.body;
- uses: actions/checkout@v3
name: Checkout
Expand All @@ -27,11 +26,31 @@ jobs:
run: npm ci --no-fund
env:
NODE_AUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Make TSC cache key
run: cat package-lock.json | grep rollup-plugin-typescript2 > .ci-cache-key
- name: Typescript cache
uses: actions/cache@v3
with:
path: "./node_modules/.cache/rollup-plugin-typescript2"
key: v1-tsc-${{ runner.os }}-18-${{ hashFiles('./.ci-cache-key') }}-${{ github.ref }}
restore-keys: |
v1-tsc-${{ runner.os }}-18-${{ hashFiles('./.ci-cache-key') }}-refs/heads/master-
v1-tsc-${{ runner.os }}-18-${{ hashFiles('./.ci-cache-key') }}-
v1-tsc-${{ runner.os }}-18-
v1-tsc-${{ runner.os }}
- name: ESLint cache
uses: actions/cache@v3
with:
path: "./node_modules/.cache/eslint"
key: v1-eslint-${{ github.ref }}-${{ github.sha }}
restore-keys: v1-eslint-refs/heads/master-
- name: Lint
run: npm run lint
- run: npm run rollup:prod
name: Build
env:
MELVOR_MOD_VERSION: ${{ github.ref_name }}
- run: npm run modio -- upload --active --token "${{ secrets.MOD_IO_API_TOKEN }}" --mod-version "${{ github.ref_name }}" --changelog "${{ steps.get-body.outputs.result }}"
- name: Format changelog
run: echo ${{ steps.get-body.outputs.result }} > .ci-cache-key
- run: npm run modio -- upload --active --token "${{ secrets.MOD_IO_API_TOKEN }}" --mod-version "${{ github.ref_name }}" --changelog "$(cat .ci-cache-key)"
name: Publish

0 comments on commit 6f7c562

Please sign in to comment.