Commit 4b55b5e0 authored by Andrew Mayorov's avatar Andrew Mayorov

Add some more fish goodies

parent b719ff84
# Change the terminal title automatically based on current process / working-directory
function fish_title
set -l command (echo $_)
if test $command = "fish"
# we are sitting at the fish prompt
echo (prompt_pwd)
else
# we are busy running some non-fish command, so use the command name
echo $command
end
end
function recap_command_output
set -l cmd $argv
set -l prompt (printf '%s $ ' (prompt_pwd))
set -l output
eval $cmd | read -z output
printf "%s%s\n%s" "$prompt" "$cmd" "$output" | xsel -ib
echo -ne "$output"
end
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment