Skip to content

deps: Bump the typescript-eslint group with 2 updates (#314) #280

deps: Bump the typescript-eslint group with 2 updates (#314)

deps: Bump the typescript-eslint group with 2 updates (#314) #280

name: "Release please"
on:
push:
branches:
- main
permissions:
id-token: write
contents: write
pull-requests: write
jobs:
release:
concurrency:
group: |
${{ github.workflow }} @ ${{ github.event.pull_request.head.label || github.head_ref || github.ref }}
cancel-in-progress: true
runs-on: ubuntu-latest
outputs:
paths_released: ${{ steps.rp_step.outputs.paths_released }}
releases_created: ${{ steps.rp_step.outputs.releases_created }}
steps:
- name: "Release please"
uses: googleapis/release-please-action@v4
id: rp_step
with:
# Expires ~December 2024
token: ${{ secrets.REPO_ADMIN_TOKEN }}
config-file: release-please-config.json
manifest-file: release-please-manifest.json
- name: "Trigger lint fixes"
if: ${{ steps.rp_step.outputs.prs_created && steps.rp_step.outputs.pr != null }}
uses: actions/github-script@v7
with:
github-token: ${{ secrets.REPO_ADMIN_TOKEN }}
script: |
github.rest.issues.createComment({
issue_number: ${{ fromJSON(steps.rp_step.outputs.pr).number }},
owner: context.repo.owner,
repo: context.repo.repo,
body: "/lint",
});
publish:
needs:
- release
if:
${{ needs.release.outputs.releases_created && needs.release.outputs.paths_released
!= '' && needs.release.outputs.paths_released != '[]' }}
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
path: ${{ fromJson(needs.release.outputs.paths_released) }}
steps:
- name: "Checkout"
uses: actions/checkout@v4
- name: "Setup Node.js"
uses: actions/setup-node@v4
with:
node-version: 20
registry-url: "https://registry.npmjs.org"
cache: "npm"
cache-dependency-path: ./package.json
- name: "Install dependencies"
run: |
npm install
- name: "Build all packages"
# We build everything. Not ideal, but this makes sure that we don't have to worry here about resolving internal dependencies
run: |
npm run build:ws
- name: "Publish to NPM"
env:
# Expires ~December 2024
# Uses NODE_AUTH_TOKEN which is supported by actions/setup-node
NODE_AUTH_TOKEN: ${{ secrets.NPM_PUBLISH_TOKEN }}
run: |
cd ${{ matrix.path }}
npm publish --provenance --access public