From 86ec9d7ce23a965fd8a37aa9cbbbab58798f386d Mon Sep 17 00:00:00 2001 From: buffet Date: Sat, 2 Sep 2023 21:47:37 +0200 Subject: [PATCH] port configs --- dots/.bash_profile | 2 + dots/.bashrc | 11 ++ dots/.config/foot/foot.ini | 51 +++++++ dots/.config/git/config | 23 +++ dots/.config/mako/config | 10 ++ dots/.config/sway/config | 137 ++++++++++++++++++ dots/.config/sway/status_command | 24 +++ dots/.config/swaylock/config | 16 ++ dots/.inputrc | 1 + .../chrome/userChrome.css | 3 + dots/.profile | 6 + 11 files changed, 284 insertions(+) create mode 100644 dots/.bash_profile create mode 100644 dots/.bashrc create mode 100644 dots/.config/foot/foot.ini create mode 100644 dots/.config/git/config create mode 100644 dots/.config/mako/config create mode 100644 dots/.config/sway/config create mode 100755 dots/.config/sway/status_command create mode 100644 dots/.config/swaylock/config create mode 100644 dots/.inputrc create mode 100644 dots/.mozilla/firefox/yflq9gsr.default-release/chrome/userChrome.css create mode 100644 dots/.profile diff --git a/dots/.bash_profile b/dots/.bash_profile new file mode 100644 index 0000000..2714462 --- /dev/null +++ b/dots/.bash_profile @@ -0,0 +1,2 @@ +[[ -f ~/.bashrc ]] && . ~/.bashrc +[[ -f ~/.profile ]] && . ~/.profile diff --git a/dots/.bashrc b/dots/.bashrc new file mode 100644 index 0000000..c2c615b --- /dev/null +++ b/dots/.bashrc @@ -0,0 +1,11 @@ +shopt -s cdspell checkjobs extglob globstar histappend nocaseglob +HISTCONTROL=erasedups:ignorespace + +alias mkdir='mkdir -p' +alias rg='rg -S' + +PS0='\[\e[0m\]' +PS1='\[\e[1m\] ' + +bind '"\C-o": "\C-a\C-k fg; if [[ $? == 1 ]]; then nvim; fi\n"' +bind '"\e\C-m": "\C-e | nvim\C-m"' diff --git a/dots/.config/foot/foot.ini b/dots/.config/foot/foot.ini new file mode 100644 index 0000000..f55b89b --- /dev/null +++ b/dots/.config/foot/foot.ini @@ -0,0 +1,51 @@ +# -*- conf -*- + +font=APL386 Unicode:size=8 +pad=8x8 # optionally append 'center' + +[scrollback] +lines=10000 + +[url] +launch=xdg-open ${url} + +[cursor] +color=dcd7ba 6f6f78 + +[colors] +background=1f1f28 +foreground=dcd7ba + +## Normal/regular colors (color palette 0-7) +regular0=090618 # black +regular1=c34043 # red +regular2=76946a # green +regular3=c0a36e # yellow +regular4=7e9cd8 # blue +regular5=957fb8 # magenta +regular6=6a9589 # cyan +regular7=c8c093 # white + +## Bright colors (color palette 8-15) +bright0=727169 # bright black +bright1=e82424 # bright red +bright2=98bb6c # bright green +bright3=e6c384 # bright yellow +bright4=7fb4ca # bright blue +bright5=938aa9 # bright magenta +bright6=7aa89f # bright cyan +bright7=dcd7ba # bright white + +## Misc colors +# selection-foreground= +# selection-background= +# jump-labels= # black-on-yellow +# scrollback-indicator= # black-on-bright-blue +# search-box-no-match= # black-on-red +# search-box-match= # black-on-yellow +# urls= + +[key-bindings] +show-urls-launch=Control+Shift+l + +# vim: ft=dosini diff --git a/dots/.config/git/config b/dots/.config/git/config new file mode 100644 index 0000000..7e55b14 --- /dev/null +++ b/dots/.config/git/config @@ -0,0 +1,23 @@ +[user] + email = dev@buffet.sh + name = buffet + +[alias] + b = branch + c = commit --verbose + m = commit --ammend --verbose + + d = diff + ds = diff --stat + dc = diff --cached + l = log + s = status -s + +[init] + defaultBranch = master + +[push] + autoSetupRemote = true + +[pull] + ff = only diff --git a/dots/.config/mako/config b/dots/.config/mako/config new file mode 100644 index 0000000..6392c38 --- /dev/null +++ b/dots/.config/mako/config @@ -0,0 +1,10 @@ +anchor=top-right +background-color=#1f1f28 +border-color=#54546d +progress-color=#dcd7ba +text-color=#dcd7ba +border-size=1 + +default-timeout=4000 + +#font=APL386 Unicode diff --git a/dots/.config/sway/config b/dots/.config/sway/config new file mode 100644 index 0000000..5475d71 --- /dev/null +++ b/dots/.config/sway/config @@ -0,0 +1,137 @@ +### Variables +set $mod Mod4 +set $left h +set $down j +set $up k +set $right l + +set $term foot +set $browser firefox-wayland +set $lock swaylock + +output * bg #1f1f28 solid_color + +input * { + xkb_layout us + xkb_options "compose:prsc" +} + +seat * hide_cursor when-typing enable + +### Autostart +exec wl-paste -t text --watch clipman store --no-persist +exec mako +exec fcitx5 + +### Key bindings + floating_modifier $mod normal + + bindsym $mod+Return exec $term + bindsym $mod+i exec $browser + bindsym $mod+Shift+y exec $lock + + bindsym $mod+z exec light -U 0.5 + bindsym $mod+x exec light -A 0.5 + bindsym $mod+Shift+z exec light -U 5 + bindsym $mod+Shift+x exec light -A 5 + + bindsym $mod+Shift+q kill + bindsym $mod+Shift+c reload + bindsym $mod+Shift+e exit + + # Move your focus around + bindsym $mod+$left focus left + bindsym $mod+$down focus down + bindsym $mod+$up focus up + bindsym $mod+$right focus right + + bindsym $mod+Left focus left + bindsym $mod+Down focus down + bindsym $mod+Up focus up + bindsym $mod+Right focus right + + bindsym $mod+Shift+$left move left + bindsym $mod+Shift+$down move down + bindsym $mod+Shift+$up move up + bindsym $mod+Shift+$right move right + + bindsym $mod+Shift+Left move left + bindsym $mod+Shift+Down move down + bindsym $mod+Shift+Up move up + bindsym $mod+Shift+Right move right + + bindsym $mod+1 workspace number 1 + bindsym $mod+2 workspace number 2 + bindsym $mod+3 workspace number 3 + bindsym $mod+4 workspace number 4 + bindsym $mod+5 workspace number 5 + bindsym $mod+6 workspace number 6 + bindsym $mod+7 workspace number 7 + bindsym $mod+8 workspace number 8 + bindsym $mod+9 workspace number 9 + bindsym $mod+0 workspace number 10 + + bindsym $mod+Shift+1 move container to workspace number 1 + bindsym $mod+Shift+2 move container to workspace number 2 + bindsym $mod+Shift+3 move container to workspace number 3 + bindsym $mod+Shift+4 move container to workspace number 4 + bindsym $mod+Shift+5 move container to workspace number 5 + bindsym $mod+Shift+6 move container to workspace number 6 + bindsym $mod+Shift+7 move container to workspace number 7 + bindsym $mod+Shift+8 move container to workspace number 8 + bindsym $mod+Shift+9 move container to workspace number 9 + bindsym $mod+Shift+0 move container to workspace number 10 + + bindsym $mod+o splith + bindsym $mod+u splitv + + bindsym $mod+s layout stacking + bindsym $mod+t layout tabbed + bindsym $mod+e layout toggle split + + bindsym $mod+f fullscreen + + bindsym $mod+Shift+space floating toggle + bindsym $mod+space focus mode_toggle + bindsym $mod+a focus parent + + bindsym $mod+Shift+minus move scratchpad + bindsym $mod+minus scratchpad show + + bindsym $mod+Ctrl+$left grow left 10 px or 10 ppt + bindsym $mod+Ctrl+$down grow down 10 px or 10 ppt + bindsym $mod+Ctrl+$up grow up 10 px or 10 ppt + bindsym $mod+Ctrl+$right grow right 10 px or 10 ppt + + bindsym $mod+Ctrl+Left grow left 10 px or 10 ppt + bindsym $mod+Ctrl+Down grow down 10 px or 10 ppt + bindsym $mod+Ctrl+Up grow up 10 px or 10 ppt + bindsym $mod+Ctrl+Right grow right 10 px or 10 ppt + +gaps inner 8 +gaps outer 0 +default_border pixel 1 +font "APL386 Unicode 8" + +client.focused #54546d #1f1f28 #dcd7ba #54546d #54546d +client.unfocused #363646 #1f1f28 #c8c093 #363646 #363646 +client.focused_inactive #363646 #1f1f28 #c8c093 #363646 #363646 + +# Status Bar: +bar { + position bottom + gaps 8 + font "APL386 Unicode 8" + + status_command ~/.config/sway/status_command + + colors { + background #1f1f28 + statusline #dcd7ba + focused_workspace #54546d #1f1f28 #c8c893 + active_workspace #1f1f28 #1f1f28 #c8c893 + inactive_workspace #1f1f28 #1f1f28 #c8c893 + } +} + +include /etc/sway/config.d/* diff --git a/dots/.config/sway/status_command b/dots/.config/sway/status_command new file mode 100755 index 0000000..2a7048c --- /dev/null +++ b/dots/.config/sway/status_command @@ -0,0 +1,24 @@ +#!/bin/sh + +while :; do + energy_full=0 + energy_now=0 + charging= + + for bat in /sys/class/power_supply/*/capacity; do + bat="${bat%/*}" + read -r full <"$bat/energy_full" + read -r now <"$bat/energy_now" + energy_full=$((energy_full + full)) + energy_now=$((energy_now + now)) + done + + if cat /sys/class/power_supply/*/status | grep -q Charging; then + charging=+ + fi + + percentage=$((energy_now * 100 / energy_full)) + + printf '%s %s ' "$charging$percentage%" "$(date +'%H:%M:%S')" + sleep 1 +done diff --git a/dots/.config/swaylock/config b/dots/.config/swaylock/config new file mode 100644 index 0000000..6ac1d0a --- /dev/null +++ b/dots/.config/swaylock/config @@ -0,0 +1,16 @@ +ignore-empty-password +color=#1f1f28 +bs-hl-color=#c34043 +caps-lock-bs-hl-color=#c34043 +caps-lock-key-hl-color=#98bb6c +inside-color=#1f1f28 +inside-clear-color=#c0a36e +inside-caps-lock-color=#1f1f28 +inside-ver-color=#7e9cd8 +inside-wrong-color=#c34043 +key-hl-color=#98bb6c +ring-color=#7e9cd8 +ring-clear-color=#c0a36e +ring-caps-lock-color=#c0a36e +ring-ver-color=#7fb4ca +ring-wrong-color=#e82424 diff --git a/dots/.inputrc b/dots/.inputrc new file mode 100644 index 0000000..236bfdd --- /dev/null +++ b/dots/.inputrc @@ -0,0 +1 @@ +set completion-ignore-case on diff --git a/dots/.mozilla/firefox/yflq9gsr.default-release/chrome/userChrome.css b/dots/.mozilla/firefox/yflq9gsr.default-release/chrome/userChrome.css new file mode 100644 index 0000000..ad40ae1 --- /dev/null +++ b/dots/.mozilla/firefox/yflq9gsr.default-release/chrome/userChrome.css @@ -0,0 +1,3 @@ +#TabsToolbar { + visibility: collapse !important; +} diff --git a/dots/.profile b/dots/.profile new file mode 100644 index 0000000..84d218f --- /dev/null +++ b/dots/.profile @@ -0,0 +1,6 @@ +[ "$PROFILE_LOADED_" ] && return +export PROFILE_LOADED_=1 + +export GTK_IM_MODULE=fcitx +export QT_IM_MODULE=fcitx +export XMODIFIERS=@im=fcitx