Skip to content

Commit

Permalink
run fixup in prepare, not postprepare
Browse files Browse the repository at this point in the history
'npm publish' runs 'npm prepare', but does _not_ run postprepare,
leading to a 'works on my machine' problem.

Via: microsoft/TypeScript#54546 (comment)
  • Loading branch information
isaacs committed Jun 6, 2023
1 parent 676bbef commit 2271473
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,8 +31,7 @@
"postversion": "npm publish",
"prepublishOnly": "git push origin --follow-tags",
"preprepare": "rm -rf dist",
"prepare": "tsc -p tsconfig.json && tsc -p tsconfig-esm.json",
"postprepare": "bash fixup.sh",
"prepare": "tsc -p tsconfig.json && tsc -p tsconfig-esm.json && bash fixup.sh",
"pretest": "npm run prepare",
"presnap": "npm run prepare",
"test": "c8 tap",
Expand Down

0 comments on commit 2271473

Please sign in to comment.