2016-01-01 21:12:40 +00:00
. \" generated with Ronn/v0.7.3
. \" http://github.com/rtomayko/ronn/tree/0.7.3
.
.TH "FISHER\-COMMANDS" "7" "January 2016" "" "fisherman"
.
.SH "NAME"
\fB fisher\- commands\fR \- Creating Fisherman Commands
.
.SH "SYNOPSIS"
This document describes how to add new commands to Fisherman\. A Fisherman command is a function that you can invoke like \fB fisher command\fR [\fI options\fR ]\.
.
.SH "DESCRIPTION"
To add a command, create a function \fB fisher_<my_command>\fR :
.
.IP "" 4
.
.nf
function fisher_hello \- d "Friendly command"
echo hello
end
.
.fi
.
.IP "" 0
.
.P
Make sure it works: \fB fisher hello\fR \.
.
.P
2016-01-10 07:01:07 +00:00
To make this function available to the current and future fish sessions, add it to \fB $XDG_CONFIG_HOME/fish/functions\fR :
2016-01-01 21:12:40 +00:00
.
.IP "" 4
.
.nf
funcsave fisher_hello
.
.fi
.
.IP "" 0
.
.P
2016-01-10 07:01:07 +00:00
You may also choose to save this function to \fB $fisher_config/functions\fR \.
2016-01-01 21:12:40 +00:00
.
.SH "EXAMPLES"
The following example implements a command to retrieve plugin information and format the output into columns\.
.
.IP "" 4
.
.nf
function fisher_info \- d "Display information about plugins"
switch "$argv"
case \- h \- \- help
2016-01-10 07:01:07 +00:00
printf "usage: fisher info name | URL [\. \. \. ]\e n\e n"
printf " \- h \- \- help Show usage help\e n"
2016-01-01 21:12:40 +00:00
return
end
for item in $argv
fisher search $item \- \- name \- \- info
end | sed \- E \' s/;/: /\' | column
end
.
.fi
.
.IP "" 0
.
.SH "SEE ALSO"
2016-01-10 07:01:07 +00:00
fisher(1)
2016-01-01 21:12:40 +00:00
.
.br
2016-01-10 19:55:59 +00:00
fisher help tour
2016-01-01 21:12:40 +00:00
.
.br
2016-01-10 07:01:07 +00:00
funcsave(1)
2016-01-01 21:12:40 +00:00
.
.br
2016-01-10 07:01:07 +00:00
fisher help plugins
2016-01-01 21:12:40 +00:00
.
.br