How to ignore persistence.xml in gitignore?

Asked

Viewed 156 times

0

I have a persistence file called persistence.xml in the paths:

/git/meuRepositorio/Meuprojeto/src/main/Resources/META-INF/persistence.xml

And I’d like to include you in .gitignore, I put that path in the .gitignore, I commit and push, but persistence is still seen by git, which way should I do it, so it’s ignored in GIT? Just remembering that I’m using the GitHub.

1 answer

1


You need to re-load your . gitgnore from Github:

First make any changes to your code, then execute the following commands:

git rm -r --cached .

This removes the changed files from the index (staging area), then just run:

git add .

Then commit:

git commit -m ".gitignore esta atualizado agora"

Browser other questions tagged

You are not signed in. Login or sign up in order to post.