@defra/grants-config-utils 0.0.9 → 0.0.14

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.
@@ -14,6 +14,7 @@ jobs:
14
14
  cdp-workflows:
15
15
  name: Run Pull Request Checks
16
16
  runs-on: ubuntu-latest
17
+ if: github.actor != 'github-actions[bot]'
17
18
  steps:
18
19
  - uses: actions/checkout@v6
19
20
  - uses: actions/setup-node@v6
@@ -8,6 +8,7 @@ on:
8
8
  permissions:
9
9
  contents: write
10
10
  packages: write
11
+ pull-requests: write
11
12
  id-token: write # Required for OIDC
12
13
 
13
14
  jobs:
@@ -34,29 +35,19 @@ jobs:
34
35
  run: npm test
35
36
 
36
37
  - name: SonarCloud Scan
37
- if: github.actor != 'dependabot[bot]'
38
+ if: github.actor != 'dependabot[bot]' && github.actor != 'github-actions[bot]' && !contains(github.event.head_commit.message, 'Create new config version')
38
39
  uses: SonarSource/sonarqube-scan-action@v8.1.0
39
40
  env:
40
41
  GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
41
42
  SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
42
43
 
43
- - name: Version changed packages
44
- run: npm run version:changed
45
- env:
46
- GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
47
-
48
- - name: Publish changed packages to npm
49
- run: npm run publish:changed
50
-
51
- - name: Commit version bumps & push
52
- run: |
53
- git config user.name "github-actions[bot]"
54
- git config user.email "github-actions[bot]@users.noreply.github.com"
55
- git add .
56
- git commit -m "Version package [skip ci]" || echo "No changes to commit"
57
- git push
44
+ - name: Set user
45
+ run: git config user.name github-actions[bot] && git config user.email github-actions[bot]@users.noreply.github.com
58
46
 
59
- - name: Create Git tag & GitHub Release
60
- run: npm run github:release
61
- env:
62
- GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
47
+ - name: Create Release Pull Request or Release
48
+ uses: changesets/action@v1
49
+ with:
50
+ commitMode: 'github-api'
51
+ publish: npm run github:release
52
+ commit: 'Create new config version'
53
+ title: 'Create new config version'
package/CHANGELOG.md CHANGED
@@ -1,10 +1,34 @@
1
1
  # @defra/grants-config-utils
2
2
 
3
- ## 0.0.9
3
+ ## 0.0.14
4
4
 
5
5
  ### Patch Changes
6
6
 
7
- - [#8](https://github.com/DEFRA/grants-config-utils/pull/8) [`d6f369e`](https://github.com/DEFRA/grants-config-utils/commit/d6f369ebc4c4815f57b9ce07eff455d66b3cbf42) Thanks [@aaroncarroll82](https://github.com/aaroncarroll82)! - build: bump
7
+ - [`05f2ca6`](https://github.com/DEFRA/grants-config-utils/commit/05f2ca64700ee0f6dc7d791dcea080ae22168ef1) Thanks [@aaroncarroll82](https://github.com/aaroncarroll82)! - Invoke publish mechanism
8
+
9
+ ## 0.0.13
10
+
11
+ ### Patch Changes
12
+
13
+ - [#17](https://github.com/DEFRA/grants-config-utils/pull/17) [`91e030a`](https://github.com/DEFRA/grants-config-utils/commit/91e030ac2834ac0d4ae8c8b56f95f20048a8840a) Thanks [@aaroncarroll82](https://github.com/aaroncarroll82)! - Ensure npm publish happens too
14
+
15
+ ## 0.0.12
16
+
17
+ ### Patch Changes
18
+
19
+ - [#15](https://github.com/DEFRA/grants-config-utils/pull/15) [`2172acd`](https://github.com/DEFRA/grants-config-utils/commit/2172acd0198efdc5df24e12b1f33d0ba24511427) Thanks [@aaroncarroll82](https://github.com/aaroncarroll82)! - Prevent sonarcloud interfering with release
20
+
21
+ ## 0.0.11
22
+
23
+ ### Patch Changes
24
+
25
+ - [#13](https://github.com/DEFRA/grants-config-utils/pull/13) [`29ba4f3`](https://github.com/DEFRA/grants-config-utils/commit/29ba4f312943f1a54d2e4867b1529c8534bc5ce7) Thanks [@aaroncarroll82](https://github.com/aaroncarroll82)! - Build mechanism
26
+
27
+ ## 0.0.10
28
+
29
+ ### Patch Changes
30
+
31
+ - [#8](https://github.com/DEFRA/grants-config-utils/pull/8) [`d6f369e`](https://github.com/DEFRA/grants-config-utils/commit/d6f369ebc4c4815f57b9ce07eff455d66b3cbf42) Thanks [@aaroncarroll82](https://github.com/aaroncarroll82)! - build: Change to PR based mechanism
8
32
 
9
33
  ## 0.0.6
10
34
 
package/CONTRIBUTING.md CHANGED
@@ -19,4 +19,6 @@ To make changes to this library, please follow the steps below:
19
19
  4. Push to branch, and create a pull request.
20
20
  5. Github actions will verify the build
21
21
  6. After review, merge the pull request.
22
- 7. Github actions will automatically increment the version and publish to NPM.
22
+ 7. A second PR will be created by the release action.
23
+ 8. Merge this PR
24
+ 9. Github actions will automatically increment the version and publish to NPM.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@defra/grants-config-utils",
3
- "version": "0.0.9",
3
+ "version": "0.0.14",
4
4
  "description": "NPM module for providing utils for publishing grants config",
5
5
  "engines": {
6
6
  "node": ">=24",
@@ -16,7 +16,7 @@
16
16
  "type": "module",
17
17
  "scripts": {
18
18
  "prepare": "husky",
19
- "github:release": "npx cdp-github-release @defra/grants-config-utils",
19
+ "github:release": "npm run publish:changed && npx cdp-github-release @defra/grants-config-utils",
20
20
  "lint": "eslint --cache --cache-strategy content \"**/*.{cjs,js}\"",
21
21
  "lint:fix": "npm run lint -- --fix",
22
22
  "prettier": "prettier --check \"**/*.{cjs,js,json}\"",