Move a lot of stuff around
This commit is contained in:
parent
bc5ce9e725
commit
3a8eb5d475
65 changed files with 607 additions and 60 deletions
1
Makefile
1
Makefile
|
@ -1,5 +1,4 @@
|
|||
MAKEFILE_PATH ?= $(shell dirname $(realpath $(lastword $(MAKEFILE_LIST))))
|
||||
ALERT_AGREEMENT_FILE ?= "$(MAKEFILE_PATH)/.agreed-to-erasing-files.lock"
|
||||
|
||||
default: install
|
||||
|
||||
|
|
|
@ -387,7 +387,7 @@ margin-bottom = ${env:WINDOW_GAP:0}
|
|||
|
||||
[module/microphone]
|
||||
type = custom/script
|
||||
exec = $DOTFILES_PATH/de/bar/mic.bash
|
||||
exec = $DOTFILES_PATH/apps/de/bar/mic.bash
|
||||
tail = true
|
||||
format = <label>
|
||||
label-foreground = ${colors.icon}
|
|
@ -5,7 +5,7 @@ source "$HOME/.bashrc"
|
|||
# NO_COMPTON=1
|
||||
BORDER_WIDTH=5 # change in bspwm_config, here for launcher
|
||||
START_BAR=1
|
||||
BAR_COMMAND="$DOTFILES_PATH/de/bar/bar.bash"
|
||||
BAR_COMMAND="$DOTFILES_PATH/apps/de/bar/bar.bash"
|
||||
|
||||
if [[ -z "$XDG_CONFIG_HOME" ]]; then
|
||||
export XDG_CONFIG_HOME="$HOME/.config"
|
||||
|
@ -21,7 +21,7 @@ if [ -e "$BSPWM_STATE" ] ; then
|
|||
rm "$BSPWM_STATE"
|
||||
fi
|
||||
|
||||
source "$DOTFILES_PATH/de/bspwm/config"
|
||||
source "$DOTFILES_PATH/apps/de/bspwm/config"
|
||||
|
||||
# TODO: switch to alacritty
|
||||
if command -v urxvtd >/dev/null 2>&1; then
|
||||
|
@ -38,8 +38,8 @@ if command -v sxhkd >/dev/null 2>&1; then
|
|||
sxhkd -m -1 &
|
||||
fi
|
||||
|
||||
if [ -f "$DOTFILES_PATH/de/x/loadresources" ]; then
|
||||
"$DOTFILES_PATH/de/x/loadresources"
|
||||
if [ -f "$DOTFILES_PATH/apps/de/x/loadresources" ]; then
|
||||
"$DOTFILES_PATH/apps/de/x/loadresources"
|
||||
fi
|
||||
|
||||
if [ -f "$HOME/.fehbg" ]; then
|
|
@ -43,4 +43,4 @@ export SSH_AUTH_SOCK
|
|||
# autocutsel -selection SECONDARY -fork &
|
||||
|
||||
# fire up wm
|
||||
exec "$DOTFILES_PATH/de/bspwm/wmstart"
|
||||
exec "$DOTFILES_PATH/apps/de/bspwm/wmstart"
|
|
@ -19,7 +19,7 @@ fi
|
|||
sysresources="/etc/X11/xinit/.Xresources"
|
||||
sysmodmap="/etc/X11/xinit/.Xmodmap"
|
||||
userresources="$HOME/.Xresources"
|
||||
usercolors="$DOTFILES_PATH/scripts/colors/xresources"
|
||||
usercolors="$DOTFILES_PATH/bin/lib/colors/xresources"
|
||||
userenv="$EDFP/x/${ENV_TYPE}resources"
|
||||
usermodmap="$EDFP/x/modmap"
|
||||
|
|
@ -36,8 +36,8 @@ if [ -f "$HOME/.xmodmap" ]; then
|
|||
xmodmap "$HOME/.xmodmap"
|
||||
fi
|
||||
|
||||
if [ -f "$DOTFILES_PATH/de/x/loadresources" ]; then
|
||||
"$DOTFILES_PATH/de/x/loadresources"
|
||||
if [ -f "$DOTFILES_PATH/apps/de/x/loadresources" ]; then
|
||||
"$DOTFILES_PATH/apps/de/x/loadresources"
|
||||
fi
|
||||
|
||||
if command -v xcape >/dev/null 2>&1; then
|
|
@ -20,31 +20,31 @@ export NICE_HOME
|
|||
export NOTES_DIR="$NICE_HOME/doc/notes"
|
||||
|
||||
# set our PATH
|
||||
source "$DOTFILES_PATH/shell/bash/paths"
|
||||
source "$DOTFILES_PATH/apps/shell/bash/paths"
|
||||
|
||||
# stop parsing on a non-interactive shell
|
||||
[ -z "$PS1" ] && return
|
||||
|
||||
# load our key binds
|
||||
case $- in
|
||||
*i*) bind -f "$DOTFILES_PATH/shell/inputrc";;
|
||||
*i*) bind -f "$DOTFILES_PATH/apps/shell/inputrc";;
|
||||
*) ;;
|
||||
esac
|
||||
|
||||
# import our aliases
|
||||
source "$DOTFILES_PATH/shell/bash/aliases"
|
||||
source "$DOTFILES_PATH/apps/shell/bash/aliases"
|
||||
|
||||
# import our autocompletions
|
||||
source "$DOTFILES_PATH/shell/bash/autocompletions"
|
||||
source "$DOTFILES_PATH/apps/shell/bash/autocompletions"
|
||||
|
||||
# load our vconsole colors
|
||||
if [ "${TERM%%-*}" = 'linux' ] && [[ $- == *i* ]]; then
|
||||
BASE16_SHELL="$DOTFILES_PATH/scripts/colors/vconsole"
|
||||
BASE16_SHELL="$DOTFILES_PATH/bin/lib/colors/vconsole"
|
||||
[[ -s "$BASE16_SHELL" ]] && source "$BASE16_SHELL"
|
||||
fi
|
||||
|
||||
# load our terminal colors
|
||||
BASE16_SHELL="$DOTFILES_PATH/scripts/colors/shell"
|
||||
BASE16_SHELL="$DOTFILES_PATH/bin/lib/colors/shell"
|
||||
[[ -s "$BASE16_SHELL" ]] && source "$BASE16_SHELL"
|
||||
|
||||
# disable ctrl-s terminal freeze
|
||||
|
@ -54,7 +54,7 @@ BASE16_SHELL="$DOTFILES_PATH/scripts/colors/shell"
|
|||
shopt -s globstar
|
||||
|
||||
# import our prompt
|
||||
source "$DOTFILES_PATH/shell/bash/prompt"
|
||||
source "$DOTFILES_PATH/apps/shell/bash/prompt"
|
||||
|
||||
# prevents binds or commands pulling from history from insta-sending, and
|
||||
# instead places them in the readline for editing
|
|
@ -1,6 +1,6 @@
|
|||
#!/usr/bin/env bash
|
||||
|
||||
source "$DOTFILES_PATH/de/bar/bar.bash" --just-vars
|
||||
source "$DOTFILES_PATH/apps/de/bar/bar.bash" --just-vars
|
||||
|
||||
LAUNCHER_FONT="$BAR_FONT"
|
||||
LAUNCHER_FONT_SIZE="$BAR_FONT_SIZE"
|
||||
|
|
20
bin/lib/colors/generator/gen.moon
Executable file
20
bin/lib/colors/generator/gen.moon
Executable file
|
@ -0,0 +1,20 @@
|
|||
#!/usr/bin/env moon
|
||||
|
||||
scheme_file = "donokai"
|
||||
template_file = [
|
||||
"shell"
|
||||
]
|
||||
|
||||
scheme = require(scheme_file)!
|
||||
|
||||
scheme.meta = scheme.meta || {}
|
||||
scheme.meta.author = scheme.meta.author || "Unknown Author"
|
||||
scheme.meta.name = scheme.meta.name || "Unnamed Color Scheme"
|
||||
|
||||
for f in template_files
|
||||
template_data = require(t)!
|
||||
|
||||
colors = scheme.colors
|
||||
if "function" == type template_data.color_map
|
||||
colors = {template_data.color_map(k, v) for k, v in pairs(colors)}
|
||||
|
22
bin/lib/colors/generator/schemes/donokai.moon
Normal file
22
bin/lib/colors/generator/schemes/donokai.moon
Normal file
|
@ -0,0 +1,22 @@
|
|||
=>
|
||||
meta:
|
||||
name: "Donokai"
|
||||
author: "Daniel Flanagan (https://lyte.dev)"
|
||||
|
||||
colors:
|
||||
base00: "111111" -- background, dark grey
|
||||
base01: "383830" -- lighter grey
|
||||
base02: "49483e" -- lighter grey
|
||||
base03: "75715e" -- pale-ish yellow
|
||||
base04: "a59f85" -- lighter peuce
|
||||
base05: "f8f8f2" -- foreground white
|
||||
base06: "f5f4f1" -- foreground 2 white
|
||||
base07: "f9f8f5" -- foreground 3 white
|
||||
base08: "f92672" -- magenta
|
||||
base09: "fd971f" -- orange
|
||||
base0A: "f4bf75" -- yellow
|
||||
base0B: "a6e22e" -- green
|
||||
base0C: "a1efe4" -- cyan
|
||||
base0D: "66d9ef" -- blue
|
||||
base0E: "ae81ff" -- purple
|
||||
base0F: "cc6633" -- pale orange
|
251
bin/lib/colors/generator/templates/shell
Executable file
251
bin/lib/colors/generator/templates/shell
Executable file
|
@ -0,0 +1,251 @@
|
|||
[[
|
||||
#!/bin/sh
|
||||
# Base16 <%= @.scheme %> - Shell color setup script
|
||||
# <%= @author %>
|
||||
|
||||
if [ "${TERM%%-*}" = 'linux' ]; then
|
||||
# This script doesn't support linux console (use 'vconsole' template instead)
|
||||
return 2>/dev/null || exit 0
|
||||
fi
|
||||
|
||||
color00="<%= split_by_slash(@base["00"]["hex"]) %>" # Base 00 - Black
|
||||
color01="<%= split_by_slash(@base["08"]["hex"]) %>" # Base 08 - Red
|
||||
color02="<%= split_by_slash(@base["0B"]["hex"]) %>" # Base 0B - Green
|
||||
color03="<%= split_by_slash(@base["0A"]["hex"]) %>" # Base 0A - Yellow
|
||||
color04="<%= split_by_slash(@base["0D"]["hex"]) %>" # Base 0D - Blue
|
||||
color05="<%= split_by_slash(@base["0E"]["hex"]) %>" # Base 0E - Magenta
|
||||
color06="<%= split_by_slash(@base["0C"]["hex"]) %>" # Base 0C - Cyan
|
||||
color07="<%= split_by_slash(@base["05"]["hex"]) %>" # Base 05 - White
|
||||
color08="<%= split_by_slash(@base["03"]["hex"]) %>" # Base 03 - Bright Black
|
||||
color09=$color01 # Base 08 - Bright Red
|
||||
color10=$color02 # Base 0B - Bright Green
|
||||
color11=$color03 # Base 0A - Bright Yellow
|
||||
color12=$color04 # Base 0D - Bright Blue
|
||||
color13=$color05 # Base 0E - Bright Magenta
|
||||
color14=$color06 # Base 0C - Bright Cyan
|
||||
color15="<%= split_by_slash(@base["07"]["hex"]) %>" # Base 07 - Bright White
|
||||
color16="<%= split_by_slash(@base["09"]["hex"]) %>" # Base 09
|
||||
color17="<%= split_by_slash(@base["0F"]["hex"]) %>" # Base 0F
|
||||
color18="<%= split_by_slash(@base["01"]["hex"]) %>" # Base 01
|
||||
color19="<%= split_by_slash(@base["02"]["hex"]) %>" # Base 02
|
||||
color20="<%= split_by_slash(@base["04"]["hex"]) %>" # Base 04
|
||||
color21="<%= split_by_slash(@base["06"]["hex"]) %>" # Base 06
|
||||
color_foreground="<%= split_by_slash(@base["05"]["hex"]) %>" # Base 05
|
||||
color_background="<%= split_by_slash(@base["00"]["hex"]) %>" # Base 00
|
||||
color_cursor="<%= split_by_slash(@base["05"]["hex"]) %>" # Base 05
|
||||
|
||||
if [ -n "$TMUX" ]; then
|
||||
# tell tmux to pass the escape sequences through
|
||||
# (Source: http://permalink.gmane.org/gmane.comp.terminal-emulators.tmux.user/1324)
|
||||
printf_template="\033Ptmux;\033\033]4;%d;rgb:%s\007\033\\"
|
||||
printf_template_var="\033Ptmux;\033\033]%d;rgb:%s\007\033\\"
|
||||
printf_template_custom="\033Ptmux;\033\033]%s%s\007\033\\"
|
||||
elif [ "${TERM%%-*}" = "screen" ]; then
|
||||
# GNU screen (screen, screen-256color, screen-256color-bce)
|
||||
printf_template="\033P\033]4;%d;rgb:%s\007\033\\"
|
||||
printf_template_var="\033P\033]%d;rgb:%s\007\033\\"
|
||||
printf_template_custom="\033P\033]%s%s\007\033\\"
|
||||
elif [[ $- != *i* ]]; then
|
||||
# non-interactive
|
||||
alias printf=/bin/false
|
||||
else
|
||||
printf_template="\033]4;%d;rgb:%s\033\\"
|
||||
printf_template_var="\033]%d;rgb:%s\033\\"
|
||||
printf_template_custom="\033]%s%s\033\\"
|
||||
fi
|
||||
|
||||
# 16 color space
|
||||
printf $printf_template 0 $color00
|
||||
printf $printf_template 1 $color01
|
||||
printf $printf_template 2 $color02
|
||||
printf $printf_template 3 $color03
|
||||
printf $printf_template 4 $color04
|
||||
printf $printf_template 5 $color05
|
||||
printf $printf_template 6 $color06
|
||||
printf $printf_template 7 $color07
|
||||
printf $printf_template 8 $color08
|
||||
printf $printf_template 9 $color09
|
||||
printf $printf_template 10 $color10
|
||||
printf $printf_template 11 $color11
|
||||
printf $printf_template 12 $color12
|
||||
printf $printf_template 13 $color13
|
||||
printf $printf_template 14 $color14
|
||||
printf $printf_template 15 $color15
|
||||
|
||||
# 256 color space
|
||||
printf $printf_template 16 $color16
|
||||
printf $printf_template 17 $color17
|
||||
printf $printf_template 18 $color18
|
||||
printf $printf_template 19 $color19
|
||||
printf $printf_template 20 $color20
|
||||
printf $printf_template 21 $color21
|
||||
|
||||
# foreground / background / cursor color
|
||||
if [ -n "$ITERM_SESSION_ID" ]; then
|
||||
# iTerm2 proprietary escape codes
|
||||
printf $printf_template_custom Pg <%= @base["05"]["hex"] %> # forground
|
||||
printf $printf_template_custom Ph <%= @base["00"]["hex"] %> # background
|
||||
printf $printf_template_custom Pi <%= @base["05"]["hex"] %> # bold color
|
||||
printf $printf_template_custom Pj <%= @base["02"]["hex"] %> # selection color
|
||||
printf $printf_template_custom Pk <%= @base["05"]["hex"] %> # selected text color
|
||||
printf $printf_template_custom Pl <%= @base["05"]["hex"] %> # cursor
|
||||
printf $printf_template_custom Pm <%= @base["00"]["hex"] %> # cursor text
|
||||
else
|
||||
printf $printf_template_var 10 $color_foreground
|
||||
printf $printf_template_var 11 $color_background
|
||||
printf $printf_template_custom 12 ";7" # cursor (reverse video)
|
||||
fi
|
||||
|
||||
# clean up
|
||||
unset printf_template
|
||||
unset printf_template_var
|
||||
unset color00
|
||||
unset color01
|
||||
unset color02
|
||||
unset color03
|
||||
unset color04
|
||||
unset color05
|
||||
unset color06
|
||||
unset color07
|
||||
unset color08
|
||||
unset color09
|
||||
unset color10
|
||||
unset color11
|
||||
unset color12
|
||||
unset color13
|
||||
unset color14
|
||||
unset color15
|
||||
unset color16
|
||||
unset color17
|
||||
unset color18
|
||||
unset color19
|
||||
unset color20
|
||||
unset color21
|
||||
unset color_foreground
|
||||
unset color_background
|
||||
unset color_cursor
|
||||
#!/bin/sh
|
||||
# Base16 Donokai - Shell color setup script
|
||||
# Daniel Flanagan(https://lytedev.io)
|
||||
|
||||
if [ "${TERM%%-*}" = 'linux' ]; then
|
||||
# This script doesn't support linux console (use 'vconsole' template instead)
|
||||
return 2>/dev/null || exit 0
|
||||
fi
|
||||
|
||||
color00="11/11/11" # Base 00 - Black
|
||||
color01="f9/26/72" # Base 08 - Red
|
||||
color02="a6/e2/2e" # Base 0B - Green
|
||||
color03="f4/bf/75" # Base 0A - Yellow
|
||||
color04="66/d9/ef" # Base 0D - Blue
|
||||
color05="ae/81/ff" # Base 0E - Magenta
|
||||
color06="a1/ef/e4" # Base 0C - Cyan
|
||||
color07="f8/f8/f2" # Base 05 - White
|
||||
color08="75/71/5e" # Base 03 - Bright Black
|
||||
color09=$color01 # Base 08 - Bright Red
|
||||
color10=$color02 # Base 0B - Bright Green
|
||||
color11=$color03 # Base 0A - Bright Yellow
|
||||
color12=$color04 # Base 0D - Bright Blue
|
||||
color13=$color05 # Base 0E - Bright Magenta
|
||||
color14=$color06 # Base 0C - Bright Cyan
|
||||
color15="f9/f8/f5" # Base 07 - Bright White
|
||||
color16="fd/97/1f" # Base 09
|
||||
color17="cc/66/33" # Base 0F
|
||||
color18="38/38/30" # Base 01
|
||||
color19="49/48/3e" # Base 02
|
||||
color20="a5/9f/85" # Base 04
|
||||
color21="f5/f4/f1" # Base 06
|
||||
color_foreground="f8/f8/f2" # Base 05
|
||||
color_background="11/11/11" # Base 00
|
||||
color_cursor="f8/f8/f2" # Base 05
|
||||
|
||||
if [ -n "$TMUX" ]; then
|
||||
# tell tmux to pass the escape sequences through
|
||||
# (Source: http://permalink.gmane.org/gmane.comp.terminal-emulators.tmux.user/1324)
|
||||
printf_template="\033Ptmux;\033\033]4;%d;rgb:%s\007\033\\"
|
||||
printf_template_var="\033Ptmux;\033\033]%d;rgb:%s\007\033\\"
|
||||
printf_template_custom="\033Ptmux;\033\033]%s%s\007\033\\"
|
||||
elif [ "${TERM%%-*}" = "screen" ]; then
|
||||
# GNU screen (screen, screen-256color, screen-256color-bce)
|
||||
printf_template="\033P\033]4;%d;rgb:%s\007\033\\"
|
||||
printf_template_var="\033P\033]%d;rgb:%s\007\033\\"
|
||||
printf_template_custom="\033P\033]%s%s\007\033\\"
|
||||
elif [[ $- != *i* ]]; then
|
||||
# non-interactive
|
||||
alias printf=/bin/false
|
||||
else
|
||||
printf_template="\033]4;%d;rgb:%s\033\\"
|
||||
printf_template_var="\033]%d;rgb:%s\033\\"
|
||||
printf_template_custom="\033]%s%s\033\\"
|
||||
fi
|
||||
|
||||
# 16 color space
|
||||
printf $printf_template 0 $color00
|
||||
printf $printf_template 1 $color01
|
||||
printf $printf_template 2 $color02
|
||||
printf $printf_template 3 $color03
|
||||
printf $printf_template 4 $color04
|
||||
printf $printf_template 5 $color05
|
||||
printf $printf_template 6 $color06
|
||||
printf $printf_template 7 $color07
|
||||
printf $printf_template 8 $color08
|
||||
printf $printf_template 9 $color09
|
||||
printf $printf_template 10 $color10
|
||||
printf $printf_template 11 $color11
|
||||
printf $printf_template 12 $color12
|
||||
printf $printf_template 13 $color13
|
||||
printf $printf_template 14 $color14
|
||||
printf $printf_template 15 $color15
|
||||
|
||||
# 256 color space
|
||||
printf $printf_template 16 $color16
|
||||
printf $printf_template 17 $color17
|
||||
printf $printf_template 18 $color18
|
||||
printf $printf_template 19 $color19
|
||||
printf $printf_template 20 $color20
|
||||
printf $printf_template 21 $color21
|
||||
|
||||
# foreground / background / cursor color
|
||||
if [ -n "$ITERM_SESSION_ID" ]; then
|
||||
# iTerm2 proprietary escape codes
|
||||
printf $printf_template_custom Pg f8f8f2 # forground
|
||||
printf $printf_template_custom Ph 111111 # background
|
||||
printf $printf_template_custom Pi f8f8f2 # bold color
|
||||
printf $printf_template_custom Pj 49483e # selection color
|
||||
printf $printf_template_custom Pk f8f8f2 # selected text color
|
||||
printf $printf_template_custom Pl f8f8f2 # cursor
|
||||
printf $printf_template_custom Pm 111111 # cursor text
|
||||
else
|
||||
printf $printf_template_var 10 $color_foreground
|
||||
printf $printf_template_var 11 $color_background
|
||||
printf $printf_template_custom 12 ";7" # cursor (reverse video)
|
||||
fi
|
||||
|
||||
# clean up
|
||||
unset printf_template
|
||||
unset printf_template_var
|
||||
unset color00
|
||||
unset color01
|
||||
unset color02
|
||||
unset color03
|
||||
unset color04
|
||||
unset color05
|
||||
unset color06
|
||||
unset color07
|
||||
unset color08
|
||||
unset color09
|
||||
unset color10
|
||||
unset color11
|
||||
unset color12
|
||||
unset color13
|
||||
unset color14
|
||||
unset color15
|
||||
unset color16
|
||||
unset color17
|
||||
unset color18
|
||||
unset color19
|
||||
unset color20
|
||||
unset color21
|
||||
unset color_foreground
|
||||
unset color_background
|
||||
unset color_cursor
|
255
bin/lib/colors/generator/templates/shell.moon
Normal file
255
bin/lib/colors/generator/templates/shell.moon
Normal file
|
@ -0,0 +1,255 @@
|
|||
=>
|
||||
color_map: (k, v) ->
|
||||
r, g, b = v\match "(%d%d)(%d%d)(%d%d)"
|
||||
k, "#{r}/#{g}/#{b}"
|
||||
|
||||
content: [===[#!/bin/sh
|
||||
# #{@.meta.name} by #{@.meta.author} %>
|
||||
|
||||
if [ "${TERM%%-*}" = 'linux' ]; then
|
||||
# This script doesn't support linux console (use 'vconsole' template instead)
|
||||
return 2>/dev/null || exit 0
|
||||
fi
|
||||
|
||||
color00="<%= split_by_slash(@base["00"]["hex"]) %>" # Base 00 - Black
|
||||
color01="<%= split_by_slash(@base["08"]["hex"]) %>" # Base 08 - Red
|
||||
color02="<%= split_by_slash(@base["0B"]["hex"]) %>" # Base 0B - Green
|
||||
color03="<%= split_by_slash(@base["0A"]["hex"]) %>" # Base 0A - Yellow
|
||||
color04="<%= split_by_slash(@base["0D"]["hex"]) %>" # Base 0D - Blue
|
||||
color05="<%= split_by_slash(@base["0E"]["hex"]) %>" # Base 0E - Magenta
|
||||
color06="<%= split_by_slash(@base["0C"]["hex"]) %>" # Base 0C - Cyan
|
||||
color07="<%= split_by_slash(@base["05"]["hex"]) %>" # Base 05 - White
|
||||
color08="<%= split_by_slash(@base["03"]["hex"]) %>" # Base 03 - Bright Black
|
||||
color09=$color01 # Base 08 - Bright Red
|
||||
color10=$color02 # Base 0B - Bright Green
|
||||
color11=$color03 # Base 0A - Bright Yellow
|
||||
color12=$color04 # Base 0D - Bright Blue
|
||||
color13=$color05 # Base 0E - Bright Magenta
|
||||
color14=$color06 # Base 0C - Bright Cyan
|
||||
color15="<%= split_by_slash(@base["07"]["hex"]) %>" # Base 07 - Bright White
|
||||
color16="<%= split_by_slash(@base["09"]["hex"]) %>" # Base 09
|
||||
color17="<%= split_by_slash(@base["0F"]["hex"]) %>" # Base 0F
|
||||
color18="<%= split_by_slash(@base["01"]["hex"]) %>" # Base 01
|
||||
color19="<%= split_by_slash(@base["02"]["hex"]) %>" # Base 02
|
||||
color20="<%= split_by_slash(@base["04"]["hex"]) %>" # Base 04
|
||||
color21="<%= split_by_slash(@base["06"]["hex"]) %>" # Base 06
|
||||
color_foreground="<%= split_by_slash(@base["05"]["hex"]) %>" # Base 05
|
||||
color_background="<%= split_by_slash(@base["00"]["hex"]) %>" # Base 00
|
||||
color_cursor="<%= split_by_slash(@base["05"]["hex"]) %>" # Base 05
|
||||
|
||||
if [ -n "$TMUX" ]; then
|
||||
# tell tmux to pass the escape sequences through
|
||||
# (Source: http://permalink.gmane.org/gmane.comp.terminal-emulators.tmux.user/1324)
|
||||
printf_template="\033Ptmux;\033\033]4;%d;rgb:%s\007\033\\"
|
||||
printf_template_var="\033Ptmux;\033\033]%d;rgb:%s\007\033\\"
|
||||
printf_template_custom="\033Ptmux;\033\033]%s%s\007\033\\"
|
||||
elif [ "${TERM%%-*}" = "screen" ]; then
|
||||
# GNU screen (screen, screen-256color, screen-256color-bce)
|
||||
printf_template="\033P\033]4;%d;rgb:%s\007\033\\"
|
||||
printf_template_var="\033P\033]%d;rgb:%s\007\033\\"
|
||||
printf_template_custom="\033P\033]%s%s\007\033\\"
|
||||
elif [[ $- != *i* ]]; then
|
||||
# non-interactive
|
||||
alias printf=/bin/false
|
||||
else
|
||||
printf_template="\033]4;%d;rgb:%s\033\\"
|
||||
printf_template_var="\033]%d;rgb:%s\033\\"
|
||||
printf_template_custom="\033]%s%s\033\\"
|
||||
fi
|
||||
|
||||
# 16 color space
|
||||
printf $printf_template 0 $color00
|
||||
printf $printf_template 1 $color01
|
||||
printf $printf_template 2 $color02
|
||||
printf $printf_template 3 $color03
|
||||
printf $printf_template 4 $color04
|
||||
printf $printf_template 5 $color05
|
||||
printf $printf_template 6 $color06
|
||||
printf $printf_template 7 $color07
|
||||
printf $printf_template 8 $color08
|
||||
printf $printf_template 9 $color09
|
||||
printf $printf_template 10 $color10
|
||||
printf $printf_template 11 $color11
|
||||
printf $printf_template 12 $color12
|
||||
printf $printf_template 13 $color13
|
||||
printf $printf_template 14 $color14
|
||||
printf $printf_template 15 $color15
|
||||
|
||||
# 256 color space
|
||||
printf $printf_template 16 $color16
|
||||
printf $printf_template 17 $color17
|
||||
printf $printf_template 18 $color18
|
||||
printf $printf_template 19 $color19
|
||||
printf $printf_template 20 $color20
|
||||
printf $printf_template 21 $color21
|
||||
|
||||
# foreground / background / cursor color
|
||||
if [ -n "$ITERM_SESSION_ID" ]; then
|
||||
# iTerm2 proprietary escape codes
|
||||
printf $printf_template_custom Pg <%= @base["05"]["hex"] %> # forground
|
||||
printf $printf_template_custom Ph <%= @base["00"]["hex"] %> # background
|
||||
printf $printf_template_custom Pi <%= @base["05"]["hex"] %> # bold color
|
||||
printf $printf_template_custom Pj <%= @base["02"]["hex"] %> # selection color
|
||||
printf $printf_template_custom Pk <%= @base["05"]["hex"] %> # selected text color
|
||||
printf $printf_template_custom Pl <%= @base["05"]["hex"] %> # cursor
|
||||
printf $printf_template_custom Pm <%= @base["00"]["hex"] %> # cursor text
|
||||
else
|
||||
printf $printf_template_var 10 $color_foreground
|
||||
printf $printf_template_var 11 $color_background
|
||||
printf $printf_template_custom 12 ";7" # cursor (reverse video)
|
||||
fi
|
||||
|
||||
# clean up
|
||||
unset printf_template
|
||||
unset printf_template_var
|
||||
unset color00
|
||||
unset color01
|
||||
unset color02
|
||||
unset color03
|
||||
unset color04
|
||||
unset color05
|
||||
unset color06
|
||||
unset color07
|
||||
unset color08
|
||||
unset color09
|
||||
unset color10
|
||||
unset color11
|
||||
unset color12
|
||||
unset color13
|
||||
unset color14
|
||||
unset color15
|
||||
unset color16
|
||||
unset color17
|
||||
unset color18
|
||||
unset color19
|
||||
unset color20
|
||||
unset color21
|
||||
unset color_foreground
|
||||
unset color_background
|
||||
unset color_cursor
|
||||
#!/bin/sh
|
||||
# Base16 Donokai - Shell color setup script
|
||||
# Daniel Flanagan(https://lytedev.io)
|
||||
|
||||
if [ "${TERM%%-*}" = 'linux' ]; then
|
||||
# This script doesn't support linux console (use 'vconsole' template instead)
|
||||
return 2>/dev/null || exit 0
|
||||
fi
|
||||
|
||||
color00="11/11/11" # Base 00 - Black
|
||||
color01="f9/26/72" # Base 08 - Red
|
||||
color02="a6/e2/2e" # Base 0B - Green
|
||||
color03="f4/bf/75" # Base 0A - Yellow
|
||||
color04="66/d9/ef" # Base 0D - Blue
|
||||
color05="ae/81/ff" # Base 0E - Magenta
|
||||
color06="a1/ef/e4" # Base 0C - Cyan
|
||||
color07="f8/f8/f2" # Base 05 - White
|
||||
color08="75/71/5e" # Base 03 - Bright Black
|
||||
color09=$color01 # Base 08 - Bright Red
|
||||
color10=$color02 # Base 0B - Bright Green
|
||||
color11=$color03 # Base 0A - Bright Yellow
|
||||
color12=$color04 # Base 0D - Bright Blue
|
||||
color13=$color05 # Base 0E - Bright Magenta
|
||||
color14=$color06 # Base 0C - Bright Cyan
|
||||
color15="f9/f8/f5" # Base 07 - Bright White
|
||||
color16="fd/97/1f" # Base 09
|
||||
color17="cc/66/33" # Base 0F
|
||||
color18="38/38/30" # Base 01
|
||||
color19="49/48/3e" # Base 02
|
||||
color20="a5/9f/85" # Base 04
|
||||
color21="f5/f4/f1" # Base 06
|
||||
color_foreground="f8/f8/f2" # Base 05
|
||||
color_background="11/11/11" # Base 00
|
||||
color_cursor="f8/f8/f2" # Base 05
|
||||
|
||||
if [ -n "$TMUX" ]; then
|
||||
# tell tmux to pass the escape sequences through
|
||||
# (Source: http://permalink.gmane.org/gmane.comp.terminal-emulators.tmux.user/1324)
|
||||
printf_template="\033Ptmux;\033\033]4;%d;rgb:%s\007\033\\"
|
||||
printf_template_var="\033Ptmux;\033\033]%d;rgb:%s\007\033\\"
|
||||
printf_template_custom="\033Ptmux;\033\033]%s%s\007\033\\"
|
||||
elif [ "${TERM%%-*}" = "screen" ]; then
|
||||
# GNU screen (screen, screen-256color, screen-256color-bce)
|
||||
printf_template="\033P\033]4;%d;rgb:%s\007\033\\"
|
||||
printf_template_var="\033P\033]%d;rgb:%s\007\033\\"
|
||||
printf_template_custom="\033P\033]%s%s\007\033\\"
|
||||
elif [[ $- != *i* ]]; then
|
||||
# non-interactive
|
||||
alias printf=/bin/false
|
||||
else
|
||||
printf_template="\033]4;%d;rgb:%s\033\\"
|
||||
printf_template_var="\033]%d;rgb:%s\033\\"
|
||||
printf_template_custom="\033]%s%s\033\\"
|
||||
fi
|
||||
|
||||
# 16 color space
|
||||
printf $printf_template 0 $color00
|
||||
printf $printf_template 1 $color01
|
||||
printf $printf_template 2 $color02
|
||||
printf $printf_template 3 $color03
|
||||
printf $printf_template 4 $color04
|
||||
printf $printf_template 5 $color05
|
||||
printf $printf_template 6 $color06
|
||||
printf $printf_template 7 $color07
|
||||
printf $printf_template 8 $color08
|
||||
printf $printf_template 9 $color09
|
||||
printf $printf_template 10 $color10
|
||||
printf $printf_template 11 $color11
|
||||
printf $printf_template 12 $color12
|
||||
printf $printf_template 13 $color13
|
||||
printf $printf_template 14 $color14
|
||||
printf $printf_template 15 $color15
|
||||
|
||||
# 256 color space
|
||||
printf $printf_template 16 $color16
|
||||
printf $printf_template 17 $color17
|
||||
printf $printf_template 18 $color18
|
||||
printf $printf_template 19 $color19
|
||||
printf $printf_template 20 $color20
|
||||
printf $printf_template 21 $color21
|
||||
|
||||
# foreground / background / cursor color
|
||||
if [ -n "$ITERM_SESSION_ID" ]; then
|
||||
# iTerm2 proprietary escape codes
|
||||
printf $printf_template_custom Pg f8f8f2 # forground
|
||||
printf $printf_template_custom Ph 111111 # background
|
||||
printf $printf_template_custom Pi f8f8f2 # bold color
|
||||
printf $printf_template_custom Pj 49483e # selection color
|
||||
printf $printf_template_custom Pk f8f8f2 # selected text color
|
||||
printf $printf_template_custom Pl f8f8f2 # cursor
|
||||
printf $printf_template_custom Pm 111111 # cursor text
|
||||
else
|
||||
printf $printf_template_var 10 $color_foreground
|
||||
printf $printf_template_var 11 $color_background
|
||||
printf $printf_template_custom 12 ";7" # cursor (reverse video)
|
||||
fi
|
||||
|
||||
# clean up
|
||||
unset printf_template
|
||||
unset printf_template_var
|
||||
unset color00
|
||||
unset color01
|
||||
unset color02
|
||||
unset color03
|
||||
unset color04
|
||||
unset color05
|
||||
unset color06
|
||||
unset color07
|
||||
unset color08
|
||||
unset color09
|
||||
unset color10
|
||||
unset color11
|
||||
unset color12
|
||||
unset color13
|
||||
unset color14
|
||||
unset color15
|
||||
unset color16
|
||||
unset color17
|
||||
unset color18
|
||||
unset color19
|
||||
unset color20
|
||||
unset color21
|
||||
unset color_foreground
|
||||
unset color_background
|
||||
unset color_cursor
|
||||
]===]
|
|
@ -7,7 +7,7 @@ THEME="$1"
|
|||
echo "$THEME"
|
||||
|
||||
"$DIR/generator/gen.bash" "$THEME"
|
||||
"$DOTFILES_PATH/de/x/loadresources"
|
||||
"$DOTFILES_PATH/apps/de/x/loadresources"
|
||||
resrc
|
||||
restartbar
|
||||
# TODO: set GTK theme to "Arc-Dark" or "Arc-Light"
|
|
@ -1,7 +1,7 @@
|
|||
#!/usr/bin/env bash
|
||||
|
||||
dfp=$(cd "$(dirname "${BASH_SOURCE[0]}" )/.." && pwd)
|
||||
source "${dfp}/shell/bash/bashrc"
|
||||
dfp=$(cd "$(dirname "${BASH_SOURCE[0]}" )/../../" && pwd)
|
||||
source "${dfp}/apps/shell/bash/bashrc"
|
||||
|
||||
USER_DISAGREE_CODE=120
|
||||
NO_AGREEMENT_CODE=121
|
||||
|
@ -73,6 +73,6 @@ _dotfiles_setup_run_setup() {
|
|||
echo "Quitting due to lack of user agreement."
|
||||
return "${NO_AGREEMENT_CODE}"
|
||||
fi
|
||||
|
||||
|
||||
}
|
||||
export -f _dotfiles_setup_run_setup
|
|
@ -8,16 +8,16 @@ if [[ $UID -ne 0 ]]; then
|
|||
exit
|
||||
fi
|
||||
|
||||
dfp=$(cd "$(dirname "${BASH_SOURCE[0]}" )/" && pwd)
|
||||
dfp=$(cd "$(dirname "${BASH_SOURCE[0]}" )/../" && pwd)
|
||||
source "${dfp}/scripts/setup_helpers.bash"
|
||||
|
||||
links=(
|
||||
# display manager files
|
||||
"$dfp/de/sway/sway-init" "/usr/bin/sway-lytedev"
|
||||
"$dfp/de/sway/dm_entry" "/usr/share/wayland-sessions/sway-lytedev.desktop"
|
||||
"$dfp/apps/de/sway/sway-init" "/usr/bin/sway-lytedev"
|
||||
"$dfp/apps/de/sway/dm_entry" "/usr/share/wayland-sessions/sway-lytedev.desktop"
|
||||
|
||||
# touchpad
|
||||
"$dfp/de/libinput/touchpad.conf" "/etc/X11/xorg.conf.d/41-libinput-lytedev-touchpad-options.conf"
|
||||
"$dfp/apps/de/libinput/touchpad.conf" "/etc/X11/xorg.conf.d/41-libinput-lytedev-touchpad-options.conf"
|
||||
)
|
||||
|
||||
_dotfiles_setup_run_setup "$dfp/.agreed-to-erasing-root-files.lock" "${links[@]}"
|
|
@ -1,3 +1,3 @@
|
|||
#!/usr/bin/env bash
|
||||
|
||||
"${DOTFILES_PATH}/de/bar/bar.bash"
|
||||
"${DOTFILES_PATH}/apps/de/bar/bar.bash"
|
||||
|
|
|
@ -1,9 +1,9 @@
|
|||
#!/usr/bin/env bash
|
||||
|
||||
resrc
|
||||
"${DOTFILES_PATH}/de/x/loadresources"
|
||||
"${DOTFILES_PATH}/apps/de/x/loadresources"
|
||||
autorandr --change
|
||||
"${DOTFILES_PATH}/de/bspwm/bspwmrc"
|
||||
"${DOTFILES_PATH}/de/x/loadresources"
|
||||
"${DOTFILES_PATH}/apps/de/bspwm/bspwmrc"
|
||||
"${DOTFILES_PATH}/apps/de/x/loadresources"
|
||||
restartbar
|
||||
"${HOME}/.fehbg"
|
||||
|
|
|
@ -2,9 +2,9 @@
|
|||
|
||||
resrc
|
||||
source "$HOME/.workdock.env"
|
||||
"${DOTFILES_PATH}/de/x/loadresources" lodpi
|
||||
"${DOTFILES_PATH}/apps/de/x/loadresources" lodpi
|
||||
autorandr --change
|
||||
"${DOTFILES_PATH}/de/bspwm/bspwmrc"
|
||||
"${DOTFILES_PATH}/de/x/loadresources" lodpi
|
||||
"${DOTFILES_PATH}/apps/de/bspwm/bspwmrc"
|
||||
"${DOTFILES_PATH}/apps/de/x/loadresources" lodpi
|
||||
restartbar
|
||||
"${HOME}/.fehbg"
|
||||
|
|
54
setup
54
setup
|
@ -3,7 +3,7 @@
|
|||
# TODO: ascii art header since I'm a leet haxx0r
|
||||
|
||||
dfp=$(cd "$(dirname "${BASH_SOURCE[0]}" )/" && pwd)
|
||||
source "${dfp}/scripts/setup_helpers.bash"
|
||||
source "${dfp}/bin/lib/setup_helpers.bash"
|
||||
edfp="${dfp}/.env"
|
||||
|
||||
INTERACTIVE=1
|
||||
|
@ -19,35 +19,35 @@ done
|
|||
|
||||
links=(
|
||||
# desktop environment files
|
||||
"$dfp/de/bspwm/bspwmrc" "$XDG_CONFIG_HOME/bspwm/bspwmrc"
|
||||
"$dfp/de/bspwm/fehbg" "$HOME/.fehbg"
|
||||
"$dfp/de/sway/config" "$XDG_CONFIG_HOME/sway/config"
|
||||
"$dfp/de/sxhkd/sxhkdrc" "$XDG_CONFIG_HOME/sxhkd/sxhkdrc"
|
||||
"$dfp/de/x/resources" "$HOME/.Xresources"
|
||||
"$dfp/de/x/initrc" "$HOME/.xinitrc"
|
||||
"$dfp/de/x/initrc" "$HOME/.vnc/xstartup"
|
||||
"$dfp/de/x/profile" "$HOME/.xprofile"
|
||||
"$dfp/de/x/modmap" "$HOME/.xmodmap"
|
||||
"$dfp/de/compton/compton.conf" "$XDG_CONFIG_HOME/compton.conf"
|
||||
"$dfp/de/dunst/dunstrc" "$XDG_CONFIG_HOME/dunst/dunstrc"
|
||||
"$dfp/scripts/colors/xresources" "$HOME/.Xresources.colors"
|
||||
"$dfp/apps/de/bspwm/bspwmrc" "$XDG_CONFIG_HOME/bspwm/bspwmrc"
|
||||
"$dfp/apps/de/bspwm/fehbg" "$HOME/.fehbg"
|
||||
"$dfp/apps/de/sway/config" "$XDG_CONFIG_HOME/sway/config"
|
||||
"$dfp/apps/de/sxhkd/sxhkdrc" "$XDG_CONFIG_HOME/sxhkd/sxhkdrc"
|
||||
"$dfp/apps/de/x/resources" "$HOME/.Xresources"
|
||||
"$dfp/apps/de/x/initrc" "$HOME/.xinitrc"
|
||||
"$dfp/apps/de/x/initrc" "$HOME/.vnc/xstartup"
|
||||
"$dfp/apps/de/x/profile" "$HOME/.xprofile"
|
||||
"$dfp/apps/de/x/modmap" "$HOME/.xmodmap"
|
||||
"$dfp/apps/de/compton/compton.conf" "$XDG_CONFIG_HOME/compton.conf"
|
||||
"$dfp/apps/de/dunst/dunstrc" "$XDG_CONFIG_HOME/dunst/dunstrc"
|
||||
"$dfp/bin/lib/colors/xresources" "$HOME/.Xresources.colors"
|
||||
|
||||
# shell files
|
||||
"$dfp/shell/bash/bashrc" "$HOME/.bashrc"
|
||||
"$dfp/shell/bash/bash_profile" "$HOME/.bash_profile"
|
||||
"$dfp/shell/tmux/tmux.conf" "$HOME/.tmux.conf"
|
||||
"$dfp/shell/tmux/layouts" "$HOME/.tmux/layouts"
|
||||
"$dfp/apps/shell/bash/bashrc" "$HOME/.bashrc"
|
||||
"$dfp/apps/shell/bash/bash_profile" "$HOME/.bash_profile"
|
||||
"$dfp/apps/shell/tmux/tmux.conf" "$HOME/.tmux.conf"
|
||||
"$dfp/apps/shell/tmux/layouts" "$HOME/.tmux/layouts"
|
||||
|
||||
# text editor files
|
||||
"$dfp/apps/neovim/" "$XDG_CONFIG_HOME/nvim"
|
||||
"$dfp/apps/neovim/" "$HOME/.vim"
|
||||
"$dfp/apps/neovim/init.vim" "$HOME/.vimrc"
|
||||
"$dfp/scripts/colors/vim" "$XDG_CONFIG_HOME/nvim/colors/base16-donokai.vim"
|
||||
"$dfp/bin/lib/colors/vim" "$XDG_CONFIG_HOME/nvim/colors/base16-donokai.vim"
|
||||
|
||||
# gtk configuration files
|
||||
"$dfp/de/gtk/2rc" "$HOME/.gtkrc-2.0"
|
||||
"$dfp/de/gtk/2rc" "$HOME/.gtkrc"
|
||||
"$dfp/de/gtk/3settings.ini" "$XDG_CONFIG_HOME/gtk-3.0/settings.ini"
|
||||
"$dfp/apps/de/gtk/2rc" "$HOME/.gtkrc-2.0"
|
||||
"$dfp/apps/de/gtk/2rc" "$HOME/.gtkrc"
|
||||
"$dfp/apps/de/gtk/3settings.ini" "$XDG_CONFIG_HOME/gtk-3.0/settings.ini"
|
||||
|
||||
# irc files
|
||||
"$dfp/apps/irssi/" "$HOME/.irssi"
|
||||
|
@ -62,7 +62,7 @@ links=(
|
|||
"$dfp/apps/scim/lua" "$HOME/.scim/lua"
|
||||
|
||||
# libinput configuration
|
||||
"$dfp/de/libinput/gestures.conf" "$XDG_CONFIG_HOME/libinput-gestures.conf"
|
||||
"$dfp/apps/de/libinput/gestures.conf" "$XDG_CONFIG_HOME/libinput-gestures.conf"
|
||||
|
||||
# document viewer
|
||||
"$dfp/apps/zathura/" "$XDG_CONFIG_HOME/zathura"
|
||||
|
@ -80,7 +80,7 @@ links=(
|
|||
"$dfp/apps/rofi/config" "$XDG_CONFIG_HOME/rofi/config"
|
||||
|
||||
# bar files
|
||||
"$dfp/de/bar/polybar-config" "$XDG_CONFIG_HOME/polybar/config"
|
||||
"$dfp/apps/de/bar/polybar-config" "$XDG_CONFIG_HOME/polybar/config"
|
||||
|
||||
# ranger config
|
||||
"$dfp/apps/ranger/" "$XDG_CONFIG_HOME/ranger"
|
||||
|
@ -96,10 +96,10 @@ links=(
|
|||
"$dfp/apps/git/config" "$HOME/.gitconfig"
|
||||
|
||||
# fontconfig
|
||||
"$dfp/de/fontconfig/" "$XDG_CONFIG_HOME/fontconfig"
|
||||
"$dfp/apps/de/fontconfig/" "$XDG_CONFIG_HOME/fontconfig"
|
||||
|
||||
# XDG user directories
|
||||
"$dfp/shell/user-dirs" "$XDG_CONFIG_HOME/user-dirs.dirs"
|
||||
"$dfp/apps/shell/user-dirs" "$XDG_CONFIG_HOME/user-dirs.dirs"
|
||||
)
|
||||
|
||||
mkdir -p "$edfp/"
|
||||
|
@ -131,12 +131,12 @@ chmod 700 -R "$HOME/.bin"
|
|||
_dotfiles_setup_run_setup "$dfp/.agreed-to-erasing-files.lock" "${links[@]}"
|
||||
|
||||
if [[ "$INTERACTIVE" = 1 ]]; then
|
||||
echo -n -e "Do you want to run the sudo_setup script for changes to /etc"
|
||||
echo -n -e "Do you want to run the bin/lib/sudo_setup script for changes to /etc"
|
||||
echo -n -e "\nand other root directories?"
|
||||
read -r -p " [y/N] " response
|
||||
response=${response,,} # to lower case
|
||||
if [[ $response =~ ^(yes|y)$ ]]; then
|
||||
"$dfp/sudo_setup"
|
||||
"$dfp/bin/lib/sudo_setup"
|
||||
fi
|
||||
|
||||
echo -e "Dotfiles Installed! Running 'exec bash'...\n"
|
||||
|
|
Reference in a new issue