Gentoo installation script
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

52 lines
1.2 KiB

# /etc/profile
##
umask 022
## Load 'env-update' settings
if [ -e /etc/profile.env ]; then
source /etc/profile.env
fi
## Load scripts in '/etc/profile.d/'
for sh in /etc/profile.d/*.sh ; do
[ -r "$sh" ] && source "$sh"
done
## Give root a separate PATH including sbin
if [ "${EUID-}" = "0" ] || [ "${USER-}" = "root" ]; then
PATH="${ROOTPATH}:/usr/share/bcc/tools/"
MANPATH="${MANPATH}:/usr/share/bcc/man/man8"
fi
## Exports
export ARCHFLAGS="-arch x86_64"
export EDITOR='vim|emacsclient -ca ""'
export HISTTIMEFORMAT="(%m/%d/%y) %T "
export MANPATH
export PAGER="${PAGER:-/usr/bin/less}"
export PATH
export PROMPT_COMMAND="history -a"
export SSH_KEY_PATH="${HOME}/.ssh/rsa_id"
export TERM="xterm"
export ZSH="${HOME}/.oh-my-zsh"
export ZSH_THEME="gentoo"
## Bash settings
if [ -n "${BASH_VERSION-}" ]; then
[ -f /etc/bash/bashrc ] && source /etc/bash/bashrc
PS1="[\u@\h \w]\$ "
fi
## Zsh settings
if [ -n "${ZSH_VERSION-}" ]; then
[ -f /etc/zsh/zprofile ] && source /etc/zsh/zprofile
[ ! -e ${ZSH} ] && \
rawGH="https://raw.githubusercontent.com/robbyrussell/oh-my-zsh" && \
curl -fsSL $rawGH/master/tools/install.sh | sh
PS1="[%n@%m %1d]$ "
fi
## Cleanup
unset ROOTPATH
unset sh