2

I am making a mini tweet and working with team members using RxSwift and MVVM. But when I try to open a new file, it doesn't open. Restarting the computer and restarting the app is the same. enter image description here

I'm working on the same branch as a team member, is that a problem? Why won't it open

NetworkingAPI and ViewModelType is new created file but The file color is weird

ga-yo
  • 123
  • 1
  • 2
  • 11
  • right click the file and then click "show in finder" and see if it's there. If it's in a repo just reclone the project and checkout the branch again. – Greg Price Aug 04 '20 at 03:10

2 Answers2

2

There are lots of reasons why that specific file went missing.

  1. You might've dragged that file from somewhere into your Xcode project and you thought that it was copied properly onto your project folder and deleted it from the original source folder.

  2. Merge issues.

  3. Similar to #2, another team member of your project pushed the file in a wrongful way.


There are of course also ways to recover it.

  1. Check your local machine.
  2. Ask for the most updated file from your teammate.
  3. Check your commits, and simply copy the whole source from there and fix it in your Xcode project by making a new file in your project folder.

I think the #3 should suffice.

Glenn Posadas
  • 12,555
  • 6
  • 54
  • 95
0

You have the reference in Xcode but the files are missing.

This happened when merging and you had .xcodeproj conflict then someone solved it in the wrong way. Check this as reference: https://stackoverflow.com/a/12907864/3933094

Canh Tran
  • 298
  • 1
  • 14
  • Together with team members, the master branch defines a basic pod install or folder structure. I know master branch is not good but this project is simple, so I choose this way. than What should I do then? – ga-yo Aug 04 '20 at 03:10
  • Maybe your team member didn't commit those files to the repo yet. Ask him to verify it again. – Canh Tran Aug 04 '20 at 03:14
  • oh okay I'll try – ga-yo Aug 04 '20 at 05:13