Re: newbie - missing file from untracked list
From: Jiang Xin <hidden>
Date: 2016-06-15 22:51:37
于 11-7-19 上午9:49, govinda 写道:
[Govindas-iMac-2:SS_site_root] Govind% git add mainline_finishes.html [Govindas-iMac-2:SS_site_root] Govind% git status # On branch Gov_SS_2011-07-16 # Changes to be committed: # (use "git reset HEAD <file>..." to unstage) # # new file: VL_ShowMan.html # # Untracked files: # (use "git add <file>..." to include in what will be committed) # [snip] # Intranet_IE/CSI_Admin.html # Intranet_IE/DealerUpdate_Approve.html [snip] ^^^ *where* is 'mainline_finishes.html'?!
If the file 'mainline_finishes.html' is already in the repository,
add it again without any modifications, the file will not show in
git-status output.
You can see files aready in HEAD:
$ git ls-tree HEAD
or files in stage.
$ git ls-files -s
I would sort that untracked file listing for ease of reading.. but I do not know how (if it is even possible)... is there an option for 'git status -?' that causes the list to sort alphabetically? At the moment is seems to try to sort ..but breaks the lists into a couple/few separate clumps of otherwise alphabetized file names. (That makes no sense to me.)
$ git status -s | grep "^?" | sort -- Jiang Xin