mirror of
https://github.com/fish-shell/fish-shell.git
synced 2026-06-01 21:21:15 -03:00
Make literal "{}" expand to itself
This caused major annoyances with e.g. `find -exec`, and it's utterly
useless - "{}" expands to nothing, so why have it at all?
Fixes #1109.
This commit is contained in:
@@ -24,7 +24,6 @@
|
||||
- <a href='#faq-titlebar'>I'm seeing weird output before each prompt when using screen. What's wrong?</a>
|
||||
- <a href='#faq-greeting'>How do I change the greeting message?</a>
|
||||
- <a href='#faq-history'>Why doesn't history substitution ("!$" etc.) work?</a>
|
||||
- <a href='#faq-find-braces'>Why do I get a missing argument error with `find ... {}`?</a>
|
||||
- <a href='#faq-cd-minus'>How can I use `-` as a shortcut for `cd -`?</a>
|
||||
- <a href='#faq-uninstalling'>How do I uninstall fish?</a>
|
||||
- <a href='#faq-third-party'>Where can I find extra tools for fish?</a>
|
||||
@@ -244,21 +243,6 @@ Fish history recall is very simple yet effective:
|
||||
|
||||
See <a href='index.html#editor'>documentation</a> for more details about line editing in fish.
|
||||
|
||||
<hr>
|
||||
\section faq-find-braces Why do I get a missing argument error with `find ... {}`?
|
||||
|
||||
Running `find ... -exec ... {}` produces an error:
|
||||
|
||||
find: missing argument to '-exec'
|
||||
|
||||
The problem is caused by the empty braces, which are subject to <a href="index.html#expand-brace">brace expansion</a>.
|
||||
|
||||
Quote the empty braces to achieve the desired effect:
|
||||
|
||||
\fish{cli-dark}
|
||||
find ... -exec ... '{{}}'
|
||||
\endfish
|
||||
|
||||
<hr>
|
||||
\section faq-cd-minus How can I use `-` as a shortcut for `cd -`?
|
||||
|
||||
|
||||
Reference in New Issue
Block a user