Untrack all files on git

In the move from C9 to hosting on my Macbook via SSH, I’ve had to re-download Kohana and change some other things just to get my site working; I don’t want those to be committed. Is there any way to untrack all tracked files so only future changes are committed? Or is there something else I should be doing?

I’m on a Macbook running Mountain Lion with Apache and PHP turned on.

  • git not receiving post commit results from svn server
  • Git strategy to keep on applying my changes to someone else's updeting branch
  • Bypassing gitolite restrictions for specific commits
  • Phabricator arc land won't work because that there are multiple revisions on feature branch
  • Ansible playbook using private git role dependency
  • How Can I Resolve:“can not open 'git-upload-pack' ” error in eclipse?
  • In what scenarios libgit2 is faster than git?
  • how do get a clone of a commit from history github
  • How do I download an ubuntu dsc file?
  • How do I change my default browser in git's BASH shell?
  • How to set up a repository using git-ftp?
  • vscode quick open “git checkout” shows no results
  • 3 Solutions collect form web for “Untrack all files on git”

    git rm --cached File

    Will delete the file in the index, so it will no longer be tracked, but won’t physically delete it. This will untrack the file only for current branch

    [OR]

    Use this git command. After you do this, git stops checking the file for possible modifications.

    git update-index --assume-unchanged  <filename>
    

    At any time, you can track again by setting --no-assume-unchaged flag

    git update-index --no-assume-unchanged  <filename>
    

    But these command do not affect the remote repository.

    Even simpler:

    cd /root/directory/of/your/local/repo
    git rm --cached -r .
    

    Even even simpler:

    git clone url/for/Kohana /different/local/path
    

    I’m not exactly sure what you mean by “untrack all tracked files so only future changes are committed”. As you need to track files so they can be committed.

    If all you just want to do is not track Kohana and the other downloads, then just remove them from your working directory using git rm --cached <file> or even better create a .gitignore file.

    There are many helpful posts on stackoverflow to assist you with creating a .gitignore file for your project. By using this, you can exclude an entire folder easily.

    For Mac, it would also be helpful if you could see hidden file as the . file is hidden. This page shows you how to see hidden files on Mountain Loin – http://www.mikesel.info/show-hidden-files-mac-os-x-10-7-lion/

    Git Baby is a git and github fan, let's start git clone.