Rhs
Rhs

Reputation: 3318

Git Pull Synchronization

On my git, I have a file called b.txt

On my local machine, I do not have this file.

I tried "git pull" to retrieve the file from git and place it into the directory of my local machine, but it says: Already up-to-date.

How do I retrieve the file without physically downloading it and placing it into my folder?

Thanks.

Upvotes: 1

Views: 100

Answers (1)

VonC
VonC

Reputation: 1329082

Check if you are in a detached head mode: see "Why did git detach my head?"

That would:

  • make any git pull null ("already up-to-date")
  • not restore your file if you had deleted locally

Note that you can search for the branches containing that file ("How can I search Git branches for a file or directory?"), and look for a deleted file ("Git: How to search for a deleted file on the project history?")

Upvotes: 2

Related Questions