blob: b2c54115469dbda83d65f18eeb3bf3614807a233 (
plain) (
blame)
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
|
# set xdg runtime dir if it's not defined
if [ -z "${XDG_RUNTIME_DIR}" ]; then
export XDG_RUNTIME_DIR=/run/user/"$(id -u)"
if [ ! -d "${XDG_RUNTIME_DIR}" ]; then
mkdir -p "${XDG_RUNTIME_DIR}"
chmod 0700 "${XDG_RUNTIME_DIR}"
fi
fi
# set xdg cache dir if it's not defined
if [ -z "${XDG_CACHE_DIR}" ]; then
export XDG_CACHE_DIR=/tmp/"$(id -un)"/.cache
if [ ! -d "${XDG_CACHE_DIR}" ]; then
mkdir -p "${XDG_CACHE_DIR}"
chmod 0700 "${XDG_CACHE_DIR}"
fi
fi
if [ -d "${HOME}/bin" ]; then
pathprepend "${HOME}/bin"
pathprepend "${HOME}/bin/$(uname -n)"
fi
if [ -d "${HOME}/AppImages" ]; then
pathappend "${HOME}/AppImages"
fi
export GOPATH="${HOME}/go"
if [ -d "${GOPATH}" ]; then
pathappend "${GOPATH}/bin"
fi
if [ -d "${HOME}/.cargo/bin" ]; then
pathappend "${HOME}/.cargo/bin"
fi
if [ -d "/usr/src/rust" ]; then
export RUST_SRC_PATH=/usr/src/rust
fi
# Use the new build backend in docker
export DOCKER_BUILDKIT=1
# Parallel portage
export NUMCPUS=$(nproc)
export NUMCPUSplusone=$((NUMCPUS + 1))
export MAKEOPTS="-j${NUMCPUSplusone} -l${NUMCPUS}"
export EMERGE_DEFAULT_OPTS="--jobs=${NUMCPUSplusone} --load-average=${NUMCPUS}"
export GPG_TTY=$(tty)
# Set prompt
# export PS1="$(prompt)"
# enlable vi mode
set -o vi
bind -m vi-insert -x '"\C-l": clear'
# Set less default options
export LESS='--hilite-search --hilite-unread --long-prompt --raw-control-chars --chop-long-lines --quit-if-one-screen --no-init'
# Set the rsync ssh command to use by default
export RSYNC_RSH='ssh -T -x -o Compression=no'
|