Skip to content
This repository has been archived by the owner on Jan 5, 2024. It is now read-only.

Dev: unstaged changes end up in commit in dist/ and lib/ #250

Open
andreasabel opened this issue May 6, 2023 · 0 comments
Open

Dev: unstaged changes end up in commit in dist/ and lib/ #250

andreasabel opened this issue May 6, 2023 · 0 comments
Labels
re: dev Concerning developer experience

Comments

@andreasabel
Copy link
Member

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

@andreasabel andreasabel added the re: dev Concerning developer experience label May 6, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
re: dev Concerning developer experience
Projects
None yet
Development

No branches or pull requests

1 participant