Tree @master (Download .tar.gz)
- .github
- AnyEvent-I3
- contrib
- debian
- docs
- etc
- i3-config-wizard
- i3-dump-log
- i3-input
- i3-msg
- i3-nagbar
- i3bar
- include
- libi3
- man
- meson
- parser-specs
- release-notes
- share
- src
- testcases
- travis
- .clang-format
- .dockerignore
- .editorconfig
- .gitignore
- DEPENDS
- generate-command-parser.pl
- i3-dmenu-desktop
- i3-migrate-config-to-v4
- i3-save-tree
- i3-sensible-editor
- i3-sensible-pager
- i3-sensible-terminal
- I3_VERSION
- LICENSE
- logo.svg
- meson.build
- meson_options.txt
- PACKAGE-MAINTAINER
- pseudo-doc.doxygen
- README.md
- RELEASE-NOTES-4.21.1
- release.sh
i3-sensible-editor @master — raw · history · blame
#!/bin/sh
#
# This code is released in public domain by Han Boetes <[email protected]>
#
# This script tries to exec an editor by trying some known editors if $EDITOR is
# not set.
#
# Distributions/packagers can enhance this script with a distribution-specific
# mechanism to find the preferred editor
# Hopefully one of these is installed (no flamewars about preference please!):
for editor in "$VISUAL" "$EDITOR" nano nvim vim vi emacs pico qe mg jed gedit mcedit gvim; do
if command -v "$editor" > /dev/null 2>&1; then
exec "$editor" "$@"
fi
done
|