composer php - Recover files deleted with git rm --cached -


i trying ignore changes on composer.phar , composer.phar files staging area (local host). followed this post answer , did:

git rm --cached composer.lock  git rm --cached composer.phar 

and added:

/composer.lock  /composer.phar 

to .gitignore file. , seemed go expected, files still there, weren't followed.

but now, when try pull changes server, these files removed. don't remove files, don't follow them. how come or resolve issue?

well yes, deleted file index. first need back. can either revert commit did

git revert sha_key_of_commit_that_deleted_it

or if ok changing history reset branch point before change

git reset sha_key_of_the_commit_where_sky_was_blue

then, want stop file receiving further changes keeping way is:

git update-index --assume-unchanged /composer.lock


Comments

Popular posts from this blog

android - Get AccessToken using signpost OAuth without opening a browser (Two legged Oauth) -

org.mockito.exceptions.misusing.InvalidUseOfMatchersException: mockito -

google shop client API returns 400 bad request error while adding an item -