Update alacritty config

This commit is contained in:
Akemi Izuko 2023-12-23 20:13:56 -07:00
parent 3c98a36227
commit 451ae82fbf
Signed by: akemi
GPG key ID: 8DE0764E1809E9FC
4 changed files with 19 additions and 32 deletions

View file

@ -21,8 +21,6 @@ font:
x: 0
y: 1
use_thin_strokes: true
draw_bold_text_with_bright_colors: false
# Colors (Gruvbox dark)
@ -40,9 +38,6 @@ colors:
focused_match:
foreground: CellBackground
background: CellForeground
bar:
background: '#c5c8c6'
foreground: '#1d1f21'
selection:
text: '#000000'
@ -55,33 +50,21 @@ import:
# Window GUI
#==========================
window:
title: JoJo
position:
x: 536
y: 164
dimensions:
columns: 134 # 16 size font
lines: 36
#columns: 150 # 14 size font
#lines: 40
padding:
x: 4
y: 0
decorations: None
startup_mode: Windowed
dynamic_title: false
opacity: 1
title: Alacritty
dynamic_title: true
scrolling:
history: 10000
multiplier: 3
multiplier: 1
bell:
duration: 0
color: '#ffff99'
duration: 0 # Disable
command: None
selection:
@ -93,6 +76,7 @@ cursor:
blinking: Always
vi_mode_style: Block
blink_interval: 400
blink_timeout: 0 # Stop cursor from freezing
unfocused_hollow: true
thickness: 0.15

View file

@ -29,6 +29,10 @@ declare -i a=2 b=3 # Multiple on the same line are fine
(( a = 4 + b )) # Spacing is optional, same as above
declare -i c=$((a**b + 4)) # c == 7**3 + 4 == 347
declare -ia arr=(0 1 2 3)
(( arr[a] = 3 )) # Array indexing also no longer needs $
(( arr[100] = 3 )) # Array is acc an integer hashmap, so over-indexing works
```
## Using numbers

View file

@ -110,10 +110,8 @@ main() {
exit 0
fi
if [[ "$1" == "install" ]]; then
install_web_packages
install_cargo_packages
fi
install_web_packages
install_cargo_packages
printf 'Done\n'
}

View file

@ -8,7 +8,7 @@
declare -r ADJUST="$1"
declare -r NOTIFY_SOUND="$2"
declare -r MAX_VOLUME="100"
declare -ir MAX_VOLUME=100
set_volume() {
if ! pactl set-sink-volume @DEFAULT_SINK@ "${1}%"; then
@ -25,7 +25,7 @@ play_notify_sound() {
exit 1
fi
if command -v ffmpeg &>/dev/null; then
if command -v ffplay &>/dev/null; then
ffplay -nodisp -autoexit -v error "$1"
elif command -v afplay &>/dev/null; then
afplay "$1"
@ -44,15 +44,16 @@ readonly curr_volume=$(pactl get-sink-volume @DEFAULT_SINK@ | awk '
if ! [[ "$curr_volume" =~ ^[0-9]+$ ]]; then
printf "Failed to find default sink's volume: %s\n" "$curr_volume" >&2
exit 1
fi
declare -ir new_volume=$(($curr_volume + $ADJUST))
declare -ir new_volume=$((curr_volume + ADJUST))
printf "Changing volumes from %d -> %d\n" "$curr_volume" "$new_volume" >&2
if [[ "$new_volume" -gt "$MAX_VOLUME" ]]; then
set_volume "$MAX_VOLUME"
elif [[ "$new_volume" -lt "0" ]]; then
set_volume "0"
if [[ $new_volume -gt $MAX_VOLUME ]]; then
set_volume $MAX_VOLUME
elif [[ $new_volume -lt 0 ]]; then
set_volume 0
else
set_volume "$new_volume"
set_volume $new_volume
fi