Big News: Socket raises $60M Series C at a $1B valuation to secure software supply chains for AI-driven development.Announcement
Sign In

ctrf-cli

Package Overview
Dependencies
Maintainers
1
Versions
6
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

ctrf-cli - npm Package Compare versions

Comparing version
0.0.2
to
0.0.3
+17
-4
package.json
{
"name": "ctrf-cli",
"version": "0.0.2",
"version": "0.0.3",
"description": "Various CTRF utilities available from the command line",

@@ -11,3 +11,9 @@ "main": "dist/index.js",

"build": "tsc",
"all": "npm run build"
"test": "vitest run",
"test:coverage": "vitest run --coverage",
"lint": "eslint . --ext .ts --fix",
"lint:check": "eslint . --ext .ts",
"format": "prettier --write .",
"format:check": "prettier --check .",
"all": "npm run lint && npm run format:check && npm run test && npm run build"
},

@@ -35,6 +41,13 @@ "files": [

"devDependencies": {
"@d2t/vitest-ctrf-json-reporter": "^1.2.0",
"@types/node": "^20.12.7",
"@vitest/coverage-v8": "^3.2.4",
"@eslint/js": "^9.32.0",
"eslint": "^9.32.0",
"prettier": "^3.5.3",
"@types/yargs": "^17.0.32",
"typescript": "^5.4.5"
"typescript": "^5.4.5",
"typescript-eslint": "^8.38.0",
"vitest": "^3.2.4"
}
}
}
+18
-10

@@ -44,19 +44,27 @@ # CTRF CLI

```sh
npx ctrf-cli merge <directory>
npx ctrf-cli@0.0.3 merge <directory>
```
Replace `directory` with the path to the directory containing the CTRF reports you want to merge.
Replace `directory` with the path to the directory containing the CTRF reports you want to merge. Your merged report will be saved as `ctrf-report.json` in the same directory by default.
### Options
-o, --output `filename`: Output file name for the merged report. Default is ctrf-report.json.
-o, --output `path`: Output file path for the merged report. Can be a filename (saved in input directory), relative path from current working directory, or absolute path. Default is `ctrf-report.json`.
```sh
npx ctrf-cli merge <directory> --output my-merged-report.json
```
# Save with custom filename in input directory
npx ctrf-cli@0.0.3 merge ./reports --output my-merged-report.json
# Merged report saved to: ./reports/my-merged-report.json
-d, --output-dir `directory`: Output directory for the merged report. Default is the same directory as the input reports.
# Save with relative path from current directory
npx ctrf-cli@0.0.3 merge ./reports --output ./output/merged.json
# Merged report saved to: ./output/merged.json
```sh
npx ctrf-cli merge <directory> --output-dir /path/to/output
# Save to directory with default filename
npx ctrf-cli@0.0.3 merge ./reports --output ./output/
# Merged report saved to: ./output/ctrf-report.json
# Save to absolute path
npx ctrf-cli@0.0.3 merge ./reports --output /tmp/merged.json
# Merged report saved to: /tmp/merged.json
```

@@ -67,3 +75,3 @@

```sh
npx ctrf-cli merge <directory> --keep-reports
npx ctrf-cli@0.0.3 merge <directory> --keep-reports
```

@@ -79,3 +87,3 @@

```sh
npx ctrf-cli flaky <file-path>
npx ctrf-cli@0.0.3 flaky <file-path>
```

@@ -82,0 +90,0 @@