Skip to content

Commit

Permalink
Update fish files to return instead of exit for consistency
Browse files Browse the repository at this point in the history
  • Loading branch information
JamyGolden committed Dec 17, 2023
1 parent 444b2d6 commit fa32028
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion hooks/base16-fzf.fish
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ end

# If BASE16_FZF_PATH doesn't exist, stop hook
if not test -d "$BASE16_FZF_PATH"
exit 2
return 2
end

# ----------------------------------------------------------------------
Expand Down
8 changes: 4 additions & 4 deletions hooks/base16-hexchat.fish
Original file line number Diff line number Diff line change
Expand Up @@ -18,20 +18,20 @@ end

# If BASE16_HEXCHAT_PATH doesn't exist, stop hook
if not test -d "$BASE16_HEXCHAT_PATH"
exit 2
return 2
end

# If HEXCHAT_COLORS_CONF_PATH hasn't been configured, stop hook
if test -z "$HEXCHAT_COLORS_CONF_PATH"
exit 1
return 1
end

# If HEXCHAT_COLORS_CONF_PATH has been configured, but the file doesn't
# exist
if test -n "$HEXCHAT_COLORS_CONF_PATH"; \
and not test -f "$HEXCHAT_COLORS_CONF_PATH"
echo "\$HEXCHAT_COLORS_CONF_PATH is not a file."
exit 2
return 2
end

# Set current theme name
Expand All @@ -47,7 +47,7 @@ if not test -f "$hexchat_theme_path"

echo $output

exit 2
return 2
end

# ----------------------------------------------------------------------
Expand Down
2 changes: 1 addition & 1 deletion hooks/base16-tmux.fish
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ end

# If base16-tmux path directory doesn't exist, stop hook
if not test -d $BASE16_TMUX_PLUGIN_PATH
exit 2
return 2
end

# ----------------------------------------------------------------------
Expand Down

0 comments on commit fa32028

Please sign in to comment.