Skip to content

Commit b479dad

Browse files
authored
refactor: rename TypeScript documentation npm scripts (#7107)
Rename and reorganize type-checking npm scripts for better clarity: - Rename `type:test` to `type:doc:test` - Rename `type:doc` to `type:doc:build` - Update `type:check` to use `tsconfig.dev.json` Update references in CI workflow and publish_docs script to use the new script names.
1 parent a8ed0d8 commit b479dad

3 files changed

Lines changed: 6 additions & 6 deletions

File tree

.github/workflows/project.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -94,8 +94,8 @@ jobs:
9494
- uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
9595
- uses: ./.github/actions/node/latest
9696
- uses: ./.github/actions/install
97-
- run: npm run type:test
98-
- run: npm run type:doc
97+
- run: npm run type:doc:test
98+
- run: npm run type:doc:build
9999

100100
# TODO: Remove need for `npm show` before re-enabling to avoid rate limit errors.
101101
# verify-yaml:

package.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,9 +10,9 @@
1010
"bench": "node benchmark/index.js",
1111
"bench:e2e:test-optimization": "node benchmark/e2e-test-optimization/benchmark-run.js",
1212
"dependencies:dedupe": "yarn-deduplicate yarn.lock",
13-
"type:check": "tsc --noEmit -p tsconfig.json",
14-
"type:doc": "cd docs && yarn && yarn build",
15-
"type:test": "cd docs && yarn && yarn test",
13+
"type:check": "tsc --noEmit -p tsconfig.dev.json",
14+
"type:doc:build": "cd docs && yarn && yarn build",
15+
"type:doc:test": "cd docs && yarn && yarn test",
1616
"lint": "node scripts/check_licenses.js && eslint . --concurrency=auto --max-warnings 0",
1717
"lint:fix": "node scripts/check_licenses.js && eslint . --concurrency=auto --max-warnings 0 --fix",
1818
"lint:inspect": "npx @eslint/config-inspector@latest",

scripts/publish_docs.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ try {
1818
}
1919

2020
exec('rm -rf ./out', { cwd: './docs' })
21-
exec('yarn type:doc') // run first because typedoc requires an empty directory
21+
exec('yarn type:doc:build') // run first because typedoc requires an empty directory
2222
exec('git init', { cwd: './docs/out' }) // cloning would overwrite generated docs
2323
exec('git remote add origin git@github.com:DataDog/dd-trace-js.git', { cwd: './docs/out' })
2424
exec('git add -A', { cwd: './docs/out' })

0 commit comments

Comments
 (0)