hitch icon indicating copy to clipboard operation
hitch copied to clipboard

fish shell support

Open Globegitter opened this issue 9 years ago • 4 comments

It would be great to get https://github.com/fish-shell/fish-shell/ support. Currently getting these errors: screen shot 2015-03-18 at 00 22 02

Globegitter avatar Mar 18 '15 00:03 Globegitter

Hello @Globegitter. I'll install fish-shell and tinker with it.

therubymug avatar Mar 18 '15 14:03 therubymug

@therubymug https://github.com/therubymug/hitch/blob/master/lib/hitch/hitch.sh

This file is valid for ZSH or bash, but it isn't going to work with fish.

stephenprater avatar Mar 18 '15 15:03 stephenprater

@Globegitter: Do you mind trying this out and see if it helps? https://github.com/edc/bass

therubymug avatar Mar 20 '15 15:03 therubymug

Here's my working solution:

$ cat config/fish/functions/pair.fish                                                            
function pair --description "begin pairing"
hitch  $argv[1] $argv[2]
source ~/.hitch_export_authors
end

$ cat config/fish/functions/unpair.fish                                                                
function unpair --description "end pairing"
hitch -u
set -e GIT_AUTHOR_NAME
set -e GIT_AUTHOR_EMAIL
rm ~/.hitch_export_authors
end

and in config.fish:

if test -f ~/.hitch_export_authors; source ~/.hitch_export_authors; end

ezuk avatar Oct 14 '16 18:10 ezuk