@mafintosh/ci-testing 2.0.1-beta.0 → 3.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,36 @@
1
+ name: Publish
2
+ on:
3
+ pull_request:
4
+ types: [closed]
5
+ branches:
6
+ - main
7
+ jobs:
8
+ approve-release:
9
+ if: "${{ github.event.pull_request.merged == true && startsWith(github.event.pull_request.title, 'Release: ') }}"
10
+ runs-on: ubuntu-latest
11
+ environment: release
12
+ permissions:
13
+ contents: write
14
+ id-token: write
15
+ steps:
16
+ - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6
17
+ - uses: actions/setup-node@53b83947a5a98c8d113130e565377fae1a50d02f # v6
18
+ with:
19
+ node-version: lts/*
20
+ registry-url: 'https://registry.npmjs.org'
21
+ - run: npm whoami
22
+ env:
23
+ NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
24
+ - run: |
25
+ VERSION=$(node -p "require('./package.json').version")
26
+ PR_TITLE="${{ github.event.pull_request.title }}"
27
+ TAG=$(echo "$PR_TITLE" | grep -oP '(?<=@)\S+' || echo "latest")
28
+ npm version $VERSION --no-git-tag-version --allow-same-version
29
+ git remote set-url origin https://x-access-token:${{ secrets.GITHUB_TOKEN }}@github.com/${{ github.repository }}.git
30
+ if ! git ls-remote --tags origin | grep -q "refs/tags/v$VERSION$"; then
31
+ git tag "v$VERSION"
32
+ git push origin "v$VERSION"
33
+ fi
34
+ npm publish --access public --provenance --tag $TAG
35
+ env:
36
+ NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
package/README.md CHANGED
@@ -1 +1 @@
1
- hello
1
+ hello world
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@mafintosh/ci-testing",
3
- "version": "2.0.1-beta.0",
3
+ "version": "3.0.1",
4
4
  "description": "hello",
5
5
  "homepage": "https://github.com/mafintosh/ci-testing#readme",
6
6
  "bugs": {