Skip to content

Fish shell support #162

@andrewfung729

Description

@andrewfung729

Is your feature request related to a problem? Please describe.
Thanks for the great tools. Unfortunately, Fish Shell is not supported.

Describe the solution you'd like
I wrote a bash shell for setting up my fish shell

cat >${HOME}/.g/env.fish <<-'EOF_ENV_FISH'
# g shell setup for fish

set -gx GOROOT "$HOME/.g/go"
set -gx G_MIRROR "https://golang.google.cn/dl/"

# Add g, GOROOT/bin, and GOPATH/bin (if set) to PATH using fish_add_path
fish_add_path "$HOME/.g/bin"
fish_add_path "$GOROOT/bin"

set -gx GOPATH "$HOME/go"

if set -q GOPATH;
    fish_add_path "$GOPATH/bin"
end
EOF_ENV_FISH

fish_conf_d_dir="${HOME}/.config/fish/conf.d"
mkdir -p "${fish_conf_d_dir}"
cat >"${fish_conf_d_dir}/g.fish" <<-'EOF_G_FISH_CONF'
# g shell setup
if test -s "$HOME/.g/env.fish"; and source "$HOME/.g/env.fish"; end
EOF_G_FISH_CONF

Metadata

Metadata

Assignees

Labels

enhancementNew feature or request

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions