Compare commits

..

12 Commits

6 changed files with 1240 additions and 13 deletions

1115
.ansible.cfg Normal file

File diff suppressed because it is too large Load Diff

View File

@ -56,6 +56,9 @@ function parse_git_branch {
#export PS1='\u@\h \[\033[1;33m\]\w \[\033[0m\]$(parse_git_branch)$ '
export PS1='\[\033[1;31m\]\u@\h \[\033[1;34m\]\w \[\033[1;32m\]$(parse_git_branch)\[\033[0m\]$ '
# bind commands
bind '"\C-k"':kill-line # clear to end of line
# Local customized path and environment settings, etc.
if [ -f ~/.bashrc.local ]; then
. ~/.bashrc.local

4
.bashrc.local Normal file
View File

@ -0,0 +1,4 @@
# Activate Starship command prompt
if [ -f /usr/local/bin/starship ]; then
eval "$(starship init bash)"
fi

View File

@ -224,14 +224,14 @@ tmux_conf_theme_window_status_last_bg="$tmux_conf_theme_colour_2"
tmux_conf_theme_window_status_last_attr="none"
# status left/right sections separators
tmux_conf_theme_left_separator_main=""
tmux_conf_theme_left_separator_sub="|"
tmux_conf_theme_right_separator_main=""
tmux_conf_theme_right_separator_sub="|"
#tmux_conf_theme_left_separator_main="\uE0B0" # /!\ you don't need to install Powerline
#tmux_conf_theme_left_separator_sub="\uE0B1" # you only need fonts patched with
#tmux_conf_theme_right_separator_main="\uE0B2" # Powerline symbols or the standalone
#tmux_conf_theme_right_separator_sub="\uE0B3" # PowerlineSymbols.otf font, see README.md
#tmux_conf_theme_left_separator_main=""
#tmux_conf_theme_left_separator_sub="|"
#tmux_conf_theme_right_separator_main=""
#tmux_conf_theme_right_separator_sub="|"
tmux_conf_theme_left_separator_main="\uE0B0" # /!\ you don't need to install Powerline
tmux_conf_theme_left_separator_sub="\uE0B1" # you only need fonts patched with
tmux_conf_theme_right_separator_main="\uE0B2" # Powerline symbols or the standalone
mux_conf_theme_right_separator_sub="\uE0B3" # PowerlineSymbols.otf font, see README.md
# status left/right content:
# - separate main sections with "|"
@ -261,7 +261,7 @@ tmux_conf_theme_right_separator_sub="|"
# - #{username}
# - #{username_ssh}
tmux_conf_theme_status_left=" ❐ #S | ↑#{?uptime_y, #{uptime_y}y,}#{?uptime_d, #{uptime_d}d,}#{?uptime_h, #{uptime_h}h,}#{?uptime_m, #{uptime_m}m,} "
tmux_conf_theme_status_right=" #{prefix}#{mouse}#{pairing}#{synchronized} #(curl wttr.in?format=3) #{?battery_status,#{battery_status},}#{?battery_bar, #{battery_bar},}#{?battery_percentage, #{battery_percentage},} , %R , %d %b | #{username}#{root} | #{hostname} "
tmux_conf_theme_status_right=" #{prefix}#{mouse}#{pairing}#{synchronized} #(curl #{?battery_status,#{battery_status},}#{?battery_bar, #{battery_bar},}#{?battery_percentage, #{battery_percentage},} , %R , %d %b | #{username}#{root} | #{hostname} "
# status left style
tmux_conf_theme_status_left_fg="$tmux_conf_theme_colour_6,$tmux_conf_theme_colour_7,$tmux_conf_theme_colour_8"

View File

@ -6,9 +6,9 @@
########## Variables
dir=~/dotfiles # dotfiles directory
olddir=~/dotfiles_old # old dotfiles backup directory
files=".tmux.conf .tmux.conf.local .vimrc .vim .tcshrc .bashrc .inputrc .git_completion" # list of files/folders to symlink in homedir
dir=~/.dotfiles # dotfiles directory
olddir=~/.dotfiles_old # old dotfiles backup directory
files=".tmux.conf .tmux.conf.local .vimrc .vim .tcshrc .bashrc .inputrc .git_completion .ansible.cfg" # list of files/folders to symlink in homedir
##########
@ -25,7 +25,18 @@ echo "...done"
# move any existing dotfiles in homedir to dotfiles_old directory, then create symlinks
for file in $files; do
echo "Moving any existing dotfiles from ~ to $olddir"
mv ~/$file ~/dotfiles_old/ > /dev/null 2>&1
mv ~/$file ~/.dotfiles_old/ > /dev/null 2>&1
echo "Creating symlink to $file in home directory."
ln -s $dir/$file ~/$file > /dev/null 2>&1
done
# link Starship config to ~/.config/ if exists
if [ -d ~/.config ]; then
ln -s $dir/starship.toml ~/.config/starship.toml
fi
# copy example bashrc.local if one doesn't exist yet
if [ ! -f ~/.bashrc.local ]; then
cp $file/.bashrc.local ~/.bashrc.local
fi

94
starship.toml Normal file
View File

@ -0,0 +1,94 @@
command_timeout = 500
format = "$username$hostname: $directory$git_branch$python$aws$time$cmd_duration$character"
[line_break]
disabled = true
[character]
success_symbol = "[➜](bold green) "
error_symbol = "[✗](bold red) "
[cmd_duration]
min_time = 500
format = "took [$duration](bold yellow) "
[env_var.SHELL]
variable = "SHELL"
default = "unknown shell"
[env_var.USER]
default = "unknown user"
[username]
style_user = "blue bold"
style_root = "red bold"
format = "[$user]($style)"
disabled = false
show_always = true
[hostname]
ssh_only = false
format = "[$ssh_symbol](bold blue) on [$hostname](bold yellow) "
trim_at = ".strog.org"
disabled = false
[directory]
read_only = " "
truncation_length = 8
truncation_symbol = "…/"
use_os_path_sep = true
[shell]
fish_indicator = ""
powershell_indicator = "_"
unknown_indicator = "mystery shell"
style = "cyan bold"
disabled = false
[status]
style = "bg:blue"
symbol = "🔴 "
success_symbol = "🟢 SUCCESS"
format = '[\[$symbol$common_meaning$signal_name$maybe_int\]]($style) '
map_symbol = true
disabled = false
[aws]
disabled = true
format = ' AWS:[$symbol($profile )(\($region\))]($style)'
style = "bold blue"
#symbol = "\xe2\x98\x81\xef\xb8\x8f"
[aws.region_aliases]
us-west-1 = "us-west-1"
us-east-1 = "va"
[container]
format = "[$symbol \\[$name\\]]($style) "
[git_branch]
symbol = "  "
style = "bold #e8ec00 inverted"
format = "on [$symbol$branch ]($style) "
[git_commit]
disabled = false
[git_state]
disabled = false
[git_status]
disabled = false
[kubernetes]
format = 'on [☸ $context \($namespace\)](dimmed green) '
disabled = false
#[kubernetes.context_aliases]
#"dev.local.cluster.k8s" = "dev"
[package]
disabled = true
[python]
format = '[${symbol}${pyenv_prefix}(${version} )(\($virtualenv\))]($style)'
symbol = "🐍 "
pyenv_version_name = true