-1

I'm developing react native app and during developement in some cases I have to remove node modules and then adding it again and after that I'm installing the pods also, But there are so many pod files which are here in my git folder and not ignoring as I already put a specific path in my .gitignore file. If anyone have idea about how to do that? I tried everything but it's not working somehow.

.gitingnore and git status

Tried with putting these paths

/ios/Pods/

/vendor/bundle/

Please let me know if there's any better solution than this.

  • 4
    did you well add the gitignore to the repo? And see if they are already managed? Also, please don't include code as text, but prefer copy/paste your gitignore file. – Elikill58 Jun 06 '23 at 09:07
  • 2
    If the files are already added to the repository `.gitignore` won't work – Konrad Jun 06 '23 at 09:16
  • 2
    +1 on the "paste text, not images" part: you can paste the output of `git status` and `cat .gitignore` (or the relevant parts) in your question, rather than a screen capture. – LeGEC Jun 06 '23 at 09:23

1 Answers1

-1

You need to follow these steps and update your gitignore file

1 - Remove your file or folder from git cached

git rm -r --cached myFolder
git rm -r myFolder // This deletes from filesystem

git rm file1.txt // This deletes from filesystem
git rm --cached file1.txt

2 - Delete local file or folder from your system
3 - Check git status and push that commit

Let me update your queries here, I will help you to sort out. Thanks

Bhavin Parghi
  • 132
  • 10