git/list[1] front-page[2] threads[3] people[4] search[5] about
 

git bug

From
JTJustin Tang <jutang@ixl.com>
Date
Feb 8, 2024, 19:32 UTC
Message-ID
<CAO18WYyQas36PNz20+pRt0usGqZwrhVYDbQfPZnHEVD8esfoyQ@mail.gmail.com>
Thank you for filling out a Git bug report!
Please answer the following questions to help us understand your issue.
What did you do before the bug happened? (Steps to reproduce your issue)
add a new file to the git directory, untracked. with some path path/to/file
I wanted to use git diff on untracked files, so I added the file as an
empty file to git, with:
git add --intent-to-add path/to/file
Then I wanted to stash my changes, with:
git stash save
What did you expect to happen? (Expected behavior)
My changes to be stashed.
What happened instead? (Actual behavior)
I can't stash my changes, git stash save or git stash save --include-untracked.
I was getting this error:

error: Entry 'path/to/file' not uptodate. Cannot merge. Cannot save the current worktree state

What's different between what you expected and what actually happened?
umm
Anything else you want to add:
Anything else you want to add:
I 'fixed' this by removing the empty file with git rm -r --cached path/to/file
Please review the rest of the bug report below.
You can delete any lines you don't wish to share.
[System Info]
git version:
git version 2.38.4
cpu: x86_64
no commit associated with this build
sizeof-long: 8
sizeof-size_t: 8
shell-path: /bin/sh

uname: Linux 3.10.0-1127.13.1.el7.x86_64 #1 SMP Tue Jun 23 15:46:38 UTC 2020 x86_64

compiler info: gnuc: 10.2
libc info: glibc: 2.17
$SHELL (typically, interactive shell): /bin/bash
[Enabled Hooks]
commit-msg
post-commit
post-rewrite
pre-commit
pre-push
prepare-commit-msg
Message 1 of 1 in “git bug”
  1. Justin TangFeb 8, 2024

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.