bashrc added to my_config
This commit is contained in:
parent
9f82db520d
commit
859b88590c
5
.bashrc.d/BASHRC_ADDON
Normal file
5
.bashrc.d/BASHRC_ADDON
Normal file
@ -0,0 +1,5 @@
|
||||
# You may want to put all your additions into a folder file like
|
||||
# ~/.bashrc.d instead of adding them here directly.
|
||||
for file in ~/.bashrc.d/*.sh; do
|
||||
. $file
|
||||
done
|
17
.bashrc.d/__available__/aliases.sh
Normal file
17
.bashrc.d/__available__/aliases.sh
Normal file
@ -0,0 +1,17 @@
|
||||
# enable color support of ls and also add handy aliases
|
||||
if [ -x /usr/bin/dircolors ]; then
|
||||
test -r ~/.dircolors && eval "$(dircolors -b ~/.dircolors)" || eval "$(dircolors -b)"
|
||||
alias ls='ls --color=auto'
|
||||
alias dir='dir -lh --color=auto'
|
||||
#alias vdir='vdir --color=auto'
|
||||
|
||||
alias grep='grep --color=auto'
|
||||
alias fgrep='fgrep --color=auto'
|
||||
alias egrep='egrep --color=auto'
|
||||
fi
|
||||
|
||||
# some more ls aliases
|
||||
alias ll='ls -alF'
|
||||
alias la='ls -A'
|
||||
alias l='ls -CF'
|
||||
alias less='less -iS'
|
4
.bashrc.d/__available__/aliases_extended.sh
Normal file
4
.bashrc.d/__available__/aliases_extended.sh
Normal file
@ -0,0 +1,4 @@
|
||||
# some more ls aliases
|
||||
alias dd='dd status=progress'
|
||||
alias dd_status="watch -n5 'sudo kill -USR1 $(pgrep ^dd)'"
|
||||
alias ssh='ssh -X'
|
1
.bashrc.d/__available__/bell-none.sh
Normal file
1
.bashrc.d/__available__/bell-none.sh
Normal file
@ -0,0 +1 @@
|
||||
bind 'set bell-style none'
|
4
.bashrc.d/__available__/bin.sh
Normal file
4
.bashrc.d/__available__/bin.sh
Normal file
@ -0,0 +1,4 @@
|
||||
# set PATH so it includes user's private bin if it exists
|
||||
if [ -d "$HOME/bin" ] ; then
|
||||
PATH="$HOME/bin:$PATH"
|
||||
fi
|
2
.bashrc.d/__available__/git_prompt.sh
Normal file
2
.bashrc.d/__available__/git_prompt.sh
Normal file
@ -0,0 +1,2 @@
|
||||
PS1='$(giti)'"$PS1"
|
||||
export PS1
|
3
.bashrc.d/__available__/neofetch.sh
Normal file
3
.bashrc.d/__available__/neofetch.sh
Normal file
@ -0,0 +1,3 @@
|
||||
neofetch
|
||||
|
||||
|
14
.bashrc.d/__available__/powerline.sh
Normal file
14
.bashrc.d/__available__/powerline.sh
Normal file
@ -0,0 +1,14 @@
|
||||
#!/bin/sh
|
||||
#
|
||||
|
||||
# You need to install powerline and fonts-powerline
|
||||
#
|
||||
# You need to install powerline-gitstatus by sudo pip install powerline-gitstatus
|
||||
# See also powerline.zip for the content in ~/config/powerline
|
||||
|
||||
if [ ! `which powerline-daemon` == "" ]; then
|
||||
powerline-daemon -q
|
||||
POWERLINE_BASH_SELECT=1
|
||||
POWERLINE_BASH_CONTINUATION=1
|
||||
. /usr/share/powerline/bindings/bash/powerline.sh
|
||||
fi
|
2
.bashrc.d/__available__/prompt_debian.sh
Normal file
2
.bashrc.d/__available__/prompt_debian.sh
Normal file
@ -0,0 +1,2 @@
|
||||
PS1='\[\e]0;\u@\h: \w\a\]${debian_chroot:+($debian_chroot)}\[\033[01;32m\]\u@\h\[\033[00m\]:\[\033[01;34m\]\w\[\033[00m\]\$ '
|
||||
|
3
.bashrc.d/__available__/pytux_32.sh
Normal file
3
.bashrc.d/__available__/pytux_32.sh
Normal file
File diff suppressed because one or more lines are too long
3
.bashrc.d/__available__/pytux_48.sh
Normal file
3
.bashrc.d/__available__/pytux_48.sh
Normal file
File diff suppressed because one or more lines are too long
3
.bashrc.d/__available__/root_prompt.sh
Normal file
3
.bashrc.d/__available__/root_prompt.sh
Normal file
@ -0,0 +1,3 @@
|
||||
PS1="\033[1;31m$PS1\033[00m"
|
||||
export PS1
|
||||
|
5
.bashrc.d/__available__/tmux_local.sh
Normal file
5
.bashrc.d/__available__/tmux_local.sh
Normal file
@ -0,0 +1,5 @@
|
||||
#!/bin/sh
|
||||
#
|
||||
~/bin/tmux_ssh
|
||||
|
||||
|
5
.bashrc.d/__available__/todo.sh
Normal file
5
.bashrc.d/__available__/todo.sh
Normal file
@ -0,0 +1,5 @@
|
||||
#!/bin/sh
|
||||
#
|
||||
if [ -r ~/todo.txt ]; then
|
||||
cat ~/todo.txt
|
||||
fi
|
19
.bashrc.d/__available__/venv_prompt.sh
Normal file
19
.bashrc.d/__available__/venv_prompt.sh
Normal file
@ -0,0 +1,19 @@
|
||||
function venv_status {
|
||||
COLOR_WHITE="\033[00m"
|
||||
COLOR_CYAN="\033[1;36m"
|
||||
COLOR_RED="\033[1;31m"
|
||||
COLOR_YELLOW="\033[1;33m"
|
||||
COLOR_DARKYELLOW="\033[0;33m"
|
||||
COLOR_GREEN="\033[1;32m"
|
||||
COLOR_DARKGREEN="\033[0;32m"
|
||||
COLOR_OCHRE="\033[38;5;95m"
|
||||
|
||||
if [[ ! $VIRTUAL_ENV == "" ]]; then
|
||||
echo -e "$COLOR_DARKGREEN(🐍 `basename \"$VIRTUAL_ENV\"`)$COLOR_OCHRE "
|
||||
fi
|
||||
}
|
||||
|
||||
export VIRTUAL_ENV_DISABLE_PROMPT=1
|
||||
PS1='$(venv_status)'"$PS1"
|
||||
export PS1
|
||||
|
5
.bashrc.d/my_defaults
Normal file
5
.bashrc.d/my_defaults
Normal file
@ -0,0 +1,5 @@
|
||||
ln -vs __available__/aliases.sh
|
||||
ln -vs __available__/bin.sh
|
||||
ln -vs __available__/neofetch.sh
|
||||
ln -vs __available__/powerline.sh
|
||||
ln -vs __available__/todo.sh
|
17
add_bash
Executable file
17
add_bash
Executable file
@ -0,0 +1,17 @@
|
||||
#!/bin/zsh
|
||||
#
|
||||
SCRIPTPATH="$( cd -- "$(dirname "$0")" >/dev/null 2>&1 ; pwd -P )"
|
||||
|
||||
if [[ (-e ~/.bashrc.d) ]]; then
|
||||
echo "A bash configuration already exists (~/.bashrc.d)"
|
||||
echo "Remove this configuration and start the script again"
|
||||
else
|
||||
echo "Creating base link"
|
||||
ln -vs $SCRIPTPATH/.bashrc.d ~/.bashrc.d
|
||||
fi
|
||||
|
||||
GS=`grep .bashrc.d ~/.bashrc`
|
||||
if [ ${#GS} -eq 0 ]; then
|
||||
echo "Adding execution of scripts in ~.bashrc.d"
|
||||
cat ~/.bashrc.d/BASHRC_ADDON >> ~/.bashrc
|
||||
fi
|
Loading…
x
Reference in New Issue
Block a user