From 687a64c30fa70eb2a27cba09599c33a68b18d910 Mon Sep 17 00:00:00 2001 From: Tucker Evans Date: Sun, 11 Mar 2018 21:42:10 -0400 Subject: Adds git-bash-prompt Also makes minor changes to other files --- .gitmodules | 3 +++ X/.Xresources | 4 ++-- bash/.bashrc | 22 ++++++++++++++++++++++ bash/.git-prompt | 1 + bash/.git-prompt-colors.sh | 32 ++++++++++++++++++++++++++++++++ i3/.config/i3/config | 7 ++++--- i3/.config/i3status/config | 4 ++-- installs.txt | 21 ++++++++++++++------- task/.taskrc | 34 ++++++++++++++++++++++++++++++++++ tmux/.tmux.conf | 5 ++++- 10 files changed, 118 insertions(+), 15 deletions(-) create mode 160000 bash/.git-prompt create mode 100644 bash/.git-prompt-colors.sh create mode 100644 task/.taskrc diff --git a/.gitmodules b/.gitmodules index 454c5ba..068b2dc 100644 --- a/.gitmodules +++ b/.gitmodules @@ -10,3 +10,6 @@ [submodule "vim/.vim/pack/tje/start/wordCount.vim"] path = vim/.vim/pack/tje/start/wordCount.vim url = git@github.com:ChesleyTan/wordCount.vim.git +[submodule "bash/.git-prompt"] + path = bash/.git-prompt + url = https://github.com/magicmonty/bash-git-prompt.git diff --git a/X/.Xresources b/X/.Xresources index 96a1863..f262dea 100644 --- a/X/.Xresources +++ b/X/.Xresources @@ -1,5 +1,5 @@ -XTerm*faceName: 3270Medium Nerd Font -UXTerm*faceName: 3270Medium Nerd Font +XTerm*faceName: IBM 3270 +UXTerm*faceName: IBM 3270 XTerm*faceSize: 16 diff --git a/bash/.bashrc b/bash/.bashrc index 6453f1e..11d51e4 100644 --- a/bash/.bashrc +++ b/bash/.bashrc @@ -23,6 +23,10 @@ alias rtv='rtv --enable-media' alias sloc='sloccount' +alias t='t --task-dir ~/tasks' + +alias fm='vifm' + PS1='[\u@\h \W]\$ ' export GPG_TTY=$(tty) @@ -36,3 +40,21 @@ export IRCNAME="tje" export IRCSERVER="chat.freenode.net" alias word=wordgrinder + +GIT_PROMPT_ONLY_IN_REPO=1 +GIT_PROMPT_IGNORE_SUBMODULES=1 +# GIT_PROMPT_FETCH_REMOTE_STATUS=0 # uncomment to avoid fetching remote status +GIT_PROMPT_SHOW_UPSTREAM=1 # uncomment to show upstream tracking branch +# GIT_PROMPT_SHOW_UNTRACKED_FILES=all # can be no, normal or all; determines counting of untracked files +# GIT_PROMPT_SHOW_CHANGED_FILES_COUNT=0 # uncomment to avoid printing the number of changed files +# GIT_PROMPT_STATUS_COMMAND=gitstatus_pre-1.7.10.sh # uncomment to support Git older than 1.7.10 +# GIT_PROMPT_START=... # uncomment for custom prompt start sequence +# GIT_PROMPT_END=... # uncomment for custom prompt end sequence + +# as last entry source the gitprompt script +# GIT_PROMPT_THEME=Custom # use custom theme specified in file GIT_PROMPT_THEME_FILE (default ~/.git-prompt-colors.sh) +GIT_PROMPT_THEME="Custom"; # use theme optimized for solarized color scheme +GIT_PROMPT_THEME_FILE=~/.git-prompt-colors.sh + +source /home/tje/.git-prompt/gitprompt.sh + diff --git a/bash/.git-prompt b/bash/.git-prompt new file mode 160000 index 0000000..19c8def --- /dev/null +++ b/bash/.git-prompt @@ -0,0 +1 @@ +Subproject commit 19c8def6a90d72f2a99d781752271126b1b9ff66 diff --git a/bash/.git-prompt-colors.sh b/bash/.git-prompt-colors.sh new file mode 100644 index 0000000..ff8a38a --- /dev/null +++ b/bash/.git-prompt-colors.sh @@ -0,0 +1,32 @@ +# This is an alternative approach. Single line minimalist in git repo. +override_git_prompt_colors() { + GIT_PROMPT_THEME_NAME="Custom" + + function prompt_callback { + local PS1="$(gp_truncate_pwd)" + gp_set_window_title "$PS1" + } + + Time12a="\$(date +%H:%M:%S)" + PathShort="\W"; + + GIT_PROMPT_PREFIX="[" + GIT_PROMPT_SUFFIX="]" + GIT_PROMPT_SEPARATOR=" " + GIT_PROMPT_STAGED="${Red}●${ResetColor}" + GIT_PROMPT_CONFLICTS="${Red}×${ResetColor}" + GIT_PROMPT_CHANGED="${Blue}+${ResetColor}" + GIT_PROMPT_UNTRACKED="${Cyan}─${ResetColor}" + GIT_PROMPT_STASHED="${BoldBlue}≡${ResetColor}" + GIT_PROMPT_CLEAN="${BoldGreen}✔${ResetColor}" + + GIT_PROMPT_COMMAND_OK="${Green}✔" + GIT_PROMPT_COMMAND_FAIL="${Red}✘" + + GIT_PROMPT_START_USER="${Cyan}${PathShort}${ResetColor}" + GIT_PROMPT_END_USER="${ResetColor} $ " + GIT_PROMPT_END_ROOT="${BoldRed} # " + +} + +reload_git_prompt_colors "Custom" diff --git a/i3/.config/i3/config b/i3/.config/i3/config index dae7dec..1705240 100644 --- a/i3/.config/i3/config +++ b/i3/.config/i3/config @@ -13,7 +13,7 @@ set $mod Mod1 # Font for window titles. Will also be used by the bar unless a different font # is used in the bar {} block below. -font pango:Courier Prime 14 +font pango:Courier Prime 8 # This font is widely installed, provides lots of unicode glyphs, right-to-left # text rendering and scalability on retina/hidpi displays (thanks to pango). @@ -30,7 +30,7 @@ font pango:Courier Prime 14 floating_modifier $mod # start a terminal - bindsym $mod+Return exec xterm + bindsym $mod+Return exec uxterm # kill focused window bindsym $mod+Shift+q kill @@ -160,6 +160,7 @@ bindsym $mod+r mode "resize" bar { status_command i3status separator_symbol " | " + font pango: 3270Medium Nerd Font 14 # colors { # background #414A59 # statusline #F5F6F7 @@ -188,7 +189,7 @@ bindsym XF86AudioPrev exec playerctl previous exec --no-startup-id synclient NaturalScrolling=1 VertScrollDelta=-113 exec --no-startup-id /home/tje/i3-battery-popup -N -bindsym $mod+b exec qutebrowser +bindsym $mod+b exec firefox bindsym $mod+p exec passmenu for_window [class="mpv"] floating enable diff --git a/i3/.config/i3status/config b/i3/.config/i3status/config index 36062e3..b4f4c36 100644 --- a/i3/.config/i3status/config +++ b/i3/.config/i3status/config @@ -64,7 +64,7 @@ disk "/" { } volume master { - format = "♪: %volume" - format_muted = "♪: muted (%volume)" + format = " %volume" + format_muted = " %volume" device = "pulse:alsa_output.pci-0000_00_1f.3.analog-stereo" } diff --git a/installs.txt b/installs.txt index 4da50b8..2ed4358 100644 --- a/installs.txt +++ b/installs.txt @@ -1,22 +1,29 @@ git vim cmus -i3/i3status +i3/i3status&dmenu pass gpg2|gpg mpv -ranger? +vifm|ranger qutebrowser|firefox task -ircii|irssi|weechat|ii|sic +ircii|sic|ii csh? feh? -elinks|lynx +w3m calcurse troff/grap/pic/env latex(texlive) gv|evince -mutt&offlineimap|fetchmail&msmtp -tmux +mutt&mbsync&msmtp +tmux|screen R - +tcc +base-devel +go +groff +man-pages/man-pages-devel +sc|scim +rtorrent? +wordgrinder? diff --git a/task/.taskrc b/task/.taskrc new file mode 100644 index 0000000..c0cbd46 --- /dev/null +++ b/task/.taskrc @@ -0,0 +1,34 @@ +# [Created by task 2.5.1 11/13/2017 14:07:09] +# Taskwarrior program configuration file. +# For more documentation, see http://taskwarrior.org or try 'man task', 'man task-color', +# 'man task-sync' or 'man taskrc' + +# Here is an example of entries that use the default, override and blank values +# variable=foo -- By specifying a value, this overrides the default +# variable= -- By specifying no value, this means no default +# #variable=foo -- By commenting out the line, or deleting it, this uses the default + +# Use the command 'task show' to see all defaults and overrides + +# Files +data.location=~/.task + +# Color theme (uncomment one to use) +#include /usr/local/share/doc/task/rc/light-16.theme +#include /usr/local/share/doc/task/rc/light-256.theme +include /usr/local/share/doc/task/rc/dark-16.theme +#include /usr/local/share/doc/task/rc/dark-256.theme +#include /usr/local/share/doc/task/rc/dark-red-256.theme +#include /usr/local/share/doc/task/rc/dark-green-256.theme +#include /usr/local/share/doc/task/rc/dark-blue-256.theme +#include /usr/local/share/doc/task/rc/dark-violets-256.theme +#include /usr/local/share/doc/task/rc/dark-yellow-green.theme +#include /usr/local/share/doc/task/rc/dark-gray-256.theme +#include /usr/local/share/doc/task/rc/dark-gray-blue-256.theme +#include /usr/local/share/doc/task/rc/solarized-dark-256.theme +#include /usr/local/share/doc/task/rc/solarized-light-256.theme +#include /usr/local/share/doc/task/rc/no-color.theme + +uda.priority.values=H,M,,L +alias.ls=next +default.command=next diff --git a/tmux/.tmux.conf b/tmux/.tmux.conf index 90ed13c..54e496b 100644 --- a/tmux/.tmux.conf +++ b/tmux/.tmux.conf @@ -14,4 +14,7 @@ bind h select-pane -L bind l select-pane -R -set -g status-bg magenta +#set -g status-bg magenta + + +set -g mouse on -- cgit v1.1