Home > OS >  What is "Pod/***.a Pod/**.dia" file?
What is "Pod/***.a Pod/**.dia" file?

Time:01-04

I am using the Cocoapod , RxCocoa , RxSwift and Git.

When I run the "git status", some warning will show:

(use "git restore ..." to discard changes in working directory)
modified: Pods/RxCocoa.d
modified: Pods/RxRelay.d
modified: Pods/RxSwift.d

I remember "Pod/*.a Pod/.dia" show too.

How to prevent this in the future?
Must I add something into the .gitignore file??

===================== Edit again:

I viewed the .gitignore a few minutes ago.

My project doesn't ignore the Pods. My project ignore the files in this way:


# Xcode
*.build
*.dia
*.tlog
*.o
*.d


In my opinion, I need't ignore the ".d" ".a" ".dia" files which are in the file "Pods/", need I?

CodePudding user response:

You could ignore Pods altogether:

echo Pods/>.gitignore
git rm --cached -R Pods/

But ignoring Pods has its Pros and Cons, so make sure this would work with your development workflow.


If your .gitignore already had *.d for instance, you can make sure that rule applies with:

git rm --cached -R Pods/*.d

(same for *.a, and so on)

  •  Tags:  
  • Related