mirror of
https://github.com/xsghetti/HyprCrux.git
synced 2025-07-17 02:36:34 -04:00
New Scripts
This commit is contained in:
parent
4875c2f2df
commit
bcac3c08e4
6 changed files with 116 additions and 7 deletions
|
@ -22,7 +22,7 @@ decoration {
|
||||||
|
|
||||||
blur {
|
blur {
|
||||||
enabled = true
|
enabled = true
|
||||||
size = 2
|
size = 5
|
||||||
passes = 3
|
passes = 3
|
||||||
new_optimizations = true
|
new_optimizations = true
|
||||||
ignore_opacity = on
|
ignore_opacity = on
|
||||||
|
|
|
@ -46,7 +46,7 @@ workspace = 5, persistent:true,monitor:eDP-1
|
||||||
$terminal = kitty
|
$terminal = kitty
|
||||||
$fileManager = dolphin
|
$fileManager = dolphin
|
||||||
$menu = rofi -show drun
|
$menu = rofi -show drun
|
||||||
$browser = firefox
|
$browser = google-chrome-stable
|
||||||
$discord = discord # --enable-features=UseOzonePlatform --ozone-platform=wayland
|
$discord = discord # --enable-features=UseOzonePlatform --ozone-platform=wayland
|
||||||
|
|
||||||
# Some default env vars.
|
# Some default env vars.
|
||||||
|
@ -88,7 +88,7 @@ dwindle {
|
||||||
|
|
||||||
master {
|
master {
|
||||||
# See https://wiki.hyprland.org/Configuring/Master-Layout/ for more
|
# See https://wiki.hyprland.org/Configuring/Master-Layout/ for more
|
||||||
#new_is_master = true
|
new_status = master
|
||||||
}
|
}
|
||||||
|
|
||||||
gestures {
|
gestures {
|
||||||
|
|
|
@ -16,7 +16,7 @@ background {
|
||||||
}
|
}
|
||||||
|
|
||||||
input-field {
|
input-field {
|
||||||
monitor = DP-1
|
monitor = eDP-1
|
||||||
size = 250, 50
|
size = 250, 50
|
||||||
outline_thickness = 3
|
outline_thickness = 3
|
||||||
dots_size = 0.2 # Scale of input-field height, 0.2 - 0.8
|
dots_size = 0.2 # Scale of input-field height, 0.2 - 0.8
|
||||||
|
@ -35,7 +35,7 @@ input-field {
|
||||||
|
|
||||||
# Current time
|
# Current time
|
||||||
label {
|
label {
|
||||||
monitor = DP-1
|
monitor = eDP-1
|
||||||
text = cmd[update:1300] echo "<b><big> $(date +"%H:%M:%S") </big></b>"
|
text = cmd[update:1300] echo "<b><big> $(date +"%H:%M:%S") </big></b>"
|
||||||
color = $color7
|
color = $color7
|
||||||
font_size = 64
|
font_size = 64
|
||||||
|
@ -47,7 +47,7 @@ label {
|
||||||
|
|
||||||
# User label
|
# User label
|
||||||
label {
|
label {
|
||||||
monitor = DP-1
|
monitor = eDP-1
|
||||||
text = Hey <span text_transform="capitalize" size="larger">$USER</span>
|
text = Hey <span text_transform="capitalize" size="larger">$USER</span>
|
||||||
color = $color7
|
color = $color7
|
||||||
font_size = 20
|
font_size = 20
|
||||||
|
@ -60,7 +60,7 @@ label {
|
||||||
|
|
||||||
# Type to unlock
|
# Type to unlock
|
||||||
label {
|
label {
|
||||||
monitor = DP-1
|
monitor = eDP-1
|
||||||
text = Type to unlock!
|
text = Type to unlock!
|
||||||
color = $color7
|
color = $color7
|
||||||
font_size = 16
|
font_size = 16
|
||||||
|
|
|
@ -125,3 +125,12 @@ bind = , xf86audioraisevolume, exec, wpctl set-volume -l 1.0 @DEFAULT_SINK@ 5%+
|
||||||
bind = , xf86audiolowervolume, exec, wpctl set-volume -l 1.0 @DEFAULT_SINK@ 5%-
|
bind = , xf86audiolowervolume, exec, wpctl set-volume -l 1.0 @DEFAULT_SINK@ 5%-
|
||||||
bind = , xf86audiomute, exec, wpctl set-mute @DEFAULT_SINK@ toggle
|
bind = , xf86audiomute, exec, wpctl set-mute @DEFAULT_SINK@ toggle
|
||||||
|
|
||||||
|
|
||||||
|
bind = $mainMod, EQUAL, exec, ~/.config/hypr/scripts/gaps.sh +
|
||||||
|
bind = $mainMod, MINUS, exec, ~/scripts/gaps.sh -
|
||||||
|
|
||||||
|
# Adjust gaps_out
|
||||||
|
binde = $mainMod SHIFT, UP, exec, ~/.config/hypr/scripts/gaps_out.sh up
|
||||||
|
binde = $mainMod SHIFT, DOWN, exec, ~/.config/hypr/scripts/gaps_out.sh down
|
||||||
|
binde = $mainMod SHIFT, left, exec, ~/.config/hypr/scripts/gaps_in.sh down
|
||||||
|
binde = $mainMod SHIFT, right, exec, ~/.config/hypr/scripts/gaps_in.sh up
|
||||||
|
|
50
.config/hypr/scripts/gaps_in.sh
Executable file
50
.config/hypr/scripts/gaps_in.sh
Executable file
|
@ -0,0 +1,50 @@
|
||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
# Function to get current gaps_in
|
||||||
|
get_current_gaps_in() {
|
||||||
|
hyprctl getoption general:gaps_in -j | jq -r '.custom' | awk '{print $1}'
|
||||||
|
}
|
||||||
|
|
||||||
|
# Function to set new gaps_in
|
||||||
|
set_new_gaps_in() {
|
||||||
|
hyprctl keyword general:gaps_in $1
|
||||||
|
}
|
||||||
|
|
||||||
|
# Check if an argument is provided
|
||||||
|
if [ $# -eq 0 ]; then
|
||||||
|
echo "Usage: $0 [up|down]"
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Get the current gaps_in
|
||||||
|
current_gaps=$(get_current_gaps_in)
|
||||||
|
|
||||||
|
# If current_gaps is empty or not a number, set it to 0
|
||||||
|
if ! [[ "$current_gaps" =~ ^[0-9]+$ ]] ; then
|
||||||
|
current_gaps=0
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Adjust gaps based on argument
|
||||||
|
case $1 in
|
||||||
|
"up")
|
||||||
|
new_gaps=$((current_gaps + 10))
|
||||||
|
;;
|
||||||
|
"down")
|
||||||
|
new_gaps=$((current_gaps - 10))
|
||||||
|
;;
|
||||||
|
*)
|
||||||
|
echo "Invalid argument. Use up or down"
|
||||||
|
exit 1
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
|
||||||
|
# Ensure gaps don't go negative
|
||||||
|
if [ $new_gaps -lt 0 ]; then
|
||||||
|
new_gaps=0
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Set the new gaps_in
|
||||||
|
set_new_gaps_in $new_gaps
|
||||||
|
|
||||||
|
echo "Gaps_in changed from $current_gaps to $new_gaps"
|
||||||
|
|
50
.config/hypr/scripts/gaps_out.sh
Executable file
50
.config/hypr/scripts/gaps_out.sh
Executable file
|
@ -0,0 +1,50 @@
|
||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
# Function to get current gaps_out
|
||||||
|
get_current_gaps_out() {
|
||||||
|
hyprctl getoption general:gaps_out -j | jq -r '.custom' | awk '{print $1}'
|
||||||
|
}
|
||||||
|
|
||||||
|
# Function to set new gaps_out
|
||||||
|
set_new_gaps_out() {
|
||||||
|
hyprctl keyword general:gaps_out $1
|
||||||
|
}
|
||||||
|
|
||||||
|
# Check if an argument is provided
|
||||||
|
if [ $# -eq 0 ]; then
|
||||||
|
echo "Usage: $0 [up|down]"
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Get the current gaps_out
|
||||||
|
current_gaps=$(get_current_gaps_out)
|
||||||
|
|
||||||
|
# If current_gaps is empty or not a number, set it to 0
|
||||||
|
if ! [[ "$current_gaps" =~ ^[0-9]+$ ]] ; then
|
||||||
|
current_gaps=0
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Adjust gaps based on argument
|
||||||
|
case $1 in
|
||||||
|
"up")
|
||||||
|
new_gaps=$((current_gaps + 10))
|
||||||
|
;;
|
||||||
|
"down")
|
||||||
|
new_gaps=$((current_gaps - 10))
|
||||||
|
;;
|
||||||
|
*)
|
||||||
|
echo "Invalid argument. Use up or down"
|
||||||
|
exit 1
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
|
||||||
|
# Ensure gaps don't go negative
|
||||||
|
if [ $new_gaps -lt 0 ]; then
|
||||||
|
new_gaps=0
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Set the new gaps_out
|
||||||
|
set_new_gaps_out $new_gaps
|
||||||
|
|
||||||
|
echo "Gaps_out changed from $current_gaps to $new_gaps"
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue