Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Git ignore for Ionic project

I'm somewhat new applications with Ionic and very new to the subject of Git repositories. When I commit, endless files are uploaded - I find it very difficult to identify what changes are in the project.

So I wanted to ask for help here, is there a guide to ignore files if a file exists by default, and where, since most of the work is done in the www folder.

Sorry if the question is very basic, but I need help to solve this problem.

like image 769
NHTorres Avatar asked May 19 '15 15:05

NHTorres


1 Answers

The problem here is that if you already add all those files, once you put the .gitignore it will not work as you want. You need to put the .gitignore at the very beginning of your project.

So, my advise: make another project in Git, just upload your project again and create the .gitignore file. I am telling you this based on my own experience.

The basics of what you should put in that .gitignore

node_modules .tmp .sass-cache **/bower_components or sometimes it is lib/** platforms plugins *.swp *.swo *.log *.DS_Store 

in order to create this file, you can do it from Git, or from your terminal:

  1. In Terminal, navigate to the location of your Git repository.
  2. Enter $ touch .gitignore to create a .gitignore file.
like image 77
Non Avatar answered Sep 28 '22 20:09

Non