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

git reset

From
EGEfim Goncharuk <efimster@gmail.com>
Date
Aug 16, 2017, 12:21 UTC
Message-ID
<34910856-7DE9-41A0-A7A6-B572B1C88C1F@gmail.com>
Hello,
Starting from git v.2.13.0 onwards (v 2.12.2 works fine)
git reset --hard with --work-tree and --git-dir options does not move HEAD to hash/tag specified. HEAD remains on same position.
Example:
> git --work-tree=lib/core --git-dir=lib/core/.git/ reset --hard 0.1.0

Note: on another hand

> git -C lib/core reset --hard 0.1.0

Regards, Efim Goncharuk

Next: Junio C Hamano
Message 1 of 2 in “git reset”
  1. Efim GoncharukAug 16, 2017
  2. Junio C HamanoAug 16, 2017

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.