Krolyxon
Commit 32247d5

Branches

Refs →

dotfiles-x1132247d5

use Fira Code as font, add setwall script

Author
krolxon
Date
2025-08-13 15:01 +0530
Parent
ecb14b5
Commit
32247d59a2ea42542328071c3784bec753b8ce00

+63 −46

6 files changed

  1. M .config/alacritty/alacritty.toml +7 −7
  2. M .config/gtk-2.0/gtkrc-2.0 +1 −1
  3. D .local/bin/genwall +0 −18
  4. D .local/bin/randomwall +0 −17
  5. M .local/bin/screenshot +3 −3
  6. A .local/bin/setwall +52 −0
M .config/alacritty/alacritty.toml View
@@ -89,10 +89,10 @@ persistent_logging = false
8989 render_timer = false
9090
9191 [font]
92−size = 11
92+size = 12
9393
9494 [font.bold]
95−family = "JetBrainsMono Nerd Font"
95+family = "Fira Code"
9696 style = "Bold"
9797
9898 [font.glyph_offset]
@@ -100,11 +100,11 @@ x = 0
100100 y = 0
101101
102102 [font.italic]
103−family = "JetBrainsMono Nerd Font"
103+family = "Fira Code"
104104 style = "Italic"
105105
106106 [font.normal]
107−family = "JetBrainsMono Nerd Font"
107+family = "Fira Code"
108108 style = "Regular"
109109
110110 [font.offset]
@@ -650,7 +650,7 @@ semantic_escape_chars = ",│`|:\"' ()[]{}<>"
650650 [window]
651651 decorations = "none"
652652 dynamic_padding = false
653−opacity = 0.8
653+opacity = 0.9
654654 startup_mode = "Maximized"
655655
656656 [window.dimensions]
@@ -658,8 +658,8 @@ columns = 0
658658 lines = 0
659659
660660 [window.padding]
661−x = 0
662−y = 0
661+x = 5
662+y = 5
663663
664664 [general]
665665
M .config/gtk-2.0/gtkrc-2.0 View
@@ -4,7 +4,7 @@
44 include "/home/krolyxon/.gtkrc-2.0.mine"
55 gtk-theme-name="Arc-Dark"
66 gtk-icon-theme-name="Papirus-Dark"
7−gtk-font-name="JetBrainsMonoNL Nerd Font Thin 11"
7+gtk-font-name="Fira Code 11"
88 gtk-cursor-theme-name="Adwaita"
99 gtk-cursor-theme-size=0
1010 gtk-toolbar-style=GTK_TOOLBAR_BOTH
D .local/bin/genwall View
@@ -1,18 +0,0 @@
1−#!/bin/sh
2−
3−# Dependencies:
4−# convert wal xdotool xwallpaper
5−
6−wall_dir=~/pix/wall
7−
8−if [ -z "$1" ]; then
9− wall="$(find "$wall_dir" -type f -name "*.jpg" -o -name "*.png" | shuf -n1)"
10−else
11− wall="$1"
12−fi
13−
14−convert "$wall" ~/.local/share/bg.jpg
15−xwallpaper --zoom ~/.local/share/bg.jpg
16−wal -c
17−wal -i ~/.local/share/bg.jpg
18−xdotool key super+F5
D .local/bin/randomwall View
@@ -1,17 +0,0 @@
1−#!/bin/bash
2−WALL_DIR="$HOME/pix/wallpapers/onedarkwallpapers/"
3−NEW_WALL=$(find "$WALL_DIR" -type f | shuf -n 1)
4−
5−if ! pgrep -x hyprpaper >/dev/null; then
6− # hyprpaper not running → write config and start it
7− cat > ~/.config/hypr/hyprpaper.conf <<EOF
8−preload = $NEW_WALL
9−wallpaper = ,$NEW_WALL
10−EOF
11− hyprpaper &
12−else
13− # hyprpaper is running → just update it live
14− hyprctl hyprpaper preload "$NEW_WALL"
15− hyprctl hyprpaper wallpaper ",$NEW_WALL"
16−fi
17−
M .local/bin/screenshot View
@@ -3,9 +3,9 @@
33 ocr_cmd="wl-copy"
44
55 case "$(printf "a selected area (copy)\ncurrent window (copy)\nfull screen (copy)\na selected area\ncurrent window\nfull screen\na selected area (OCR)" | rofi -dmenu -l 7 -i -p "Screenshot which area?")" in
6− "a selected area (copy)") hyprshot -m region -c ;;
7− "current window (copy)") hyprshot -m window -c ;;
8− "full screen (copy)") hyprshot -m output -c ;;
6+ "a selected area (copy)") hyprshot -m region --clipboard-only ;;
7+ "current window (copy)") hyprshot -m window --clipboard-only ;;
8+ "full screen (copy)") hyprshot -m output --clipboard-only ;;
99
1010 "a selected area") hyprshot -m region -o ~/pix/ss -f "pic-selected-$(uuidgen | awk -F- '{printf $2}')-$(date '+%y-%m-%d').png" ;;
1111 "current window") hyprshot -m window -o ~/pix/ss -f "pic-window-$(uuidgen | awk -F- '{printf $2}')-$(date '+%y-%m-%d').png" ;;
A .local/bin/setwall View
@@ -0,0 +1,52 @@
1+#!/bin/bash
2+WALL_DIR="$HOME/pix/wallpapers/onedarkwallpapers/"
3+MODE="random"
4+CUSTOM_PATH=""
5+
6+# Parse options
7+while getopts ":mp:" opt; do
8+ case $opt in
9+ m) MODE="menu" ;;
10+ p) MODE="path"; CUSTOM_PATH="$OPTARG" ;;
11+ \?) echo "Usage: $0 [-m] [-p /path/to/image]" >&2; exit 1 ;;
12+ :) echo "Option -$OPTARG requires an argument." >&2; exit 1 ;;
13+ esac
14+done
15+
16+# Choose wallpaper
17+case $MODE in
18+ random)
19+ NEW_WALL=$(find "$WALL_DIR" -type f | shuf -n 1)
20+ ;;
21+ path)
22+ if [[ -f "$CUSTOM_PATH" ]]; then
23+ NEW_WALL="$CUSTOM_PATH"
24+ else
25+ echo "Error: File not found -> $CUSTOM_PATH" >&2
26+ exit 1
27+ fi
28+ ;;
29+ menu)
30+ WALLPAPER_LIST=$(find "$WALL_DIR" -type f | sort | sed "s|$WALL_DIR||")
31+ CHOSEN=$(echo "$WALLPAPER_LIST" | rofi -dmenu -i -p "Choose wallpaper:")
32+ if [[ -z "$CHOSEN" ]]; then
33+ NEW_WALL=$(find "$WALL_DIR" -type f | shuf -n 1)
34+ else
35+ NEW_WALL="$WALL_DIR$CHOSEN"
36+ fi
37+ ;;
38+esac
39+
40+# Apply wallpaper
41+if ! pgrep -x hyprpaper >/dev/null; then
42+ # Hyprpaper not running → start with chosen wallpaper
43+ cat > ~/.config/hypr/hyprpaper.conf <<EOF
44+preload = $NEW_WALL
45+wallpaper = ,$NEW_WALL
46+EOF
47+ hyprpaper &
48+else
49+ # Hyprpaper is running → change it live
50+ hyprctl hyprpaper preload "$NEW_WALL"
51+ hyprctl hyprpaper wallpaper ",$NEW_WALL"
52+fi