-
-
Notifications
You must be signed in to change notification settings - Fork 27
52 lines (46 loc) · 2.2 KB
/
release-please.yml
File metadata and controls
52 lines (46 loc) · 2.2 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
on:
push:
branches:
- main
name: release-please
jobs:
release-please:
runs-on: ubuntu-latest
permissions:
contents: read
id-token: write
steps:
- uses: googleapis/release-please-action@5c625bfb5d1ff62eadeeb3772007f7f66fdcf071 # v4
id: release
with:
token: ${{ secrets.WORKFLOW_PUSH_BOT_TOKEN }}
- uses: actions/checkout@v6
if: ${{ steps.release.outputs.release_created }}
- uses: actions/setup-node@v6
with:
node-version: lts/*
registry-url: https://registry.npmjs.org
if: ${{ steps.release.outputs.release_created }}
# npm 11.5.1 or later is required so update to latest to be sure
- name: Update npm
run: npm install -g npm@latest
if: ${{ steps.release.outputs.release_created }}
- name: Publish to npm
run: |
npm install
npm publish --provenance
if: ${{ steps.release.outputs.release_created }}
# Post to social media
- name: Post release announcement
run: 'npx @humanwhocodes/crosspost -t -m -b "eslint/create-config v${{ steps.release.outputs.major }}.${{ steps.release.outputs.minor }}.${{ steps.release.outputs.patch }} has been released:\n\n${{ steps.release.outputs.html_url }}"'
if: ${{ steps.release.outputs.release_created }}
env:
TWITTER_API_CONSUMER_KEY: ${{ secrets.TWITTER_CONSUMER_KEY }}
TWITTER_API_CONSUMER_SECRET: ${{ secrets.TWITTER_CONSUMER_SECRET }}
TWITTER_ACCESS_TOKEN_KEY: ${{ secrets.TWITTER_ACCESS_TOKEN_KEY }}
TWITTER_ACCESS_TOKEN_SECRET: ${{ secrets.TWITTER_ACCESS_TOKEN_SECRET }}
MASTODON_ACCESS_TOKEN: ${{ secrets.MASTODON_ACCESS_TOKEN }}
MASTODON_HOST: ${{ secrets.MASTODON_HOST }}
BLUESKY_IDENTIFIER: ${{ vars.BLUESKY_IDENTIFIER }}
BLUESKY_PASSWORD: ${{ secrets.BLUESKY_PASSWORD }}
BLUESKY_HOST: ${{ vars.BLUESKY_HOST }}