Skip to content

Commit 4103c3e

Browse files
committed
Update dependencies and build tooling
Update package.json and pnpm-lock.yaml: - Add test dependencies and configurations - Update related package locks Update build scripts: - Migrate get-coverage-percentage to parseArgs API - Remove yargs-parser dependency - Improve script maintainability Update workflow configurations: - Disable provenance workflow temporarily
1 parent 15f99bd commit 4103c3e

File tree

4 files changed

+30
-25
lines changed

4 files changed

+30
-25
lines changed

.github/workflows/provenance.yml.disabled

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ jobs:
2222

2323
steps:
2424
- uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
25-
- uses: SocketDev/socket-registry/.github/actions/setup@main
25+
- uses: SocketDev/socket-registry/.github/actions/setup@797e90f4f82ac089a308acdc434d2027c2cd7d5d
2626
with:
2727
scope: '@socketsecurity'
2828
- run: pnpm install

package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -130,8 +130,8 @@
130130
"@socketregistry/is-interactive": "1.0.6",
131131
"@socketregistry/packageurl-js": "1.1.4",
132132
"@socketsecurity/config": "3.0.1",
133-
"@socketsecurity/registry": "file:/Users/jdalton/projects/socket-registry/registry/socketsecurity-registry-1.3.7.tgz",
134-
"@socketsecurity/sdk": "1.8.5",
133+
"@socketsecurity/registry": "1.3.9",
134+
"@socketsecurity/sdk": "1.9.1",
135135
"@types/cmd-shim": "5.0.2",
136136
"@types/js-yaml": "4.0.9",
137137
"@types/micromatch": "4.0.9",

pnpm-lock.yaml

Lines changed: 12 additions & 13 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

scripts/get-coverage-percentage.mjs

Lines changed: 15 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -3,11 +3,11 @@
33
import { existsSync } from 'node:fs'
44
import path from 'node:path'
55

6-
import yargsParser from 'yargs-parser'
76
import colors from 'yoctocolors-cjs'
87

98
import constants from '@socketsecurity/registry/lib/constants'
109
import { logger } from '@socketsecurity/registry/lib/logger'
10+
import { parseArgs } from '@socketsecurity/registry/lib/parse-args'
1111

1212
import { getCodeCoverage } from './utils/get-code-coverage.mjs'
1313
import { getTypeCoverage } from './utils/get-type-coverage.mjs'
@@ -156,14 +156,20 @@ async function logCoveragePercentage(argv) {
156156

157157
// Main entry point - parse command line arguments and display coverage.
158158
void (async () => {
159-
const argv = yargsParser(process.argv.slice(2), {
160-
boolean: ['json', 'simple'],
161-
alias: {
162-
// -j for JSON output.
163-
j: 'json',
164-
// -s for simple output.
165-
s: 'simple',
159+
const { values } = parseArgs({
160+
args: process.argv.slice(2),
161+
options: {
162+
json: {
163+
type: 'boolean',
164+
// -j for JSON output.
165+
short: 'j',
166+
},
167+
simple: {
168+
type: 'boolean',
169+
// -s for simple output.
170+
short: 's',
171+
},
166172
},
167173
})
168-
await logCoveragePercentage(argv)
174+
await logCoveragePercentage(values)
169175
})()

0 commit comments

Comments
 (0)