diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 97af54b..e9cc473 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -8,5 +8,36 @@ on: jobs: build: runs-on: ubuntu-latest + permissions: + issues: write + contents: write steps: - uses: actions/checkout@v4 + + - uses: actions/setup-node@v4 + with: + node-version: 20 + + - name: Install packages + run: npm ci + + - name: Rebuild + run: npm run release + + - uses: actions/checkout@v4.1.4 + - name: Conventional Changelog Action + id: changelog + uses: TriPSs/conventional-changelog-action@v5.2.1 + with: + github-token: ${{ secrets.github_token }} + version-file: "package.json" + skip-on-empty: false + + - name: Create Release + uses: ncipollo/release-action@v1 + env: + GITHUB_TOKEN: ${{ secrets.github_token }} + with: + tag: ${{ steps.changelog.outputs.tag }} + name: ${{ steps.changelog.outputs.tag }} + body: ${{ steps.changelog.outputs.clean_changelog }} diff --git a/.github/workflows/testing.yml b/.github/workflows/testing.yml index 69eefa9..7a0cfcd 100644 --- a/.github/workflows/testing.yml +++ b/.github/workflows/testing.yml @@ -12,6 +12,17 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@v4 + + - uses: actions/setup-node@v4 + with: + node-version: 20 + + - name: Install packages + run: npm ci + + - name: Rebuild + run: npm run release + - uses: chrnorm/deployment-action@v2 name: Create GitHub deployment id: deployment