@npmcli/template-oss 4.6.1 → 4.7.0

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.
@@ -36,7 +36,7 @@ const run = ({ pkg, path, config: { requiredPackages = {} } }) => {
36
36
 
37
37
  return {
38
38
  title: `The following required ${location} were not found:`,
39
- body: specs.map((s) => s.rawSpec ? `${s.name}@${s.rawSpec}` : s.name),
39
+ body: specs.map((s) => s.rawSpec === '*' ? s.name : `${s.name}@${s.rawSpec}`),
40
40
  // solution is to remove any existing all at once but add back in by --save-<location>
41
41
  solution: [
42
42
  rmCommand(specs),
@@ -2,6 +2,12 @@
2
2
  name: CI - Release
3
3
 
4
4
  on:
5
+ workflow_dispatch:
6
+ inputs:
7
+ ref:
8
+ required: true
9
+ type: string
10
+ default: {{ defaultBranch }}
5
11
  workflow_call:
6
12
  inputs:
7
13
  ref:
@@ -15,7 +21,7 @@ jobs:
15
21
  lint-all:
16
22
  {{> job
17
23
  jobName="Lint All"
18
- jobCheck=(obj sha="${{ inputs.check-sha }}")
24
+ jobCheck=(obj sha="${{ inputs.check-sha }}" if="inputs.check-sha")
19
25
  jobCheckout=(obj ref="${{ inputs.ref }}")
20
26
  }}
21
27
  {{> stepLint jobRunFlags=allFlags }}
@@ -24,7 +30,7 @@ jobs:
24
30
  test-all:
25
31
  {{> jobMatrix
26
32
  jobName="Test All"
27
- jobCheck=(obj sha="${{ inputs.check-sha }}")
33
+ jobCheck=(obj sha="${{ inputs.check-sha }}" if="inputs.check-sha")
28
34
  jobCheckout=(obj ref="${{ inputs.ref }}")
29
35
  }}
30
36
  {{> stepTest jobRunFlags=allFlags }}
@@ -116,7 +116,7 @@ module.exports = {
116
116
  windowsCI: true,
117
117
  macCI: true,
118
118
  branches: ['main', 'latest'],
119
- releaseBranches: [],
119
+ defaultBranch: 'main',
120
120
  distPaths: [
121
121
  'bin/',
122
122
  'lib/',
@@ -48,7 +48,7 @@ jobs:
48
48
  if [[ "$\{{ steps.metadata.outputs.update-type }}" == "version-update:semver-major" ]]; then
49
49
  prefix='feat!'
50
50
  else
51
- prefix='chore!'
51
+ prefix='chore'
52
52
  fi
53
53
  echo "::set-output name=message::$prefix: postinstall for dependabot template-oss PR"
54
54
 
@@ -7,9 +7,7 @@ on:
7
7
  {{#each branches}}
8
8
  - {{ . }}
9
9
  {{/each}}
10
- {{#each releaseBranches }}
11
- - {{ . }}
12
- {{/each}}
10
+ - release/v*
13
11
 
14
12
  permissions:
15
13
  contents: write
@@ -20,10 +20,6 @@ const getSpecVersion = (spec, where) => {
20
20
  switch (arg.type) {
21
21
  case 'range':
22
22
  return new semver.Range(arg.fetchSpec)
23
- case 'tag': {
24
- // special case an empty spec to mean any version
25
- return arg.rawSpec === '' && new semver.Range('*')
26
- }
27
23
  case 'version':
28
24
  return new semver.SemVer(arg.fetchSpec)
29
25
  case 'directory': {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@npmcli/template-oss",
3
- "version": "4.6.1",
3
+ "version": "4.7.0",
4
4
  "description": "templated files used in npm CLI team oss projects",
5
5
  "main": "lib/content/index.js",
6
6
  "bin": {
@@ -46,7 +46,7 @@
46
46
  "just-deep-map-values": "^1.1.1",
47
47
  "just-diff": "^5.0.1",
48
48
  "lodash": "^4.17.21",
49
- "npm-package-arg": "^9.0.1",
49
+ "npm-package-arg": "^10.0.0",
50
50
  "proc-log": "^3.0.0",
51
51
  "release-please": "npm:@npmcli/release-please@^14.2.6",
52
52
  "semver": "^7.3.5",