Logo
Explore Help
Sign In
h/fish-shell
1
Fork 0
You've already forked fish-shell
mirror of https://github.com/fish-shell/fish-shell.git synced 2026-05-20 02:11:16 -03:00
Code Issues Packages Projects Releases Wiki Activity
Files
61d506afd08ee4e30d520304ca4d85d508e66b2f
fish-shell/share/functions/__fish_append.fish

6 lines
283 B
Fish
Raw Normal View History

Don't use abbreviated long options "function --argument" is not a thing, it's "--argument-names". This only accidentally works because our getopt is awful and allows abbreviated long options. Similarly, one argparse test used "--d" instead of "-d" or "--def".
2020-09-19 11:39:51 +02:00
function __fish_append -d "Internal completion function for appending string to the commandline" --argument-names sep
reformat all fish scripts I hate doing this but I am tired of touching a fish script as part of some change and having `make style` radically change it. Which makes editing fish scripts more painful than it needs to be. It is time to do a wholesale reformatting of these scripts to conform to the documented style as implemented by the `fish_indent` program.
2016-11-27 21:27:22 -08:00
set -e argv[1]
Some more precautionary uses of set --local
2020-05-15 21:34:48 +02:00
set -l str (commandline -tc | string replace -rf "(.*$sep)[^$sep]*" '$1' | string replace -r -- '--.*=' '')
functions/__fish_append: Stringify This called `sed`, twice.
2019-03-14 13:16:01 +01:00
printf "%s\n" "$str"$argv
Move a few shellscript bits around darcs-hash:20060218024145-ac50b-207ca782808ea8968cb38253c7bc2563350f38b2.gz
2006-02-18 12:41:45 +10:00
end
Reference in New Issue Copy Permalink
Powered by Gitea Version: 1.25.3 Page: 280ms Template: 8ms
English
Bahasa Indonesia Deutsch English Español Français Gaeilge Italiano Latviešu Magyar nyelv Nederlands Polski Português de Portugal Português do Brasil Suomi Svenska Türkçe Čeština Ελληνικά Български Русский Українська فارسی മലയാളം 日本語 简体中文 繁體中文(台灣) 繁體中文(香港) 한국어
Licenses API