Amending .gitignore, removing files from git while keeping them locally -


all of developers have files should have been in .gitignore start of project, not.

is there git command remove files git, while keeping them locally and keeping them locally on other developer machines, when git pull?

ideally should @ diff of .gitignore decide needs removed kept locally.

at moment, considering following manual procedure:

my machine:

  1. get full paths of files match new .gitignore, don't match old .gitignore
  2. add of files out-of-tree tar file
  3. git rm files
  4. commit , push origin master changes
  5. email tar file other developers

every other developer's machine:

  1. git pull update .gitignore , remove local copies of files should ignored.
  2. untar tar file on top of local repo reinstate removed files

this procedure has huge scope manual errors - there better way?

i've looked at:

remove file git without deleting them locally , remotely

removing file versioning keeping locally? ,

http://gitready.com/intermediate/2009/02/18/temporarily-ignoring-files.html

locally can by:

git rm --cached file_name

arlo carreon explains how multiple developers: http://www.arlocarreon.com/blog/git/untrack-files-in-git-repos-without-deleting-them/


Comments

Popular posts from this blog

javascript - Chart.js (Radar Chart) different scaleLineColor for each scaleLine -

apache - Error with PHP mail(): Multiple or malformed newlines found in additional_header -

java - Android – MapFragment overlay button shadow, just like MyLocation button -