提交 a81c311f 编写于 作者: J Junio C Hamano

git-reset: make it work from within a subdirectory.

If you typically sit in, say "src/", it's annoying to have to
change directory to do a reset.

This may need to be reworked when we add "git reset -- paths..."
to encapsulate the "ls-tree $tree | update-index --index-info"
pattern.
Signed-off-by: NJunio C Hamano <junkio@cox.net>
上级 4da90285
#!/bin/sh
USAGE='[--mixed | --soft | --hard] [<commit-ish>]'
SUBDIRECTORY_OK=Yes
. git-sh-setup
TOP=$(git-rev-parse --show-cdup)
if test ! -z "$TOP"
then
cd "$TOP"
fi
update=
reset_type=--mixed
case "$1" in
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册