From af53908079962c3208d2dbf6a2c98b5862f4c0b5 Mon Sep 17 00:00:00 2001 From: Jonas Gunz Date: Sun, 26 Jan 2020 20:16:38 +0100 Subject: custom bashit theme, vim changes --- .bashrc | 2 +- .vim/vimrc | 7 +++++-- theme.bash | 26 ++++++++++++++++++++++++++ 3 files changed, 32 insertions(+), 3 deletions(-) create mode 100644 theme.bash diff --git a/.bashrc b/.bashrc index be141bc..109fe0a 100644 --- a/.bashrc +++ b/.bashrc @@ -14,7 +14,7 @@ export BASH_IT="/home/jonas/vimconfig/bash-it" # Lock and Load a custom theme file. # Leave empty to disable theming. # location /.bash_it/themes/ -export BASH_IT_THEME='bakke' +export BASH_IT_THEME='/home/jonas/vimconfig/theme.bash' # (Advanced): Change this to the name of your remote repo if you # cloned bash-it with a remote other than origin such as `bash-it`. diff --git a/.vim/vimrc b/.vim/vimrc index b21d04a..9d93917 100644 --- a/.vim/vimrc +++ b/.vim/vimrc @@ -17,6 +17,9 @@ let g:airline#extensions#branch#enabled = 1 let g:airline#extensions#whitespace#enabled = 1 let g:airline_powerline_fonts = 1 +"show line endings and tabs +set list + " Use todo#Complete as the omni complete function for todo files au filetype todo setlocal omnifunc=todo#Complete @@ -51,7 +54,7 @@ set foldmethod=syntax "nmap :wincmd h "nmap :wincmd l -nmap :vsplit +nmap :vsplit:e . nmap :e . nnoremap @=(foldlevel('.')?'za':"\") @@ -69,7 +72,7 @@ nmap :Newterm nmap :tabclose nmap :tabprevious nmap :tabnext -nmap :tabnew +nmap :tabnew:e . " =========== diff --git a/theme.bash b/theme.bash new file mode 100644 index 0000000..648dfb6 --- /dev/null +++ b/theme.bash @@ -0,0 +1,26 @@ +#!/usr/bin/env bash +SCM_THEME_PROMPT_DIRTY=" ${red}✗" +SCM_THEME_PROMPT_CLEAN=" ${bold_green}✓" +SCM_THEME_PROMPT_PREFIX=" |" +SCM_THEME_PROMPT_SUFFIX="${green}|" + +GIT_THEME_PROMPT_DIRTY=" ${red}✗" +GIT_THEME_PROMPT_CLEAN=" ${bold_green}✓" +GIT_THEME_PROMPT_PREFIX=" ${green}|" +GIT_THEME_PROMPT_SUFFIX="${green}|" + +RVM_THEME_PROMPT_PREFIX="|" +RVM_THEME_PROMPT_SUFFIX="|" + +function prompt_command() { + #PS1="${bold_cyan}$(scm_char)${green}$(scm_prompt_info)${purple}$(ruby_version_prompt) ${yellow}\h ${reset_color}in ${green}\w ${reset_color}\n${green}→${reset_color} " + #PS1="\n${purple}\h: ${reset_color} ${green}\w\n${bold_cyan}$(scm_char)${green}$(scm_prompt_info) ${green}→${reset_color} " + #PS1="\n${cyan}\h: ${reset_color} ${yellow}\w\n${red}$(scm_char)${red}$(scm_prompt_info) ${green}→${reset_color} " + local EXIT="$?" + if [ $EXIT -eq 0 ]; then + EXIT="" + fi + PS1="\n${cyan}\h:$(virtualenv_prompt) ${reset_color} ${yellow}\w ${green}$(scm_prompt_info)\n${red}${EXIT} ${reset_color}→ " +} + +safe_append_prompt_command prompt_command -- cgit v1.2.3