Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Accidental function definition - bug or feature?
- X-seq: zsh-users 20805
- From: Holger Hoffstätte <holger.hoffstaette@xxxxxxxxxxxxxx>
- To: zsh-users@xxxxxxx
- Subject: Accidental function definition - bug or feature?
- Date: Thu, 22 Oct 2015 12:30:22 +0000 (UTC)
- List-help: <mailto:zsh-users-help@zsh.org>
- List-id: Zsh Users List <zsh-users.zsh.org>
- List-post: <mailto:zsh-users@zsh.org>
- Mailing-list: contact zsh-users-help@xxxxxxx; run by ezmlm
Hi,
today I accidentally b0rked my shell with git and an unquoted filename via
copypasta. To reproduce:
$git add foo().bar
$git --version
git:7: command not found: .bar
Turns out this unhelpfully defined a local function, which now shadows
the command:
$functions git
git () {
.bar
}
Obviously everything works correctly with quoted filenames.
Also bash complains as I would have expected:
bash$ git add foo().bar
bash: syntax error near unexpected token `('
So..bug or feature?
thanks,
Holger
Messages sorted by:
Reverse Date,
Date,
Thread,
Author