@slashgear/gdpr-cookie-scanner 2.0.1 → 2.0.2

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.
@@ -10,6 +10,7 @@ jobs:
10
10
  permissions:
11
11
  contents: write
12
12
  pull-requests: write
13
+ packages: write
13
14
 
14
15
  steps:
15
16
  - uses: actions/checkout@v6
@@ -31,6 +32,7 @@ jobs:
31
32
  run: pnpm build
32
33
 
33
34
  - name: Create release PR or publish to npm
35
+ id: changesets
34
36
  uses: changesets/action@v1
35
37
  with:
36
38
  publish: pnpm changeset publish
@@ -40,3 +42,28 @@ jobs:
40
42
  env:
41
43
  GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
42
44
  NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
45
+
46
+ - name: Extract published version
47
+ if: steps.changesets.outputs.published == 'true'
48
+ id: version
49
+ run: |
50
+ VERSION=$(echo '${{ steps.changesets.outputs.publishedPackages }}' | jq -r '.[0].version')
51
+ echo "version=$VERSION" >> $GITHUB_OUTPUT
52
+
53
+ - name: Log in to GitHub Container Registry
54
+ if: steps.changesets.outputs.published == 'true'
55
+ uses: docker/login-action@v3
56
+ with:
57
+ registry: ghcr.io
58
+ username: ${{ github.actor }}
59
+ password: ${{ secrets.GITHUB_TOKEN }}
60
+
61
+ - name: Build and push Docker image
62
+ if: steps.changesets.outputs.published == 'true'
63
+ uses: docker/build-push-action@v6
64
+ with:
65
+ context: .
66
+ push: true
67
+ tags: |
68
+ ghcr.io/${{ github.repository }}:latest
69
+ ghcr.io/${{ github.repository }}:${{ steps.version.outputs.version }}
package/CHANGELOG.md CHANGED
@@ -1,5 +1,13 @@
1
1
  # @slashgear/gdpr-cookie-scanner
2
2
 
3
+ ## 2.0.2
4
+
5
+ ### Patch Changes
6
+
7
+ - ec906f4: Publish Docker image automatically on every release.
8
+
9
+ When `changesets/action` publishes a new version to npm, the release workflow now logs in to the GitHub Container Registry (ghcr.io) and pushes the Docker image tagged with both `latest` and the exact semver version (e.g. `ghcr.io/slashgear/gdpr-cookie-scanner:2.0.2`). The `packages: write` permission is added to the job for this purpose.
10
+
3
11
  ## 2.0.1
4
12
 
5
13
  ### Patch Changes
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@slashgear/gdpr-cookie-scanner",
3
- "version": "2.0.1",
3
+ "version": "2.0.2",
4
4
  "description": "CLI tool to scan websites for GDPR cookie consent compliance",
5
5
  "keywords": [
6
6
  "compliance",