This repository was archived by the owner on Jan 5, 2024. It is now read-only.

Description
I noticed that if I create or amend a commit while I also have unstaged changes, these will end up against intention in the auto-generated dist/
and lib/
parts of the commit.
|
module.exports = { |
|
"**/!(*test).{ts,json}": [ |
|
"eslint --cache --fix", |
|
() => "npm run bundle", |
|
() => "git add setup/dist/ setup/lib/", |
|
], |
|
"**/*.ts": () => "tsc -p tsconfig.json", |
|
"**/*.{js,ts,json,md}": "prettier --write", |
|
}; |
Maybe a fix would be to auto-stash in the commit hook, so that the unstaged changes would not be considered when compiling the typescript. Presumably git stash --keep-index
can do this (?): https://stackoverflow.com/questions/20028507/git-stash-uncached-how-to-put-away-all-unstaged-changes