-
Notifications
You must be signed in to change notification settings - Fork 12
/
.exportsrc
105 lines (84 loc) · 3.17 KB
/
.exportsrc
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
# ~/.exportsrc
# Define shell exports.
# Invoked by .bash_profile and .zsrc files.
# Adds user's local bin directory.
[ -d "$HOME"/bin ] && export PATH="$PATH:$HOME/bin"
[ -d "$HOME"/.local/bin ] && export PATH="$PATH:$HOME/.local/bin"
# Architecture flags for x64
export ARCHFLAGS="-arch x86_64"
# Homebrew
ACCEPT_EULA=y
#HOMEBREW_NO_ENV_FILTERING=1
# Configure Apple's CLT package.
[ -d /usr/local/opt/apr/bin ] \
&& export PATH="/usr/local/opt/apr/bin:$PATH"
# Configure Ruby package on macOS.
[ -d /opt/homebrew/opt/ruby ] \
&& export CPPFLAGS="$CPPFLAGS -I/opt/homebrew/opt/ruby/include" \
&& export LDFLAGS="$LDFLAGS -L/opt/homebrew/opt/ruby/lib" \
&& export PATH="/opt/homebrew/opt/ruby/bin:$PATH" \
&& export PKG_CONFIG_PATH="$PKG_CONFIG_PATH /opt/homebrew/opt/ruby/lib/pkgconfig"
# Cargo (Rust package manager).
[ -d "$HOME"/.cargo/bin ] \
&& export PATH="$HOME/.cargo/bin:$PATH"
# CLI and ls colors.
export CLICOLOR=1
export LSCOLORS=ExFxCxDxBxegedabagacad
which dircolors &> /dev/null && eval "`dircolors`"
# Colored GCC warnings and errors.
export GCC_COLORS='error=01;31:warning=01;35:note=01;36:caret=01;32:locus=01:quote=01'
# Composer.
# Add a Composer's global bin directory if exists.
which composer >/dev/null && export PATH="$HOME/.composer/vendor/bin:$PATH"
# Increases Docker timeouts.
export COMPOSE_HTTP_TIMEOUT=600
export DOCKER_CLIENT_TIMEOUT=600
# Curl on macOS.
[ -d "/usr/local/opt/curl/bin" ] \
&& export PATH="/usr/local/opt/curl/bin:$PATH"
# Development variables.
export DYLD_FALLBACK_LIBRARY_PATH="/usr/X11/lib:/usr/lib" # See: http://stackoverflow.com/questions/10820981/dylibs-and-os-x
export FLEX_HOME="/usr/local/Cellar/flex_sdk/4.6.0.23201/libexec"
#export PHP_AUTOCONF="$(which autoconf)" # Install autoconf, which is needed for the installation of phpMyAdmin.
# Python 3.8
[ -d "$HOME"/Library/Python/3.8/bin ] \
&& export PATH="$PATH:$HOME/Library/Python/3.8/bin"
# Editor.
export EDITOR='vim'
# Fixes for sed.
# @see: http://www.delorie.com/gnu/docs/gawk/gawk_149.html
# @see: http://stackoverflow.com/q/19242275/55075
export LANG=C
export LC_CTYPE=C
# Go packages.
[ -d /usr/local/opt/go/libexec/bin ] \
&& export PATH=$PATH:/usr/local/opt/go/libexec/bin
# Notes for go package:
# A valid GOPATH is required to use the `go get` command.
# If $GOPATH is not specified, $HOME/go will be used by default
# @see: https://golang.org/doc/code.html#GOPATH
if [ -z "$GOPATH" ] && command -v go &> /dev/null; then
export GOPATH=$(go env GOPATH)
fi
# Rust
[ -d "$HOME"/.cargo/bin ] \
&& export PATH="$PATH:$HOME/.cargo/bin"
# Terminal colors (e.g. echo "${COLOR_RED}foo").
export COLOR_RESET=$(tput sgr0)
export COLOR_BLACK=$(tput setaf 0)
export COLOR_RED=$(tput setaf 1)
export COLOR_GREEN=$(tput setaf 2)
export COLOR_YELLOW=$(tput setaf 3)
export COLOR_BLUE=$(tput setaf 4)
export COLOR_MAGENTA=$(tput setaf 5)
export COLOR_CYAN=$(tput setaf 6)
export COLOR_WHITE=$(tput setaf 7)
# Misc
export PM_PACKAGES_ROOT=$HOME/packman-repo
# Set other options.
export LS_OPTIONS='-G -h'
# Set LC encoding to UTF-8.
# Fixes illegal byte sequence (http://stackoverflow.com/q/19242275/55075).
export LC_ALL=en_GB.UTF-8
export LANG=en_GB.UTF-8
export LANGUAGE="en_GB:en"