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

Re: change symlink

From
Andreas Schwab <schwab@linux-m68k.org>
Date
Oct 30, 2012, 21:19 UTC
Message-ID
<m2mwz3odys.fsf@igel.home>
In-Reply-To
<CAH_OBie-irmpBrJG6KB3W8bgYjQdyVYiUR-SvJPnx1FXUya0uA@mail.gmail.com>
shawn wilson <ag4ve.us@gmail.com> writes:
Show 17 quoted lines
> i'm curious why this is being reported as deleted in status and diff
> and not modified? this was tested on a build of the master branch of
> the current git repo (1.8.0).
>
> mkdir t cd t; git --init
>
> touch test
> git add test
> git commit test -m "test"
>
> ln -s test t2
> git add t2
> git commit t2 -m "symlink"
>
> rm t2
> mkdir -p t2/one
> ln -s test t2/one/test
  git add t2/one/test
Show 11 quoted lines
> this then shows up as:
>
>  % git status
> # On branch master
> # Changes not staged for commit:
> #   (use "git add/rm <file>..." to update what will be committed)
> #   (use "git checkout -- <file>..." to discard changes in working directory)
> #
> #       deleted:    t2
> #
> no changes added to commit (use "git add" and/or "git commit -a")
I'd expected t2/one/test be reported as untracked.
Andreas.
-- 
Andreas Schwab, schwab@linux-m68k.org
GPG Key fingerprint = 58CA 54C7 6D53 942B 1756  01D3 44D5 214B 8276 4ED5
"And now for something completely different."
Previous: shawn wilsonNext: shawn wilson
Message 2 of 12 in “change symlink”
  1. shawn wilsonOct 30, 2012
  2. Andreas SchwabOct 30, 2012
  3. shawn wilsonOct 30, 2012
  4. Andreas SchwabOct 30, 2012
  5. shawn wilsonOct 30, 2012
  6. Andreas SchwabOct 30, 2012
  7. shawn wilsonOct 30, 2012
  8. Andreas SchwabOct 30, 2012
  9. shawn wilsonOct 30, 2012
  10. Jeff KingOct 31, 2012
  11. Jeff KingOct 31, 2012
  12. Jeff KingOct 31, 2012

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.