Open tadast opened 4 years ago
Interesting! Have not come across that change code before. Could you please provide me a step of steps to take in a naked git repository to reproduce the status?
I see from checking the documentation for git status
compared to when this was written there are some new codes documented that might need to be accommodated for now, including the " A"
status in this issue, but also potentially " R"
"DR"
" C"
and "DC"
statuses. (And based on the updated chart, "DM"
may no longer be possible?)
diff --git a/commands/status/process.go b/commands/status/process.go
index cb4163b..1cc0ce3 100644
--- a/commands/status/process.go
+++ b/commands/status/process.go
@@ -280,15 +280,17 @@ Below documentation from git status:
X Y Meaning
-------------------------------------------------
- [MD] not updated
+ [AMD] not updated
M [ MD] updated in index
A [ MD] added to index
- D [ M] deleted from index
+ D deleted from index
R [ MD] renamed in index
C [ MD] copied in index
[MARC] index and work tree matches
[ MARC] M work tree changed since index
[ MARC] D deleted in work tree
+ [ D] R renamed in work tree
+ [ D] C copied in work tree
-------------------------------------------------
D D unmerged, both deleted
A U unmerged, added by us
Hey, yeah not many people now about -N
, but it's very useful for the workflows like the one I've shared above.
Here's the minimal number of steps to reproduce the issue:
mkdir test
cd test
git init .
touch file_to_be_added.txt
git add . -N
I'm not sure how to get the other statuses unfortunately
From
man git-add
I'm using this flow when I want to add new files using
-p
. Without intent-to-addgit add -p
won't pick up the new files.