1
0
forked from extern/nix-config

meta: Remove more old dotfiles

- alacritty: Prefer kitty.
- dual-function-keys: Managed with Nix.
- editorconfig: Managed with home-manager.
- librewolf: Managed with home-manager.
- river: Prefer hyprland.
- swayidle: Can use home-manager.
- swaylock: Managed with home-manager.
- yambar: Prefer waybar for simplicity.
This commit is contained in:
Donovan Glover 2023-05-08 21:27:23 -04:00
parent a8f7f8702e
commit 2cc88a5f4c
No known key found for this signature in database
GPG Key ID: EA7408A77AE1BE65
22 changed files with 0 additions and 660 deletions

View File

@ -1 +0,0 @@
editorconfig/.editorconfig

View File

@ -1,35 +0,0 @@
import:
- ~/.cache/wal/colors-alacritty.yml
window:
opacity: 0.9
padding:
x: 10
y: 10
decorations: none
startup_mode: Maximized
decorations_theme_variant: Dark
font:
normal:
family: Hack
size: 11
draw_bold_text_with_bright_colors: true
selection:
save_to_clipboard: true
cursor:
style:
shape: Beam
blinking: Always
shell:
program: /usr/bin/fish
mouse:
hide_when_typing: true
hints:
launcher:
program: /usr/bin/librewolf

View File

@ -1,53 +0,0 @@
colors:
primary:
background: "{background}"
foreground: "{foreground}"
cursor:
text: CellBackground
cursor: CellForeground
vi_mode_cursor:
text: CellBackground
cursor: CellForeground
search:
matches:
foreground: '{color0}'
background: '{color15}'
focused_match:
foreground: CellBackground
background: CellForeground
footer_bar:
foreground: '{color8}'
background: '{color7}'
line_indicator:
foreground: None
background: None
selection:
text: CellBackground
background: CellForeground
normal:
black: "{color0}"
red: "{color1}"
green: "{color2}"
yellow: "{color3}"
blue: "{color4}"
magenta: "{color5}"
cyan: "{color6}"
white: "{color7}"
bright:
black: "{color8}"
red: "{color9}"
green: "{color10}"
yellow: "{color11}"
blue: "{color12}"
magenta: "{color13}"
cyan: "{color14}"
white: "{color15}"

View File

@ -1,63 +0,0 @@
colors:
primary:
background: "{background}"
foreground: "{foreground}"
cursor:
text: CellBackground
cursor: CellForeground
vi_mode_cursor:
text: CellBackground
cursor: CellForeground
search:
matches:
foreground: '{color0}'
background: '{color15}'
focused_match:
foreground: CellBackground
background: CellForeground
footer_bar:
foreground: '{color8}'
background: '{color7}'
line_indicator:
foreground: None
background: None
selection:
text: CellBackground
background: CellForeground
normal:
black: "{color0}"
red: "{color1}"
green: "{color2}"
yellow: "{color3}"
blue: "{color4}"
magenta: "{color5}"
cyan: "{color6}"
white: "{color7}"
bright:
black: "{color8}"
red: "{color9}"
green: "{color10}"
yellow: "{color11}"
blue: "{color12}"
magenta: "{color13}"
cyan: "{color14}"
white: "{color15}"
dim:
black: "{color15}"
red: "{color9}"
green: "{color13}"
yellow: "{color11}"
blue: "{color12}"
magenta: "{color10}"
cyan: "{color14}"
white: "{color8}"

View File

@ -1,20 +0,0 @@
# alacritty
[alacritty][alacritty] is a new terminal emulator written in Rust.
## Use Cases
alacritty can be used to:
- Have a terminal emulator that just works
- Have a terminal emulator with modern features like live reload, and without all the extras like window management
- Master [tmux](/tmux) since you won't be relying on window management of your terminal emulator
You should not use alacritty if:
- You have a desire to output images in your terminal (use [kitty](/kitty) instead since [libsixel][libsixel] support is WIP)
- You have a need to use Japanese input in your terminal ([an issue][ime-support] for over 3 years in alacritty, [kitty](/kitty) supports this)
[alacritty]: https://github.com/alacritty/alacritty
[libsixel]: https://github.com/alacritty/alacritty/issues/910
[ime-support]: https://github.com/alacritty/alacritty/issues/1101

View File

@ -1,10 +0,0 @@
TIMING:
- TAP_MILLISEC: 1000
- DOUBLE_TAP_MILLISEC: 0
MAPPINGS:
- KEY: KEY_CAPSLOCK
TAP: KEY_ESC
HOLD: KEY_LEFTCTRL
- KEY: KEY_SYSRQ
TAP: KEY_SYSRQ
HOLD: KEY_RIGHTMETA

View File

@ -1,17 +0,0 @@
# dual-function-keys
[dual-function-keys][dual-function-keys] is a way to give your keys multiple functions.
## Use Cases
dual-function-keys can be used to:
- Have a caps lock key that works as ctrl and escape, without having your real ctrl key function as another escape key
- Have one keybinding config that works across Xorg, Wayland, and ttys
- Replace xcape, xmodmap, setxkbmap, keystrings, and similar technologies
You should not use dual-function-keys if:
- You should use dual-function-keys.
[dual-function-keys]: https://gitlab.com/interception/linux/plugins/dual-function-keys

View File

@ -1,27 +0,0 @@
root = true
# Use 2 spaces for indentation by default
[*]
charset = utf-8
end_of_line = lf
insert_final_newline = true
indent_size = 2
indent_style = space
trim_trailing_whitespace = true
# Use tab indentation for Logseq
[*.md]
indent_style = tab
# Use tab indentation (with size 4) for the following files
[Makefile]
indent_style = tab
indent_size = 4
[*.html]
indent_style = tab
indent_size = 4
[*.go]
indent_style = tab
indent_size = 4

View File

@ -1,20 +0,0 @@
# editorconfig
[editorconfig][editorconfig] is the standard tool for editing consistency between editors.
## Use Cases
editorconfig can be used to:
- Finally forget about whether spaces or tabs are being used; editorconfig will handle this automatically for you
- Share the same indentation settings in all the editors you and your colleagues use
You should not use editorconfig if:
- You should use editorconfig.
## Usage
If you use my [`.vimrc`](/vim) or [code](/code) config, editorconfig is already applied.
[editorconfig]: https://github.com/editorconfig/editorconfig

View File

@ -1,22 +0,0 @@
// Disable middle click paste
defaultPref("middlemouse.paste", false);
// Save to downloads by default
defaultPref("browser.download.useDownloadDir", true);
// Enable autoplay for muted media (default)
defaultPref("media.autoplay.default", 1);
// Autoplay when interacting with the website (default)
defaultPref("media.autoplay.blocking_policy", 0);
// Enable letterboxing
defaultPref("privacy.resistFingerprinting.letterboxing", true);
// Enable activity cursor
defaultPref("ui.use_activity_cursor", true);
// Open new tabs after the current tab
defaultPref("browser.tabs.insertAfterCurrent", true);
// vim:syn=javascript

View File

@ -1,15 +0,0 @@
# librewolf
[librewolf][librewolf] is a firefox fork focused on privacy, security, and freedom.
## Use Cases
librewolf can be used to:
- Use Firefox without worrying about changing the defaults.
You should not use librewolf if:
- You don't mind changing settings in Firefox.
[librewolf]: https://librewolf.net/

View File

@ -1,98 +0,0 @@
#!/usr/bin/bash
riverctl map normal Super+Shift Return spawn kitty
riverctl map normal Super Q close
riverctl map normal Super+Shift E exit
riverctl map normal Super J focus-view next
riverctl map normal Super K focus-view previous
riverctl map normal Super+Shift J swap next
riverctl map normal Super+Shift K swap previous
riverctl map normal Super Period focus-output next
riverctl map normal Super Comma focus-output previous
riverctl map normal Super+Shift Period send-to-output next
riverctl map normal Super+Shift Comma send-to-output previous
riverctl map normal Super Return zoom
riverctl map normal Super H send-layout-cmd rivertile "main-ratio -0.05"
riverctl map normal Super L send-layout-cmd rivertile "main-ratio +0.05"
riverctl map normal Super+Shift H send-layout-cmd rivertile "main-count +1"
riverctl map normal Super+Shift L send-layout-cmd rivertile "main-count -1"
riverctl map normal Super+Alt H move left 100
riverctl map normal Super+Alt J move down 100
riverctl map normal Super+Alt K move up 100
riverctl map normal Super+Alt L move right 100
riverctl map normal Super+Alt+Control H snap left
riverctl map normal Super+Alt+Control J snap down
riverctl map normal Super+Alt+Control K snap up
riverctl map normal Super+Alt+Control L snap right
riverctl map normal Super+Alt+Shift H resize horizontal -100
riverctl map normal Super+Alt+Shift J resize vertical 100
riverctl map normal Super+Alt+Shift K resize vertical -100
riverctl map normal Super+Alt+Shift L resize horizontal 100
riverctl map-pointer normal Super BTN_LEFT move-view
riverctl map-pointer normal Super BTN_RIGHT resize-view
riverctl map-pointer normal Super BTN_MIDDLE toggle-float
riverctl map normal Super Tab focus-previous-tags
for i in $(seq 1 9)
do
tags=$((1 << ($i - 1)))
riverctl map normal Super $i set-focused-tags $tags
riverctl map normal Super+Shift $i set-view-tags $tags
riverctl map normal Super+Control $i toggle-focused-tags $tags
riverctl map normal Super+Shift+Control $i toggle-view-tags $tags
done
all_tags=$(((1 << 32) - 1))
riverctl map normal Super 0 set-focused-tags $all_tags
riverctl map normal Super+Shift 0 set-view-tags $all_tags
riverctl map normal Super Space toggle-float
riverctl map normal Super F toggle-fullscreen
riverctl map normal Super Up send-layout-cmd rivertile "main-location top"
riverctl map normal Super Right send-layout-cmd rivertile "main-location right"
riverctl map normal Super Down send-layout-cmd rivertile "main-location bottom"
riverctl map normal Super Left send-layout-cmd rivertile "main-location left"
for mode in normal locked
do
riverctl map $mode None XF86Eject spawn 'eject -T'
riverctl map $mode None XF86AudioRaiseVolume spawn 'wpctl set-volume -l 1 @DEFAULT_AUDIO_SINK@ 5%+ && notify-send -t 2000 "Raised volume to" "$(wpctl get-volume @DEFAULT_AUDIO_SINK@ | tail -c 3)%"'
riverctl map $mode None XF86AudioLowerVolume spawn 'wpctl set-volume @DEFAULT_AUDIO_SINK@ 5%- && notify-send -t 2000 "Lowered volume to" "$(wpctl get-volume @DEFAULT_AUDIO_SINK@ | tail -c 3)%"'
riverctl map $mode None XF86AudioMute spawn 'wpctl set-mute @DEFAULT_AUDIO_SINK@ toggle && notify-send -t 2000 "Muted" "$(wpctl get-volume @DEFAULT_AUDIO_SINK@)"'
riverctl map $mode None XF86AudioMedia spawn 'playerctl play-pause'
riverctl map $mode None XF86AudioPlay spawn 'playerctl play-pause'
riverctl map $mode None XF86AudioPrev spawn 'playerctl previous'
riverctl map $mode None XF86AudioNext spawn 'playerctl next'
riverctl map $mode None XF86MonBrightnessUp spawn 'brightnessctl set +5% && notify-send -t 2000 "Increased brightness to" "$(brightnessctl get)"'
riverctl map $mode None XF86MonBrightnessDown spawn 'brightnessctl set 5%- && notify-send -t 2000 "Decreased brightness to" "$(brightnessctl get)"'
done
riverctl background-color 0x111111
riverctl border-color-focused 0x93a1a1
riverctl border-color-unfocused 0x586e75
riverctl set-repeat 50 300
riverctl default-layout rivertile
dunst &
rivertile -view-padding 0 -outer-padding 0 &
fcitx5 -d # Japanese input support
wl-paste -p --watch wl-copy -pc & # Disable middle click paste
udiskie & # Auto-mount drives
yambar &
touchpad="pointer-2-7-SynPS/2_Synaptics_TouchPad"
riverctl input $touchpad accel-profile flat
riverctl input $touchpad disable-while-typing disabled
riverctl input $touchpad natural-scroll enabled
riverctl input $touchpad tap enabled
riverctl map normal Super Z spawn 'rofi -show'
riverctl map normal Super R spawn '~/.config/river/init'
riverctl map normal Super P spawn 'grim -g "$(slurp)" - | wl-copy'
riverctl focus-follows-cursor normal
riverctl map-switch normal lid close spawn swaylock
riverctl map-switch normal lid open spawn "brightnessctl --device='tpacpi::kbd_backlight' set 2"

View File

@ -1,15 +0,0 @@
# river
[river][river] is a dynamic wayland compositor inspired by bspwm and dwm.
## Use Cases
river can be used to:
- Have all the advantages of Wayland, with the advantages of bspwm and dwm at the same time.
You should not use river if:
- You should use river.
[river]: https://github.com/riverwm/river

View File

@ -1,2 +0,0 @@
timeout 300 swaylock
before-sleep swaylock

View File

@ -1,16 +0,0 @@
# swayidle
[swayidle][swayidle] is an idle management daemon for Wayland.
## Use Cases
swayidle can be used to:
- Automatically lock the screen after a period of inactivity
- Automatically lock the screen on lid close (e.g. on a laptop)
You should not use swayidle if:
- You don't want to automatically lock the screen.
[swayidle]: https://github.com/swaywm/swayidle

View File

@ -1,37 +0,0 @@
# swaylock
show-keyboard-layout
daemonize
font="Noto Sans CJK JP"
font-size=20
indicator-radius=75
indicator-thickness=15
# Dracula colors
color=282a36
inside-color=1F202A
line-color=1F202A
ring-color=bd93f9
text-color=f8f8f2
layout-bg-color=1F202A
layout-text-color=f8f8f2
inside-clear-color=6272a4
line-clear-color=1F202A
ring-clear-color=6272a4
text-clear-color=1F202A
inside-ver-color=bd93f9
line-ver-color=1F202A
ring-ver-color=bd93f9
text-ver-color=1F202A
inside-wrong-color=ff5555
line-wrong-color=1F202A
ring-wrong-color=ff5555
text-wrong-color=1F202A
bs-hl-color=ff5555
key-hl-color=50fa7b
text-caps-lock-color=f8f8f2

View File

@ -1,18 +0,0 @@
# swaylock
[swaylock][swaylock] is a screen locker for Wayland. [swaylock-effects][swaylock-effects] adds additional features such as blur.
## Use Cases
swaylock can be used to:
- Lock the screen in a reasonable way
You should not use swaylock if:
- You're running on Xorg (use [xsecurelock][xsecurelock] instead)
- You use a desktop environment that already has a screen locker
[swaylock]: https://github.com/swaywm/swaylock
[swaylock-effects]: https://github.com/mortie/swaylock-effects
[xsecurelock]: https://github.com/google/xsecurelock

View File

@ -1,114 +0,0 @@
BMARGIN: &BMARGIN 10
bar:
height: 30
location: top
background: 262626f2
foreground: ffffffbb
font: Noto Sans CJK JP:Bold:size=13,Font Awesome 6 Free:style=solid:size=13
right-margin: *BMARGIN
layer: bottom
left:
-
script:
path: /home/donovan/.config/yambar/hyprland.sh
args: []
content:
string:
on-click:
left: sh -c 'hyprctl dispatch workspace e+1'
right: sh -c 'hyprctl dispatch workspace e-1'
middle: sh -c 'hyprctl dispatch workspace empty'
text: "{hypr_ws}"
left-margin: *BMARGIN
center:
-
script:
path: /home/donovan/.config/yambar/title.sh
args: []
content:
string:
on-click:
left: sh -c '~/.config/hypr/swapmaster.sh'
right: sh -c 'hyprctl dispatch movetoworkspace special'
middle: sh -c 'hyprctl dispatch killactive'
text: "{title}"
max: 90
right:
-
battery:
name: BAT0
anchors:
discharging: &discharging
list:
items:
- ramp:
tag: capacity
items:
- string: {text: }
- string: {text: }
- string: {text: }
- string: {text: }
- string: {text: }
- string: {text: }
- string: {text: }
- string: {text: }
- string: {text: }
- string: {text: }
- string: {text: "{capacity}% {estimate}", left-margin: *BMARGIN}
content:
map:
conditions:
state == unknown:
<<: *discharging
state == discharging:
<<: *discharging
state == charging:
- string: {text: }
- string: {text: "{capacity}% {estimate}"}
state == full:
- string: {text: }
- string: {text: " {capacity}%"}
state == "not charging":
- ramp:
tag: capacity
items:
- string: {text: }
- string: {text: }
- string: {text: }
- string: {text: }
- string: {text: }
- string: {text: }
- string: {text: }
- string: {text: }
- string: {text: }
- string: {text: }
- string: {text: "{capacity}%"}
-
backlight:
name: amdgpu_bl0
content:
string: {text: " {brightness}/255", left-margin: *BMARGIN}
-
script:
path: /home/donovan/.config/yambar/pipewire.sh
args: []
content:
string:
text: "{pipewire}"
left-margin: *BMARGIN
-
clock:
time-format: "%H:%M %Z"
content:
- string: {text: , right-margin: 5, left-margin: *BMARGIN}
- string: {text: "{date}", on-click: 'yad --calendar --title "今日は何の日"'}
- string: {text: , right-margin: 5, left-margin: *BMARGIN}
- string: {text: "{time}"}
-
label:
content:
string:
on-click: sh -c 'rofi -show'
text:
left-margin: *BMARGIN

Before

Width:  |  Height:  |  Size: 3.5 KiB

View File

@ -1,14 +0,0 @@
#!/bin/bash
declare hypr_ws
while true; do
hypr_ws=$(hyprctl workspaces -j | jq -r 'sort_by(.id)[] | .name' | sed -e "s/^special$/ 特別/g" -e "s/^1:/ 一/g" -e "s/^1$/ 一/g" -e "s/^2/ 二/g" -e "s/^3/ 三/g" -e "s/^4/ 四/g" -e "s/^5/ 五/g" -e "s/^6/ 六/g" -e "s/^7/ 七/g" -e "s/^8/ 八/g" -e "s/^9/ 九/g" -e "s/^10/ 十/g" | tr '\n' ' ')
printf -- '%s\n' "hypr_ws|string|${hypr_ws}"
printf -- '%s\n' ""
sleep 0.1
done
unset hypr_ws

View File

@ -1,29 +0,0 @@
#!/bin/bash
declare pipewire
while true; do
pw="$(wpctl get-volume @DEFAULT_AUDIO_SINK@ | choose 1)"
muted="$(wpctl get-volume @DEFAULT_AUDIO_SINK@ | choose 2)"
pw2="$(echo "$pw * 100 / 1" | bc)"
if [[ "$muted" == "[MUTED]" ]]; then
pipewire="$pw2"
else
if [[ "$pw2" -gt 59 ]]; then
pipewire="$pw2"
else
if [[ "$pw2" -gt 0 ]]; then
pipewire="$pw2"
else
pipewire="$pw2"
fi
fi
fi
printf -- '%s\n' "pipewire|string|${pipewire}%"
printf -- '%s\n' ""
sleep 0.1
done
unset pipewire

View File

@ -1,19 +0,0 @@
#!/bin/bash
declare title
# LATER: Use hyprevents instead of while true
while true; do
title="$(hyprctl activewindow -j | jq -r '.title')"
if [[ "$title" == "null" ]]; then
title="$(mpc status | head -n 1)"
fi
printf -- '%s\n' "title|string|${title}"
printf -- '%s\n' ""
sleep 0.1
done
unset title

View File

@ -1,15 +0,0 @@
# yambar
[yambar][yambar] is an information panel with X11 and Wayland support.
## Use Cases
yambar can be used to:
- Have a panel that works natively in both X11 and Wayland.
You should not use yambar if:
- You want tray icons or taskbar support.
[yambar]: https://codeberg.org/dnkl/yambar