Skip to content
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

Added precommit hook #67

Merged
merged 4 commits into from
Apr 25, 2021
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .husky/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
_
3 changes: 3 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,9 @@ $ npm install
# Copy .env.example to .env
$ It is recommended to install [MongoDB Compass](https://www.mongodb.com/try/download/compass) to visualize data in mongodb

# To test run pre commit hook
$ npm test

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

pre-commit hook should run automatically before committing the changes.

# Start application
$ npm run start:dev

Expand Down
122 changes: 122 additions & 0 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

82 changes: 42 additions & 40 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,41 +1,43 @@
{
"name": "opportunity-calendar-backend",
"version": "1.0.0",
"description": "Opportunity Calendar is the one-stop place to refer important opportunities available in tech-space like newly posted jobs, internships, hackathons, tech-conferences, scholarships etc.",
"main": "index.js",
"type": "module",
"scripts": {
"start": "node index.js",
"test": "mocha './tests/*/*'",
"start:dev": "nodemon –experimental-modules index.js"
},
"repository": {
"type": "git",
"url": "git+https://github.com/Manvityagi/Opportunity-Calendar-Backend.git"
},
"author": "ManviTyagi",
"license": "ISC",
"bugs": {
"url": "https://github.com/Manvityagi/Opportunity-Calendar-Backend/issues"
},
"homepage": "https://github.com/Manvityagi/Opportunity-Calendar-Backend#readme",
"dependencies": {
"body-parser": "^1.19.0",
"cluster": "^0.7.7",
"cors": "^2.8.5",
"dotenv": "^8.2.0",
"express": "^4.17.1",
"method-override": "^3.0.0",
"mongoose": "^5.12.1",
"mongoose-type-url": "^2.1.0",
"nodemon": "^2.0.7",
"swagger-jsdoc": "^6.0.0",
"swagger-ui-express": "^4.1.6"
},
"devDependencies": {
"chai": "^4.3.4",
"faker": "^5.5.2",
"sinon": "^10.0.0",
"mocha": "^8.3.2"
}
}
"name": "opportunity-calendar-backend",
"version": "1.0.0",
"description": "Opportunity Calendar is the one-stop place to refer important opportunities available in tech-space like newly posted jobs, internships, hackathons, tech-conferences, scholarships etc.",
"main": "index.js",
"type": "module",
"scripts": {
"prepare": "husky install",
"start": "node index.js",
"test": "mocha './tests/*/*'",
"start:dev": "nodemon –experimental-modules index.js"
},
"repository": {
"type": "git",
"url": "git+https://github.com/Manvityagi/Opportunity-Calendar-Backend.git"
},
"author": "ManviTyagi",
"license": "ISC",
"bugs": {
"url": "https://github.com/Manvityagi/Opportunity-Calendar-Backend/issues"
},
"homepage": "https://github.com/Manvityagi/Opportunity-Calendar-Backend#readme",
"dependencies": {
"body-parser": "^1.19.0",
"cluster": "^0.7.7",
"cors": "^2.8.5",
"dotenv": "^8.2.0",
"express": "^4.17.1",
"method-override": "^3.0.0",
"mongoose": "^5.12.1",
"mongoose-type-url": "^2.1.0",
"nodemon": "^2.0.7",
"swagger-jsdoc": "^6.0.0",
"swagger-ui-express": "^4.1.6"
},
"devDependencies": {
"chai": "^4.3.4",
"faker": "^5.5.2",
"husky": "^6.0.0",
"mocha": "^8.3.2",
"sinon": "^10.0.0"
}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

you need to install prettier and pretty-quick as well.

}