home/common | add nix stuff to .bashrc
This commit is contained in:
parent
8d0ff0e8df
commit
d08176943c
1 changed files with 12 additions and 26 deletions
|
|
@ -18,32 +18,21 @@
|
||||||
|
|
||||||
# set some global stuff first
|
# set some global stuff first
|
||||||
|
|
||||||
# colors
|
|
||||||
GREEN='[01;32m'
|
|
||||||
YELLOW='[01;33m'
|
|
||||||
RED='[01;31m'
|
|
||||||
NONE='[01;0m'
|
NONE='[01;0m'
|
||||||
PATH="${HOME}/bin:/run/wrappers/bin:${HOME}/.nix-profile/bin:/etc/profiles/per-user/${USER}/bin:/nix/var/nix/profiles/default/bin:/run/current-system/sw/bin:${HOME}/go/bin:${HOME}/.local/bin:${HOME}/.cargo/bin:${HOME}/.local/share/gem/ruby/latest/bin"
|
PATH="${HOME}/bin:/run/wrappers/bin:${HOME}/.nix-profile/bin:/etc/profiles/per-user/${USER}/bin:/nix/var/nix/profiles/default/bin:/run/current-system/sw/bin:${HOME}/go/bin:${HOME}/.local/bin:${HOME}/.cargo/bin:${HOME}/.local/share/gem/ruby/latest/bin"
|
||||||
GOPATH="${HOME}/go"
|
GOPATH="${HOME}/go"
|
||||||
export NONE GREEN YELLOW RED
|
|
||||||
export PATH
|
export PATH
|
||||||
export GOPATH
|
export GOPATH
|
||||||
|
export NIXPKGS_ALLOW_UNFREE=1
|
||||||
|
export NIXPKGS_ALLOW_INSECURE=1
|
||||||
|
|
||||||
if [ -f ${HOME}/.nix-profile/etc/profile.d/hm-session-vars.sh ]
|
if [ -f ${HOME}/.nix-profile/etc/profile.d/hm-session-vars.sh ]; then
|
||||||
then
|
|
||||||
. ${HOME}/.nix-profile/etc/profile.d/hm-session-vars.sh
|
. ${HOME}/.nix-profile/etc/profile.d/hm-session-vars.sh
|
||||||
fi
|
fi
|
||||||
|
|
||||||
HOSTNAME_SHORT=$(hostnamectl | awk -F: '$1=/Static hostname/{print $2}' | sed 's/^ //')
|
HOSTNAME_SHORT=$(hostnamectl | awk -F: '$1=/Static hostname/{print $2}' | sed 's/^ //')
|
||||||
while [ "${HOSTNAME_SHORT}" == "localhost" ]
|
|
||||||
do
|
|
||||||
echo "${RED}@${GREEN}-,---${NONE}"
|
|
||||||
sleep 1
|
|
||||||
HOSTNAME_SHORT=$(hostnamectl | awk -F: '$1=/Static hostname/{print $2}' | sed 's/^ //')
|
|
||||||
done
|
|
||||||
export HOSTNAME_SHORT
|
export HOSTNAME_SHORT
|
||||||
|
|
||||||
|
|
||||||
# set coredump size to 0
|
# set coredump size to 0
|
||||||
ulimit -c 0
|
ulimit -c 0
|
||||||
|
|
||||||
|
|
@ -65,8 +54,7 @@ test -d "${HOME}/bin/${HOSTNAME_SHORT}" && PATH="${PATH}:${HOME}/bin/${HOSTNAME_
|
||||||
######### #########
|
######### #########
|
||||||
#####################################
|
#####################################
|
||||||
|
|
||||||
if [ "${PS1}" ];
|
if [ "${PS1}" ]; then
|
||||||
then
|
|
||||||
unset i
|
unset i
|
||||||
set -o noclobber
|
set -o noclobber
|
||||||
set -o notify
|
set -o notify
|
||||||
|
|
@ -101,14 +89,12 @@ then
|
||||||
unset COMPHOSTS
|
unset COMPHOSTS
|
||||||
export COMPHOSTS=()
|
export COMPHOSTS=()
|
||||||
|
|
||||||
|
|
||||||
unset pathmunge
|
unset pathmunge
|
||||||
# set up man path
|
# set up man path
|
||||||
MANPATH="${MANPATH}:${HOME}/man:${HOME}/share/man"
|
MANPATH="${MANPATH}:${HOME}/man:${HOME}/share/man"
|
||||||
export MANPATH
|
export MANPATH
|
||||||
|
|
||||||
|
test -f $(ls -1 /nix/store/*bash-completion-*/etc/profile.d/bash_completion.sh | tail -n1) &&
|
||||||
test -f $(ls -1 /nix/store/*bash-completion-*/etc/profile.d/bash_completion.sh | tail -n1) && \
|
|
||||||
source $(ls -1 /nix/store/*bash-completion-*/etc/profile.d/bash_completion.sh | tail -n1)
|
source $(ls -1 /nix/store/*bash-completion-*/etc/profile.d/bash_completion.sh | tail -n1)
|
||||||
|
|
||||||
export LOCKPRG=${HOME}/bin/myLock
|
export LOCKPRG=${HOME}/bin/myLock
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue