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

Re: [PATCH] Add new git-rm command with documentation

From
Shawn Pearce <spearce@spearce.org>
Date
Feb 21, 2006, 22:32 UTC
Message-ID
<20060221223254.GB20744@spearce.org>
In-Reply-To
<43FB9455.6010402@people.pl>

Krzysiek Pawlik <krzysiek.pawlik@people.pl> wrote: [...]

Show 23 quoted lines
> +while : ; do
> +  case "$1" in
> +    -n)
> +	show_only=true
> +	;;
> +    -v)
> +	verbose=--verbose
> +	;;
> +    -f)
> +	remove_files=true
> +	;;
> +    --)
> +	break
> +	;;
> +    -*)
> +	usage
> +	;;
> +    *)
> +	break
> +	;;
> +  esac
> +  shift
> +done
[...]

You are leaving -- in $@ for processing later, which means we'll try to delete the file '--'. :-)

I think a shift before the break in the -- case would fix this.
-- 
Shawn.
Previous: Krzysiek PawlikNext: Krzysiek Pawlik
Message 5 of 15 in “Add new git-rm command with documentation”
  1. Add new git-rm command with documentationCarl Worth, Feb 21, 2006
  2. Krzysiek PawlikFeb 21, 2006
  3. Shawn PearceFeb 21, 2006
  4. Krzysiek PawlikFeb 21, 2006
  5. Shawn PearceFeb 21, 2006
  6. Krzysiek PawlikFeb 21, 2006
  7. Carl WorthFeb 21, 2006
  8. Carl WorthFeb 21, 2006
  9. Junio C HamanoFeb 22, 2006
  10. git-rm: Fix to properly handle files with spaces, tabs, newlines, etc.Carl Worth, Feb 23, 2006
  11. Carl WorthFeb 23, 2006
  12. Junio C HamanoFeb 23, 2006
  13. Alex RiesenFeb 24, 2006
  14. Junio C HamanoFeb 25, 2006
  15. Johannes SchindelinFeb 21, 2006

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.