What should I put in a meteor .gitignore file ?
Here is the solution is,
The directory excluded from version control is .meteor/local. Meteor automatically creates the right .meteor and .meteor/.gitignore, though — you shouldn’t need to do anything.
Here is an Example code:
# Meteor files to ignore now handled by .ignore file within .Meteor folder automatically # settings file to ignore to protect API keys settings.json # MUP / MUPX file to ignore to protect server passwords and sensitive info. mup.json # npm package files to ignore node?modules/ npm-debug.log # Webstorm IDE files to ignore .idea/* # Typing type definition files to ignore. Webstorm uses type definitions for autocomplete even without typescript typings/*
To use this way
- You might want to put any configuration settings files in there if you are pushing to a public repos.
- I store any security sensitive data configuration settings like encryption keys and various passwords for services like smtp, twitter, facebook and others in a config.js and then put that in .gitignore or in the info/exclude file. Stuff I don’t want in a public repo.
Here is the code:
MeteorJS ### # default meteor build and local packages .meteor/local# meteor settings file settings.json # meteor build output files *.tar.gz # general swp files from vim *.swp # End of https://www.gitignore.io/api/meteorjs
Try this method
- Gitignore is used to ignore all the unnecessary burden over the git server and your fetching all the time.
- So the best possible stuff to put inside the gitignore is packagable entity. Now, this includes the meteor downloadable packages, so, you should just add “.meteor/local” inside gitignore.
- When you add it to gitignore configuration, it reduces the size of project to n times smaller as it would be with the packages.
- If you cut-paste the entire project now to different location or fetch the repository without .meteor/local folder and start the project using meteor command, the meteor first downloads the required packages and then starts the server.
Here is an Simple code:
node_modules/ .meteor/local/* .idea/ npm-debug.log packages/*/.npm/