How to specify which files to ignore when switching between branches and pushing in GIT

Answered

This has been a nightmare trying to work with GIT. For my class in college we have to use GIT as a VCS and honestly its been the worst. I have spent more time trying to get this to work then actually working on my project... All I want to do is be able to switch between branches and not have to re-add my libraries or reconfigure the project every single frickin time or have to commit a file that should've been ignored but is obviously not. Here is a couple of screenshots of what I have done so far. I'm pretty sure it is the .gitignore file that is messed up or something has been added to git that should not have and so wants me to add it anyways. Honestly about to give up and move to something more friendly like floobits which is alot easier in my opinion and deal with this towards the end of the semester. 

 

Sorry for all the pictures but this is not even half the issues i've had with this. Its a joke.

 

 

 

0
3 comments

See https://intellij-support.jetbrains.com/hc/articles/206544839 .

Here is the sample .gitignore file: https://github.com/github/gitignore/blob/master/Global/JetBrains.gitignore .

Your file has invalid syntax, the entries normally do not start with the forward slash.

0
Avatar
Permanently deleted user

Okay thanks for pointing that out, ill take a look at that.

0
Avatar
Permanently deleted user

It worked!! Here is what I did and so far nothing seems to happen when I run the program and then switch from my branch "steve2" to "develop" branch.

 

0

Please sign in to leave a comment.