Skip to content

Commit

Permalink
fix(ama-sdk/create): fix doc:generate command (#1299)
Browse files Browse the repository at this point in the history
## Proposed change

Fix doc:generate command in project generated by ama-sdk/create.
  • Loading branch information
kpanot authored Feb 1, 2024
2 parents 1710ffd + 6676355 commit d4b36d0
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 4 deletions.
1 change: 1 addition & 0 deletions packages/@ama-sdk/create/src/index.it.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -64,5 +64,6 @@ describe('Create new sdk command', () => {
{ ...execAppOptions, cwd: sdkPackagePath }
)).not.toThrow();
expect(() => packageManagerRun('build', { ...execAppOptions, cwd: sdkPackagePath })).not.toThrow();
expect(() => packageManagerRun('doc:generate', { ...execAppOptions, cwd: sdkPackagePath })).not.toThrow();
});
});
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ export const updateScriptPackageJson = (): Rule => (tree, context) => {

const pck = tree.readJson('/package.json') as PackageJson;
if (pck.scripts?.['doc:generate'] === 'node scripts/override-readme.js && typedoc && node scripts/restore-readme.js') {
pck.scripts['doc:generate'] = 'cpx ./readme.md ./.readme-backup && typedoc && cpx ./.readme-backup ./readme.md && rimraf ./.readme-backup';
pck.scripts['doc:generate'] = 'typedoc';
}
if (pck.scripts?.['files:pack'] === 'node scripts/files-pack.js') {
pck.scripts['files:pack'] = 'amasdk-files-pack';
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@
"publish:package": "npm publish ./dist",
"postinstall": "husky install",
"generate:mock": "schematics @ama-sdk/schematics:mock",
"doc:generate": "cpx ./readme.md ./.readme-backup && typedoc && cpx ./.readme-backup ./readme.md && rimraf ./.readme-backup",
"doc:generate": "typedoc",
"tools:changelog": "standard-version"
},
"lint-staged": {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,7 @@
"**/fixtures*.ts",
"**/*.mock*.ts",
"**/*.spec.ts",
"**/*.perf.ts",
"**/*.reviver.ts"
"**/*.perf.ts"
],
"include": [
"./src/models/**/*.ts",
Expand Down

0 comments on commit d4b36d0

Please sign in to comment.