mirror of
https://git.sr.ht/~coasteen/dotfiles
synced 2026-03-21 23:19:22 +01:00
hypr updates, the GREAT mpc script
This commit is contained in:
parent
7680c64082
commit
16a28499ef
7 changed files with 233 additions and 19 deletions
24
.mpdconf
24
.mpdconf
|
|
@ -1,20 +1,16 @@
|
||||||
bind_to_address "/home/coast/.mpd/socket"
|
|
||||||
bind_to_address "127.0.0.1"
|
bind_to_address "127.0.0.1"
|
||||||
|
|
||||||
music_directory "/home/coast/Music"
|
music_directory "/home/coast/Music"
|
||||||
playlist_directory "/home/coast/.mpd/playlists"
|
playlist_directory "/home/coast/.mpd/playlists"
|
||||||
db_file "~/.mpd/database"
|
|
||||||
log_file "~/.mpd/log"
|
db_file "/home/coast/.mpd/database"
|
||||||
|
log_file "/home/coast/.mpd/log"
|
||||||
|
pid_file "/home/coast/.mpd/mpd.pid"
|
||||||
|
|
||||||
|
user "coast"
|
||||||
|
|
||||||
audio_output {
|
audio_output {
|
||||||
type "oss"
|
type "pulse"
|
||||||
name "OSS Output"
|
name "PulseAudio Output"
|
||||||
mixer_type "software"
|
mixer_type "software"
|
||||||
}
|
}
|
||||||
|
|
||||||
audio_output {
|
|
||||||
type "fifo"
|
|
||||||
name "myfifo"
|
|
||||||
path "/tmp/mpd.fifo"
|
|
||||||
format "44100:16:2"
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
|
||||||
14
config/hypr/hypridle.conf
Normal file
14
config/hypr/hypridle.conf
Normal file
|
|
@ -0,0 +1,14 @@
|
||||||
|
general {
|
||||||
|
lock_cmd = pidof hyprlock || hyprlock
|
||||||
|
}
|
||||||
|
|
||||||
|
listener {
|
||||||
|
timeout = 300
|
||||||
|
on-timeout = hyprlock
|
||||||
|
}
|
||||||
|
|
||||||
|
listener {
|
||||||
|
timeout = 600
|
||||||
|
on-timeout = hyprctl dispatch dpms off
|
||||||
|
on-resume = hyprctl dispatch dpms on
|
||||||
|
}
|
||||||
|
|
@ -1,18 +1,29 @@
|
||||||
monitor=HDMI-A-1,1920x1080@75,auto,auto
|
monitor=HDMI-A-1,1920x1080@75,auto,auto
|
||||||
|
|
||||||
|
hide_on_fullscreen = true
|
||||||
|
|
||||||
$terminal = foot
|
$terminal = foot
|
||||||
$menu = rofi -show drun -config /home/coast/.config/rofi/config.rasi
|
$menu = rofi -show drun -config /home/coast/.config/rofi/config.rasi
|
||||||
|
$webBrowser = firefox-bin
|
||||||
|
$discordApp = vesktop-bin --proxy-server="socks5://127.0.0.1:65000"
|
||||||
|
$restartWaybar = pkill waybar; waybar&disown
|
||||||
|
|
||||||
exec-once = hyprctl setcursor Adwaita 24 &
|
exec-once = hyprctl setcursor Adwaita 24 &
|
||||||
exec-once = wbg /home/coast/Pictures/walls/wallhaven-d83vjl_1920x1080.png &
|
exec-once = wbg /home/coast/Pictures/walls/wallhaven-d83vjl_1920x1080.png &
|
||||||
exec-once = eww daemon && eww open bar &
|
exec-once = hypridle &
|
||||||
|
exec-once = hyprpm reload -n;
|
||||||
|
exec-once = dbus-update-activation-environment WAYLAND_DISPLAY XDG_CURRENT_DESKTOP=Hyprland
|
||||||
|
exec-once = gnome-keyring-daemon --start --components=secrets
|
||||||
|
exec-once = waybar &
|
||||||
|
exec-once = mpd ~/.mpdconf &
|
||||||
|
exec-once = mpc add /;
|
||||||
|
|
||||||
env = XCURSOR_SIZE,24
|
env = XCURSOR_SIZE,24
|
||||||
env = HYPRCURSOR_SIZE,24
|
env = HYPRCURSOR_SIZE,24
|
||||||
|
|
||||||
general {
|
general {
|
||||||
gaps_in = 5
|
gaps_in = 5
|
||||||
gaps_out = 5
|
gaps_out = 15
|
||||||
border_size = 2
|
border_size = 2
|
||||||
col.active_border = rgba(6c6c9dee) rgba(1e1e2eee) 45deg
|
col.active_border = rgba(6c6c9dee) rgba(1e1e2eee) 45deg
|
||||||
col.inactive_border = rgba(1e1e2eaa)
|
col.inactive_border = rgba(1e1e2eaa)
|
||||||
|
|
@ -22,7 +33,7 @@ general {
|
||||||
}
|
}
|
||||||
|
|
||||||
decoration {
|
decoration {
|
||||||
rounding = 0
|
rounding = 10
|
||||||
active_opacity = 1.0
|
active_opacity = 1.0
|
||||||
inactive_opacity = 1.0
|
inactive_opacity = 1.0
|
||||||
shadow {
|
shadow {
|
||||||
|
|
@ -76,6 +87,7 @@ $mainMod = SUPER
|
||||||
bind = $mainMod, Return, exec, $terminal
|
bind = $mainMod, Return, exec, $terminal
|
||||||
bind = $mainMod, S, killactive,
|
bind = $mainMod, S, killactive,
|
||||||
bind = $mainMod, M, exec, killall eww; eww daemon && eww open bar
|
bind = $mainMod, M, exec, killall eww; eww daemon && eww open bar
|
||||||
|
bind = $mainMod SHIFT, Q, exit
|
||||||
bind = $mainMod, Space, togglefloating
|
bind = $mainMod, Space, togglefloating
|
||||||
bind = $mainMod, Space, resizeactive, exact 1000 800
|
bind = $mainMod, Space, resizeactive, exact 1000 800
|
||||||
bind = $mainMod, Space, centerwindow
|
bind = $mainMod, Space, centerwindow
|
||||||
|
|
@ -117,7 +129,6 @@ bind = $mainMod, 6, workspace, 6
|
||||||
bind = $mainMod, 7, workspace, 7
|
bind = $mainMod, 7, workspace, 7
|
||||||
bind = $mainMod, 8, workspace, 8
|
bind = $mainMod, 8, workspace, 8
|
||||||
bind = $mainMod, 9, workspace, 9
|
bind = $mainMod, 9, workspace, 9
|
||||||
bind = $mainMod, 0, workspace, 10
|
|
||||||
|
|
||||||
bind = $mainMod SHIFT, 1, movetoworkspace, 1
|
bind = $mainMod SHIFT, 1, movetoworkspace, 1
|
||||||
bind = $mainMod SHIFT, 2, movetoworkspace, 2
|
bind = $mainMod SHIFT, 2, movetoworkspace, 2
|
||||||
|
|
@ -128,14 +139,64 @@ bind = $mainMod SHIFT, 6, movetoworkspace, 6
|
||||||
bind = $mainMod SHIFT, 7, movetoworkspace, 7
|
bind = $mainMod SHIFT, 7, movetoworkspace, 7
|
||||||
bind = $mainMod SHIFT, 8, movetoworkspace, 8
|
bind = $mainMod SHIFT, 8, movetoworkspace, 8
|
||||||
bind = $mainMod SHIFT, 9, movetoworkspace, 9
|
bind = $mainMod SHIFT, 9, movetoworkspace, 9
|
||||||
bind = $mainMod SHIFT, 0, movetoworkspace, 10
|
|
||||||
|
|
||||||
bind = $mainMod, C, togglespecialworkspace, magic
|
bind = $mainMod, C, togglespecialworkspace, magic
|
||||||
bind = $mainMod SHIFT, S, exec, grim -g "$(slurp)" - | wl-copy
|
bind = $mainMod SHIFT, S, exec, grim -g "$(slurp)" - | wl-copy
|
||||||
|
|
||||||
|
bind = $mainMod CONTROL, L, exec, hyprlock
|
||||||
|
|
||||||
|
bind = $mainMod SHIFT, B, exec, $webBrowser
|
||||||
|
bind = $mainMod SHIFT, V, exec, $discordApp
|
||||||
|
|
||||||
bindm = $mainMod, mouse:272, movewindow
|
bindm = $mainMod, mouse:272, movewindow
|
||||||
bindm = $mainMod, mouse:273, resizewindow
|
bindm = $mainMod, mouse:273, resizewindow
|
||||||
|
|
||||||
|
bind = $mainMod SHIFT, P, exec, $restartWaybar
|
||||||
|
|
||||||
|
plugin {
|
||||||
|
hyprbars {
|
||||||
|
enabled = true
|
||||||
|
|
||||||
|
bar_height = 25
|
||||||
|
bar_color = rgba(1e1e2eaa)
|
||||||
|
bar_blur = true
|
||||||
|
|
||||||
|
bar_title_enabled = true
|
||||||
|
bar_text_font = "JetBrainsMono Nerd Font"
|
||||||
|
bar_text_size = 12
|
||||||
|
bar_text_align = center
|
||||||
|
col.text = rgba(ffffffdd)
|
||||||
|
|
||||||
|
bar_buttons_alignment = left
|
||||||
|
bar_padding = 10
|
||||||
|
bar_button_padding = 6
|
||||||
|
icon_on_hover = false
|
||||||
|
|
||||||
|
hyprbars-button = rgb(ff5f57), 14, , hyprctl dispatch killactive
|
||||||
|
hyprbars-button = rgb(febb2e), 14, , hyprctl dispatch togglefloating
|
||||||
|
hyprbars-button = rgb(28c840), 14, , hyprctl dispatch fullscreen 1
|
||||||
|
|
||||||
|
on_double_click = hyprctl dispatch fullscreen 1
|
||||||
|
}
|
||||||
|
|
||||||
|
hyprexpo {
|
||||||
|
columns = 3
|
||||||
|
gap_size = 5
|
||||||
|
bg_col = rgba(1e1e2eaa)
|
||||||
|
workspace_method = center current
|
||||||
|
gesture_distance = 300
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
bind = $mainMod, e, hyprexpo:expo, toggle
|
||||||
|
|
||||||
|
bind = $mainMod ALT, up, exec, /home/coast/.local/bin/mpc-shuf.sh shuf
|
||||||
|
bind = $mainMod ALT, down, exec, /home/coast/.local/bin/mpc-shuf.sh shufno
|
||||||
|
bind = $mainMod ALT, right, exec, /home/coast/.local/bin/mpc-shuf.sh next
|
||||||
|
bind = $mainMod ALT, left, exec, /home/coast/.local/bin/mpc-shuf.sh prev
|
||||||
|
bind = $mainMod SHIFT, R, exec, /home/coast/.local/bin/mpc-shuf.sh search
|
||||||
|
bind = $mainMod, slash, exec, /home/coast/.local/bin/mpc-shuf.sh current
|
||||||
|
|
||||||
xwayland {
|
xwayland {
|
||||||
enabled = true
|
enabled = true
|
||||||
}
|
}
|
||||||
|
|
|
||||||
35
config/hypr/hyprlock.conf
Normal file
35
config/hypr/hyprlock.conf
Normal file
|
|
@ -0,0 +1,35 @@
|
||||||
|
background {
|
||||||
|
monitor =
|
||||||
|
path = screenshot
|
||||||
|
blur_passes = 3
|
||||||
|
blur_size = 12
|
||||||
|
dim = 0.4
|
||||||
|
}
|
||||||
|
|
||||||
|
input-field {
|
||||||
|
monitor =
|
||||||
|
size = 350, 60
|
||||||
|
position = 0, -100
|
||||||
|
rounding = 14
|
||||||
|
border_width = 2
|
||||||
|
|
||||||
|
font = "JetBrainsMono Nerd Font"
|
||||||
|
font_size = 22
|
||||||
|
font_color = rgb(245, 224, 220)
|
||||||
|
|
||||||
|
inner_color = rgb(30, 24, 36)
|
||||||
|
outer_color = rgb(58, 52, 70)
|
||||||
|
border_color = rgb(252, 205, 205)
|
||||||
|
placeholder_text = "Password..."
|
||||||
|
fade_on_empty = true
|
||||||
|
}
|
||||||
|
|
||||||
|
label {
|
||||||
|
monitor =
|
||||||
|
text = $TIME
|
||||||
|
font = "JetBrainsMono Nerd Font"
|
||||||
|
font_size = 64
|
||||||
|
position = 0, 100
|
||||||
|
color = rgb(245, 224, 220)
|
||||||
|
}
|
||||||
|
|
||||||
27
config/waybar-2/config.jsonc
Normal file
27
config/waybar-2/config.jsonc
Normal file
|
|
@ -0,0 +1,27 @@
|
||||||
|
{
|
||||||
|
"layer": "top",
|
||||||
|
"position": "bottom",
|
||||||
|
"height": 35,
|
||||||
|
"spacing": 4,
|
||||||
|
"modules-left": ["hyprland/workspaces"],
|
||||||
|
"modules-center": ["hyprland/window"],
|
||||||
|
"modules-right": ["clock"],
|
||||||
|
|
||||||
|
"hyprland/workspaces": {
|
||||||
|
"disable-scroll": true,
|
||||||
|
"all-outputs": true,
|
||||||
|
"format": "{id}",
|
||||||
|
"on-click": "activate"
|
||||||
|
},
|
||||||
|
|
||||||
|
"hyprland/window": {
|
||||||
|
"format": "{}",
|
||||||
|
"max-length": 40,
|
||||||
|
"separate-outputs": true
|
||||||
|
},
|
||||||
|
|
||||||
|
"clock": {
|
||||||
|
"format": "{:%I:%M %p}",
|
||||||
|
"tooltip": false
|
||||||
|
}
|
||||||
|
}
|
||||||
42
config/waybar-2/style.css
Normal file
42
config/waybar-2/style.css
Normal file
|
|
@ -0,0 +1,42 @@
|
||||||
|
* {
|
||||||
|
border: none;
|
||||||
|
border-radius: 0;
|
||||||
|
font-family: "JetBrainsMono Nerd Font";
|
||||||
|
font-size: 15px;
|
||||||
|
min-height: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
window#waybar {
|
||||||
|
background-color: rgba(30, 30, 46, 0.8);
|
||||||
|
color: #cdd6f4;
|
||||||
|
}
|
||||||
|
|
||||||
|
#workspaces {
|
||||||
|
margin: 0 4px;
|
||||||
|
}
|
||||||
|
|
||||||
|
#workspaces button {
|
||||||
|
padding: 0 8px;
|
||||||
|
margin: 0 4px;
|
||||||
|
color: #6c7086;
|
||||||
|
}
|
||||||
|
|
||||||
|
#workspaces button.active {
|
||||||
|
color: #89b4fa;
|
||||||
|
border-bottom: 2px solid #89b4fa;
|
||||||
|
}
|
||||||
|
|
||||||
|
#workspaces button:hover {
|
||||||
|
background: rgba(137, 180, 250, 0.1);
|
||||||
|
box-shadow: inherit;
|
||||||
|
text-shadow: inherit;
|
||||||
|
}
|
||||||
|
|
||||||
|
#window {
|
||||||
|
color: #cdd6f4;
|
||||||
|
}
|
||||||
|
|
||||||
|
#clock {
|
||||||
|
font-weight: bold;
|
||||||
|
padding-right: 15px;
|
||||||
|
}
|
||||||
39
local/bin/mpc-shuf.sh
Executable file
39
local/bin/mpc-shuf.sh
Executable file
|
|
@ -0,0 +1,39 @@
|
||||||
|
#!/usr/bin/env sh
|
||||||
|
|
||||||
|
case "$1" in
|
||||||
|
shuf) mpc random on && notify-send "Shuffle enabled" && exit 0 ;;
|
||||||
|
shufno) mpc random off && notify-send "Shuffle disabled" && exit 0 ;;
|
||||||
|
next) mpc next ;;
|
||||||
|
prev) mpc prev ;;
|
||||||
|
current) ;;
|
||||||
|
search)
|
||||||
|
choice=$(mpc search any "" | \
|
||||||
|
mpc --format '%title% - %artist% - %album%' search any "" 2>/dev/null | \
|
||||||
|
rofi -dmenu -i -p "Search music")
|
||||||
|
[ -z "$choice" ] && exit 0
|
||||||
|
file=$(mpc --format '%title% - %artist% - %album%\t%file%' search any "" | \
|
||||||
|
grep "^$choice " | head -n 1 | cut -f2)
|
||||||
|
[ -z "$file" ] && exit 0
|
||||||
|
mpc clear
|
||||||
|
mpc add "$file"
|
||||||
|
mpc play
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
|
||||||
|
mpc play
|
||||||
|
mpc volume 15
|
||||||
|
|
||||||
|
song_file=$(mpc --format '%file%' current)
|
||||||
|
music_dir="/home/coast/Music"
|
||||||
|
song_abs="$music_dir/$song_file"
|
||||||
|
song_dir=$(dirname "$song_abs")
|
||||||
|
|
||||||
|
cover=$(find "$song_dir" -maxdepth 1 \
|
||||||
|
\( -iname '*cover*.jpg' -o -iname '*cover*.png' \
|
||||||
|
-o -iname '*folder*.jpg' -o -iname '*folder*.png' \
|
||||||
|
-o -iname '*front*.jpg' -o -iname '*front*.png' \) \
|
||||||
|
| head -n 1)
|
||||||
|
|
||||||
|
[ -z "$cover" ] && cover="/usr/share/icons/hicolor/48x48/apps/musical-note.png"
|
||||||
|
|
||||||
|
notify-send "Now playing..." "$(mpc current)" -i "$cover"
|
||||||
Loading…
Add table
Reference in a new issue