Skip to content

Commit

Permalink
plugins/textmate: use _command_exists
Browse files Browse the repository at this point in the history
Addresses Bash-it#1632

# Conflicts:
#	plugins/available/textmate.plugin.bash
  • Loading branch information
gaelicWizard committed Sep 10, 2021
1 parent a31f3fc commit 9ba5a4a
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions plugins/available/textmate.plugin.bash
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
# shellcheck shell=bash
cite about-plugin
about-plugin 'set textmate as a default editor'

if type -t mate >/dev/null
if _command_exists mate
then
export EDITOR="$(which mate) -w"
export GIT_EDITOR=$EDITOR
export EDITOR="$(type -p mate) -w"
export GIT_EDITOR="$EDITOR"
fi

0 comments on commit 9ba5a4a

Please sign in to comment.