-
Notifications
You must be signed in to change notification settings - Fork 9
Add pre-commit hook #4 #8
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Add pre-commit hook #4 #8
Conversation
@@ -21,7 +21,9 @@ | |||
"develop": "gatsby develop", | |||
"format": "prettier --write 'src/**/*.js'", | |||
"eslint": "node_modules/eslint-watch/bin/esw -w --fix", | |||
"test": "echo \"Error: no test specified\" && exit 1" | |||
"lint": "node_modules/.bin/eslint .", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why you have added it again.
eslint is already there right?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
the earlier eslint command runs in watch mode, can I change it to the new command?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do you know what pre-hook commit do ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The first character of the word in commit should be capital
Is it done?
@rahulrana95 should all the words in the commit message be capitalized (Add Precommit Hook) or only the first word of the message(Add precommit hook) ? |
@adarshlilha Make first character of all letters capital |
@adarshlilha Any update on this PR |
sorry for the delay. I tried using husky to run a custom script to verify all words start with a capital letter but couldn't get this working. Will need help from someone to look into this. |
Google about pre-hook and how it works. |
@adarshlilha Are you planning to work on this issue? @rahulrana95 Please Provide complete comment with what needs to updated in the PR to merge. Need to close this soon. |
Added husky and modified package.json scripts to run linter before git commit