dotfiles
bugabingas dorkfiles
owned by bugabinga
fix git email
e137035e5e6938881d0454b48de06d808093d052
Oliver Jan Krylow <oliver@bugabinga.net> ·
unsigned
Browse filesCompare with HEAD
Changed files (5)
2 2 name
= Oliver Jan Krylow 3 - email
= olver@bugabinga.net 3 + email
= oliver@bugabinga.net 8 8 ~/.config/git/.gitconfig.include
11 +~/.local/bin/git-info
11 14 ~/.cargo/config.toml
new file mode 100755 42 +$0 [<options>] [<path>] 44 +$0 shows information about a Git repository. 47 +color?when show colored output (always|never|auto) 49 + eval "$(echo "$OPTS_SPEC" | git rev-parse --parseopt --stuck-long -- "$@" || echo exit $?)" 51 + while [ $# -gt 0
]; do 66 + die
"Unexpected option: $opt" 77 + if [ -n
"$GIT_DIR" ]; then 84 + die
"Too many arguments" 91 +initialize_colors () {
92 + if [ -z
"$COLOR" ]; then 93 + if git config --get-colorbool color.info
; then 102 + COLOR_BRANCH
=$COLOR 105 + if git config --get-colorbool color.branch
; then 106 + COLOR_BRANCH
=always 112 + die
"option \`color' expects \"always\", \"auto\", or \"never\"" 116 + if [ "$COLOR" = always
]; then 117 + REMOTE_COLOR
="$(get_color color.info.remote color.branch.remote red)" 118 + LOCAL_COLOR
="$(get_color color.info.local color.branch.local green)" 119 + PATH_COLOR
="$(get_color color.info.path '' 'bold')" 120 + REPOSITORY_COLOR
="$(get_color color.info.repository '' 'bold')" 121 + ID_COLOR
="$(get_color color.info.id '' 'yellow')" 122 + RESET_COLOR
=$(printf "\033[m") 134 + local key1
="$1" key2
="$2" fb
="$3" 135 + local color
="$(git config --get-color "$key1" '')" 138 + git config --get-color
"$key2" "$fb" 141 + printf '%s' "$color" 147 + local path
="$1" dir relpath root git_dir
149 + if [ -d
"$path" ]; then 150 + dir
="$(cd -P "$path" && pwd)" || die
"$path: Cannot cd to the directory" 156 + elif [ -f
"$path" ]; then 157 + dir
="$(dirname "$path")" 158 + dir
="$(cd -P "$dir" && pwd)" || die
"$dir: Cannot cd to the directory" 159 + relpath
="$(basename "$path")" 161 + die
"$path: No such file or directory" 164 + if [ -n
"$git_dir" ]; then 167 + elif case "$dir" in ?*.git
) [ -d
"$dir/objects" -a -d
"$dir/refs" ] ;;
*) false ;;
esac; then 172 + cd "$dir" || exit 1 173 + while [ ! -e .git ]; do 174 + [ "$(pwd)" = / ] && exit 1 178 + )" || die
"Not a git repository." 179 + git_dir
="$root/.git" 180 + if [ "$dir" = "$root" ]; then 182 + elif [ -n
"$relpath" ]; then 183 + relpath
="${dir#"$root/"}/$relpath" 185 + relpath
="${dir#"$root/"}" 190 + if [ -n
"$relpath" ]; then 191 + set -- "$@" "$relpath" 198 + local git_dir
="$1" relpath
="$2" root line field color reset
202 + echo "Repository Path: $PATH_COLOR$git_dir$RESET_COLOR" 204 + if [ $# -gt 0
]; then 205 + root
="$(dirname "$git_dir")" 206 + if [ "$relpath" = .
]; then 207 + echo "Path: $PATH_COLOR$root$RESET_COLOR" 209 + echo "Path: $PATH_COLOR$root/$relpath$RESET_COLOR" 215 + GIT_DIR
="$git_dir" git remote -v
> "$TEMPFILE" 216 + if [ -s
"$TEMPFILE" ]; then 217 + echo "Remote Repositories:" 218 + sed -e
"s/^\([^ ]\{1,\}\)\([ ]\{1,\}\)\([^ ]\{1,\}\)/$REMOTE_COLOR\1$RESET_COLOR\2$REPOSITORY_COLOR\3$RESET_COLOR/" \
223 + GIT_DIR
="$git_dir" git branch -r --color
=$COLOR_BRANCH
> "$TEMPFILE" 224 + if [ -s
"$TEMPFILE" ]; then 225 + echo "Remote Branches:" 226 + sed -e
"s/\([ ]\{1,\}->[ ]\{1,\}\)\([^ ]\{1,\}\)/\1$REMOTE_COLOR\2$RESET_COLOR/" \
227 + -e
's/^ */ /' "$TEMPFILE" 230 + GIT_DIR
="$git_dir" git branch --color
=$COLOR_BRANCH
> "$TEMPFILE" 231 + if [ -s
"$TEMPFILE" ]; then 232 + echo "Local Branches:" 233 + sed
's/^/ /' "$TEMPFILE" 236 + echo "Repository Configuration:" 237 + GIT_DIR
="$git_dir" git config --local --list
| sort
| {
240 + while read line
; do 243 + lhs
=$(expr "$line" : '\([^=]\{1,\}\)') 244 + rhs
=$(expr "$line" : '[^=]\{1,\}=\(.*\)') 247 + section
=$(expr "$lhs" : '\([^.]\{1,\}\)') 248 + subsection
=$(expr "$lhs" : '[^.]\{1,\}\.\(.\{1,\}\)\.') 249 + key
=$(expr "$lhs" : '[^.]\{1,\}\..\{1,\}\.\([^.]\{0,\}\)$') 250 + if [ "$section" != "$prev_section" -o
"$subsection" != "$prev_subsection" ]; then 251 + prev_section
=$section 252 + prev_subsection
=$subsection 255 + subsection
=$REMOTE_COLOR$subsection$RESET_COLOR 258 + subsection
=$LOCAL_COLOR$subsection$RESET_COLOR 260 + printf "\t[%s \"%s\"]\n" "$section" "$subsection" 264 + if [ "$key" = url
]; then 265 + rhs
=$REPOSITORY_COLOR$rhs$RESET_COLOR 269 + if [ "$key" = remote
]; then 270 + rhs
=$REMOTE_COLOR$rhs$RESET_COLOR 273 + printf "\t\t%s = %s\n" "$key" "$rhs" 276 + section
=$(expr "$lhs" : '\([^.]\{1,\}\)') 277 + key
=$(expr "$lhs" : '[^.]\{1,\}\.\([^.]\{1,\}\)$') 278 + if [ "$section" != "$prev_section" -o -n
"$prev_subsection" ]; then 279 + prev_section
=$section 281 + printf "\t[%s]\n" "$section" 283 + printf "\t\t$key = $rhs\n" 291 + (
cd "$root" && GIT_DIR
="$git_dir" git log --max-count
=1
"$@")
| {
292 + while read -r field line
; do 299 + reset
="$RESET_COLOR" 307 + echo "Last Changed $field $color$line$reset" 311 + echo "Last Changed Log:" 312 + sed
's/^ / /' "$TEMPFILE" 318 + [ "$#" -gt 0
] && echo "$0: $@" >&2 326 + if [ -z
"$TEMPFILE" ]; then 327 + TEMPFILE
="$(mktemp /tmp/git-info.XXXXXX)" || die
328 + trap "finalize; exit 130" 1 2 3 15
333 + if [ -n
"$TEMPFILE" ]; then wezterm/bugabinga/workspaces.lua
Modified31 31 local reign_tab, reign_pane, reign_window
= mux.spawn_window {
args = {
'hx',
'.' },
cwd = WORKSPACE
.. '/reign',
workspace =
33 33 local reign_right_pane
= reign_pane:split {
direction =
'Right',
size =
0.36 }
34 + reign_right_pane:send_text
"watch src {clear; just build}\n" 34 35 reign_right_pane:split {
direction =
'Bottom',
size =
0.33 }
35 36 reign_tab:set_title
'Reign Development' 36 - reign_right_pane:send_text
'watch src {clear; just build}\n' 37 37 reign_pane:activate()
39 39 local dork_tab, dork_pane, dork_window
= mux.spawn_window {
cwd = WORKSPACE
.. '/dotfiles',
workspace = dork_ws }
wezterm/wezterm.service
Modified3 3 Description=Wezterm Multiplexing Server
6 -ExecStart=/usr/bin/wezterm-mux-server
6 +# start with system shell as parent in order to inherit environment variables
7 +ExecStart=/bin/sh -c /usr/bin/wezterm-mux-server