2019-08-29 10:03:32 +10:00
|
|
|
command -v vim &>/dev/null && editor="$(which vim)"
|
|
|
|
command -v nvim &>/dev/null && editor="$(which nvim)"
|
2011-10-24 11:03:37 +11:00
|
|
|
|
2019-08-29 10:04:05 +10:00
|
|
|
if command -v ag &>/dev/null; then
|
|
|
|
# Ignore anything in .gitignore but still list other hidden files (e.g. .env)
|
|
|
|
export FZF_DEFAULT_COMMAND="ag -l --hidden --ignore .git/"
|
|
|
|
fi
|
|
|
|
|
2019-08-29 10:02:43 +10:00
|
|
|
# Many editor integrations (linters, language server, etc) mess up Phoenix auto
|
|
|
|
# reloading by compiling changed files themselves (causing Phoenix to think
|
|
|
|
# that the live version is up-to-date).
|
|
|
|
#
|
|
|
|
# Each tool has various work-arounds to make this work, but the simplest thing
|
|
|
|
# (for editors started from the terminal) is to simply change the environment
|
|
|
|
# everything runs under by default.
|
2020-06-13 14:32:29 +10:00
|
|
|
editor="env MIX_ENV=test $editor"
|
2019-08-29 10:02:43 +10:00
|
|
|
|
2011-11-04 03:37:31 +11:00
|
|
|
export EDITOR="$editor -f"
|
|
|
|
export VISUAL="$editor"
|
2009-03-20 00:08:06 +11:00
|
|
|
|
2020-06-13 14:32:29 +10:00
|
|
|
# Enable shell history in IEx and Erlang REPLs
|
|
|
|
export ERL_AFLAGS="-kernel shell_history enabled"
|
|
|
|
|
2011-10-24 11:06:03 +11:00
|
|
|
export TERM=xterm-256color
|
2009-03-20 00:08:06 +11:00
|
|
|
export CLICOLOR=1
|
|
|
|
|
2009-04-26 16:55:34 +10:00
|
|
|
export HISTSIZE=1000000
|
2011-11-23 07:34:53 +11:00
|
|
|
export HISTIGNORE="clear:bg:fg:cd:cd -:exit:date:w:* --help"
|
2011-03-30 14:03:08 +11:00
|
|
|
|
2013-10-12 04:01:55 +11:00
|
|
|
export GOPATH="$HOME/Code/Go"
|
2015-09-02 12:37:59 +10:00
|
|
|
PATH="$PATH:$GOPATH/bin"
|