From 0f7b4712384ae7edfe2234d56fd085791327b832 Mon Sep 17 00:00:00 2001 From: Raymaekers Luca Date: Mon, 16 Oct 2023 12:04:29 +0200 Subject: removed mplay --- bin/menuscripts/mplay | 6 ------ 1 file changed, 6 deletions(-) delete mode 100755 bin/menuscripts/mplay (limited to 'bin') diff --git a/bin/menuscripts/mplay b/bin/menuscripts/mplay deleted file mode 100755 index e4fca54..0000000 --- a/bin/menuscripts/mplay +++ /dev/null @@ -1,6 +0,0 @@ -#!/bin/sh -choice="$(mpc listall | commander -c -l -d -x)" -[ "$choice" ] || exit 1 -mpc insert "$choice" || exit 1 -mpc next 2> /dev/null -mpc play 2> /dev/null -- cgit v1.2.3 From cb97cb065ebd7fa5e447a314a2421109ef9c3339 Mon Sep 17 00:00:00 2001 From: Raymaekers Luca Date: Mon, 16 Oct 2023 12:07:21 +0200 Subject: added setip --- bin/extra/setip | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) create mode 100755 bin/extra/setip (limited to 'bin') diff --git a/bin/extra/setip b/bin/extra/setip new file mode 100755 index 0000000..b10e7cc --- /dev/null +++ b/bin/extra/setip @@ -0,0 +1,16 @@ +#!/bin/sh + +ips="192.168.178.79 192.168.178.52 10.7.0.1 none" + +for ip in $ips +do ping -i .2 -c 1 "$ip" > /dev/null 2>&1 && break +done + +if [ "$ip" = "none" ] +then + >&2 printf 'No ip.\n' + exit 1 +fi + +sed -i "/Host db/,/^$/s/.*HostName.*/\tHostname $ip/" "$HOME"/.ssh/config +>&2 printf 'Done: %s \n' "$ip" -- cgit v1.2.3 From 791fe7d02cd117f12c5f1473f408ea67c5f2338e Mon Sep 17 00:00:00 2001 From: Raymaekers Luca Date: Mon, 16 Oct 2023 12:07:51 +0200 Subject: removed pomo --- bin/extra/pomo | 31 ------------------------------- 1 file changed, 31 deletions(-) delete mode 100755 bin/extra/pomo (limited to 'bin') diff --git a/bin/extra/pomo b/bin/extra/pomo deleted file mode 100755 index a2c371d..0000000 --- a/bin/extra/pomo +++ /dev/null @@ -1,31 +0,0 @@ -#!/bin/sh -notif() { notify-send -t 1000 -w "pomo" "$1"; } - -for msg in "three" "two" "one" -do notif "$msg" -done - -# $1: time in minutes -# $2: msg for notification -ring_ring() -{ - date '+%R B' - notify-send -w "$(($1*1000*60))" -u critical "pomo" "$2" -} - -i="${1-0}" -while true - -do - notif "START" - date '+%R S' - sleep 20m - if [ "$i" -eq 3 ] - then - i=0 - ring_ring 20 "GIGA BREAK TIME" - else - ring_ring 5 "BREAK TIME" - i=$((i+1)) - fi -done -- cgit v1.2.3 From 389f23521d2d43fd7a9117a47f5ba4ed92c4c389 Mon Sep 17 00:00:00 2001 From: Raymaekers Luca Date: Mon, 16 Oct 2023 12:08:15 +0200 Subject: fixed typo --- bin/common/ytclipo | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'bin') diff --git a/bin/common/ytclipo b/bin/common/ytclipo index 567e357..712b068 100755 --- a/bin/common/ytclipo +++ b/bin/common/ytclipo @@ -8,7 +8,7 @@ then paste() { termux-clipboard-get; } else paste() { xclip -o -sel c; } fi -inp=”$1” +inp="$1" [ "${inp:=$(paste)}" ] || inp="$(cat /dev/stdin)" # take last link from clipboard -- cgit v1.2.3 From cf9854013e689fa238a2deb14276e29c1a4a35f4 Mon Sep 17 00:00:00 2001 From: Raymaekers Luca Date: Mon, 16 Oct 2023 12:08:25 +0200 Subject: cleanup --- bin/extra/confirm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'bin') diff --git a/bin/extra/confirm b/bin/extra/confirm index 116b468..630d701 100755 --- a/bin/extra/confirm +++ b/bin/extra/confirm @@ -5,8 +5,8 @@ read_char () old_stty_cfg=$(stty -g 2> /dev/null) stty raw -echo 2> /dev/null dd ibs=1 count=1 2> /dev/null - stty $old_stty_cfg 2> /dev/null + stty "$old_stty_cfg" 2> /dev/null } ->&2 printf "$1 " +>&2 printf "%s " "$1" read_char | grep -q "[yY]" -- cgit v1.2.3 From 4fac003fb7d79d59e61fb0d3bcee8b38e06bdbc6 Mon Sep 17 00:00:00 2001 From: Raymaekers Luca Date: Tue, 17 Oct 2023 10:35:15 +0200 Subject: refactor and added lutris --- bin/extra/gml | 33 ++++++++++++++++++--------------- 1 file changed, 18 insertions(+), 15 deletions(-) (limited to 'bin') diff --git a/bin/extra/gml b/bin/extra/gml index 0f2f143..f8d6b7e 100755 --- a/bin/extra/gml +++ b/bin/extra/gml @@ -32,14 +32,14 @@ minecraft() -mindepth 1 -maxdepth 1 \ -type d \ -printf "%f\n" - ) | commander -d -c -s)" + ) | commander -d -c -s)" - [ -z "$world" ] && exit 1 + [ -z "$world" ] && exit 1 - if [ "$world" = 'none' ] - then setsid multimc -l "$instance" > /dev/null 2>&1 - else setsid multimc -l "$instance" -w "$world" > /dev/null 2>&1 - fi + if [ "$world" = 'none' ] + then setsid multimc -l "$instance" > /dev/null 2>&1 + else setsid multimc -l "$instance" -w "$world" > /dev/null 2>&1 + fi fi } @@ -47,24 +47,27 @@ minecraft() steam() { choice="$( - cat <<-EOF | column -t -l 2 | commander -d -x -c | awk '{printf $1}' - 274190 broforce - 291550 brawlhalla - 1712840 tiny tina - 105600 terraria - kill -EOF - )" + cat <<-EOF | + 274190 broforce + 291550 brawlhalla + 1712840 tiny tina + 105600 terraria + kill + EOF + column -t -l 2 | commander -d -x -c | awk '{printf $1}')" + case "$choice" in kill) pkill steam ;; + "") ;; *) setsid steam steam://rungameid/"$choice" ;; esac exit } eval "$( - cat <<-EOF | commander -c -w 9 -y 2 + cat <<-EOF | commander -c -w 9 -y 3 minecraft steam + lutris EOF )" -- cgit v1.2.3 From c4da89e164a9901f4a317085d83f745e235b6ea0 Mon Sep 17 00:00:00 2001 From: Raymaekers Luca Date: Tue, 17 Oct 2023 22:12:26 +0200 Subject: use eval to allow pipes --- bin/common/wt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'bin') diff --git a/bin/common/wt b/bin/common/wt index d19539b..3cd739a 100755 --- a/bin/common/wt +++ b/bin/common/wt @@ -2,6 +2,6 @@ while true do clear - $@ + eval "$*" sleep 1 done -- cgit v1.2.3 From a3aca5cf6bc7e5c3d9623e48f4c57ea4745d62dd Mon Sep 17 00:00:00 2001 From: Raymaekers Luca Date: Tue, 17 Oct 2023 23:15:47 +0200 Subject: added dwl configuration --- bin/guiscripts/startdwl | 49 +++++++++++++++++++ bin/guiscripts/startw | 2 + config/essentials/zsh/.zshrc | 8 ++-- config/hyprland/waybar/config.jsonc | 78 ------------------------------- config/hyprland/waybar/dwl.jsonc | 74 +++++++++++++++++++++++++++++ config/hyprland/waybar/hyprland.jsonc | 78 +++++++++++++++++++++++++++++++ config/hyprland/waybar/schemes/base16.css | 24 +++++++--- 7 files changed, 225 insertions(+), 88 deletions(-) create mode 100755 bin/guiscripts/startdwl delete mode 100644 config/hyprland/waybar/config.jsonc create mode 100644 config/hyprland/waybar/dwl.jsonc create mode 100644 config/hyprland/waybar/hyprland.jsonc (limited to 'bin') diff --git a/bin/guiscripts/startdwl b/bin/guiscripts/startdwl new file mode 100755 index 0000000..64b2515 --- /dev/null +++ b/bin/guiscripts/startdwl @@ -0,0 +1,49 @@ +#!/bin/sh + +eval "$(keychain --dir "$XDG_CONFIG_HOME/keychain" --eval --quiet --agents gpg,ssh)" +eval "$(keychain --dir "$XDG_CONFIG_HOME/keychain" --eval --quiet --agents gpg 3A626DD20A32EB2E5DD9CE71CFD9ABC97158CD5D 2> /dev/null)" + +export XCURSOR_THEME="Bibata-Modern-Classic" +export XCURSOR_SIZE="24" + +export GTK_THEME="Arc-Dark" + +export GTK_IM_MODULE="fcitx" +export XMODIFIERS="@im=fcitx" +export GLFW_IM_MODULE="ibus" + +export MOZ_ENABLE_WAYLAND="1" + +export QT_IM_MODULE="fcitx" +export QT_AUTO_SCREEN_SCALE_FACTOR="1" +export QT_QPA_PLATFORM="wayland;xcb" +export QT_QPA_PLATFORMTHEME="qt5ct" +export QT_WAYLAND_DISABLE_WINDOWDECORATION="1" + +export XDG_CURRENT_DESKTOP="dwl" +export XDG_SESSION_TYPE="wayland" +export XDG_SESSION_DESKTOP="dwl" + +export SDL_IM_MODULE="fcitx" +export SDL_VIDEODRIVER="wayland" +export CLUTTER_BACKEND="wayland" + +export TERMINAL="foot" +export MENUCMD="tofi" +export IMAGE="imv" + +# # nvidia +# env = LIBVA_DRIVER_NAME,nvidia +# env = XDG_SESSION_TYPE,wayland +# env = GBM_BACKEND,nvidia-drm +# env = __GLX_VENDOR_LIBRARY_NAME,nvidia +# env = WLR_NO_HARDWARE_CURSORS,1 + +(cd ~/.config/waybar/ && ln -sf dwl.jsonc config.jsonc) + +eval "$(keychain --dir "$XDG_CONFIG_HOME/keychain" --eval --quiet --agents gpg,ssh)" +eval "$(keychain --dir "$XDG_CONFIG_HOME/keychain" --eval --quiet --agents gpg 3A626DD20A32EB2E5DD9CE71CFD9ABC97158CD5D 2> /dev/null)" + +while true; +do dwl -s $HOME/.config/hypr/startup.sh +done diff --git a/bin/guiscripts/startw b/bin/guiscripts/startw index 9b35556..0383f48 100755 --- a/bin/guiscripts/startw +++ b/bin/guiscripts/startw @@ -3,4 +3,6 @@ eval "$(keychain --dir "$XDG_CONFIG_HOME/keychain" --eval --quiet --agents gpg,ssh)" eval "$(keychain --dir "$XDG_CONFIG_HOME/keychain" --eval --quiet --agents gpg 3A626DD20A32EB2E5DD9CE71CFD9ABC97158CD5D 2> /dev/null)" +(cd ~/.config/waybar/ && ln -sf hyprland.jsonc config.jsonc) + Hyprland diff --git a/config/essentials/zsh/.zshrc b/config/essentials/zsh/.zshrc index 993ae8a..e46cf8e 100644 --- a/config/essentials/zsh/.zshrc +++ b/config/essentials/zsh/.zshrc @@ -3,10 +3,10 @@ if [ "$(id -u)" -ne 0 ] then clear - case "${TTY#/dev/}" in - tty1) exec startw ;; - tty2) exec startx ;; - tty3) exec startdwl ;; + case "${TTY#/dev/tty}" in + 1) exec startw > /dev/null 2>&1 ;; + 2) exec startx > /dev/null 2>&1 ;; + 3) exec startdwl > /dev/null 2>&1 ;; *) false ;; esac && exit fi diff --git a/config/hyprland/waybar/config.jsonc b/config/hyprland/waybar/config.jsonc deleted file mode 100644 index cd24d14..0000000 --- a/config/hyprland/waybar/config.jsonc +++ /dev/null @@ -1,78 +0,0 @@ -{ - "layer": "top", - "modules-left": ["battery", "hyprland/workspaces", "mpd", "hyprland/window"], - "modules-center": ["clock"], - "modules-right": ["custom/wireguard", "network", "pulseaudio", "temperature", "cpu", "custom/memory", "custom/bluetooth", "tray"], - "mpd": { - "format": "{artist} - {title} ({elapsedTime:%M:%S}/{totalTime:%M:%S})", - "artist-len": 24, - "format-disconnected": "s", - "format-stopped": "", - "state-icons": { - "playing": "", - "paused": "", - }, - "tooltip-format": "{songPosition}/{queueLength} ({volume}%)", - "on-click": "mpc toggle", - "on-scroll-up": "mpc volume +5", - "on-scroll-down": "mpc volume -5", - }, - "battery": { - "format-charging": " {capacity}%", - "on-click": "mpower", - "interval": 10, - }, - "hyprland/window": { - "format": "{}", - "separate-outputs": true, - }, - "pulseaudio": { - "scroll-step": 1, - "format": "{icon} {volume:3}%", - "format-icons": { - "default": ["", "", ""] - }, - "on-click": "pavucontrol", - }, - "temperature": { - "interval": 3, - "format": "{icon} {temperatureC}°C", - "format-icons": { - "default":["", "", "", "", ""] - }, - }, - "custom/wireguard": { - "exec": "ip addr show dev wg0", - "format": "wg0", - "restart-interval": 3, - }, - "network": { - "format-wifi": " ", - "tooltip-format-wifi": "{ifname} {essid}", - "format-ethernet": "", - "tooltip-format-ethernet": "{ifname} {ipaddr}", - "format-disconnected": "", - }, - "cpu": { - "format": " {usage:2}%", - "interval": 3, - }, - "custom/memory": { - "exec": "free -h | awk '(NR==2){ print $3 }'", - "format": "{}", - "restart-interval": 3, - }, - "clock": { - "format": "{:%R}", - "format-alt": "{:(%T) %A %d %B}", - "interval": 1, - }, - "custom/bluetooth": { - "exec": "bluetoothctl info", - "format": "", - "interval": 3, - }, - "tray": { - "spacing": 5, - } -} diff --git a/config/hyprland/waybar/dwl.jsonc b/config/hyprland/waybar/dwl.jsonc new file mode 100644 index 0000000..9d65564 --- /dev/null +++ b/config/hyprland/waybar/dwl.jsonc @@ -0,0 +1,74 @@ +{ + "layer": "top", + "modules-left": ["battery", "dwl/tags", "mpd"], + "modules-center": ["clock"], + "modules-right": ["custom/wireguard", "network", "pulseaudio", "temperature", "cpu", "custom/memory", "custom/bluetooth", "tray"], + "mpd": { + "format": "{artist} - {title} ({elapsedTime:%M:%S}/{totalTime:%M:%S})", + "artist-len": 24, + "format-disconnected": "s", + "format-stopped": "", + "state-icons": { + "playing": "", + "paused": "", + }, + "tooltip-format": "{songPosition}/{queueLength} ({volume}%)", + "on-click": "mpc toggle", + "on-scroll-up": "mpc volume +5", + "on-scroll-down": "mpc volume -5", + }, + "battery": { + "format-charging": " {capacity}%", + "on-click": "mpower", + "interval": 10, + }, + "pulseaudio": { + "scroll-step": 1, + "format": "{icon} {volume:3}%", + "format-icons": { + "default": ["", "", ""] + }, + "on-click": "pavucontrol", + }, + "temperature": { + "interval": 3, + "format": "{icon} {temperatureC}°C", + "format-icons": { + "default":["", "", "", "", ""] + }, + }, + "custom/wireguard": { + "exec": "ip addr show dev wg0", + "format": "wg0", + "restart-interval": 3, + }, + "network": { + "format-wifi": " ", + "tooltip-format-wifi": "{ifname} {essid}", + "format-ethernet": "", + "tooltip-format-ethernet": "{ifname} {ipaddr}", + "format-disconnected": "", + }, + "cpu": { + "format": " {usage:2}%", + "interval": 3, + }, + "custom/memory": { + "exec": "free -h | awk '(NR==2){ print $3 }'", + "format": "{}", + "restart-interval": 3, + }, + "clock": { + "format": "{:%R}", + "format-alt": "{:(%T) %A %d %B}", + "interval": 1, + }, + "custom/bluetooth": { + "exec": "bluetoothctl info", + "format": "", + "interval": 3, + }, + "tray": { + "spacing": 5, + } +} diff --git a/config/hyprland/waybar/hyprland.jsonc b/config/hyprland/waybar/hyprland.jsonc new file mode 100644 index 0000000..cd24d14 --- /dev/null +++ b/config/hyprland/waybar/hyprland.jsonc @@ -0,0 +1,78 @@ +{ + "layer": "top", + "modules-left": ["battery", "hyprland/workspaces", "mpd", "hyprland/window"], + "modules-center": ["clock"], + "modules-right": ["custom/wireguard", "network", "pulseaudio", "temperature", "cpu", "custom/memory", "custom/bluetooth", "tray"], + "mpd": { + "format": "{artist} - {title} ({elapsedTime:%M:%S}/{totalTime:%M:%S})", + "artist-len": 24, + "format-disconnected": "s", + "format-stopped": "", + "state-icons": { + "playing": "", + "paused": "", + }, + "tooltip-format": "{songPosition}/{queueLength} ({volume}%)", + "on-click": "mpc toggle", + "on-scroll-up": "mpc volume +5", + "on-scroll-down": "mpc volume -5", + }, + "battery": { + "format-charging": " {capacity}%", + "on-click": "mpower", + "interval": 10, + }, + "hyprland/window": { + "format": "{}", + "separate-outputs": true, + }, + "pulseaudio": { + "scroll-step": 1, + "format": "{icon} {volume:3}%", + "format-icons": { + "default": ["", "", ""] + }, + "on-click": "pavucontrol", + }, + "temperature": { + "interval": 3, + "format": "{icon} {temperatureC}°C", + "format-icons": { + "default":["", "", "", "", ""] + }, + }, + "custom/wireguard": { + "exec": "ip addr show dev wg0", + "format": "wg0", + "restart-interval": 3, + }, + "network": { + "format-wifi": " ", + "tooltip-format-wifi": "{ifname} {essid}", + "format-ethernet": "", + "tooltip-format-ethernet": "{ifname} {ipaddr}", + "format-disconnected": "", + }, + "cpu": { + "format": " {usage:2}%", + "interval": 3, + }, + "custom/memory": { + "exec": "free -h | awk '(NR==2){ print $3 }'", + "format": "{}", + "restart-interval": 3, + }, + "clock": { + "format": "{:%R}", + "format-alt": "{:(%T) %A %d %B}", + "interval": 1, + }, + "custom/bluetooth": { + "exec": "bluetoothctl info", + "format": "", + "interval": 3, + }, + "tray": { + "spacing": 5, + } +} diff --git a/config/hyprland/waybar/schemes/base16.css b/config/hyprland/waybar/schemes/base16.css index 61696d0..35737b4 100644 --- a/config/hyprland/waybar/schemes/base16.css +++ b/config/hyprland/waybar/schemes/base16.css @@ -54,7 +54,7 @@ window#waybar.PCSX2 #window { margin-left: 3px; } -#workspaces, #mpd, #battery, +#workspaces, #tags, #mpd, #battery, #clock, #custom-wireguard, #network, #pulseaudio, #temperature, #cpu, #custom-memory, #custom-bluetooth, #tray { border: solid @background; @@ -73,26 +73,38 @@ window#waybar.PCSX2 #window { margin-right: 16px; } -#workspaces { +#workspaces, #tags { border: solid @background 2px; background: @color3; } -#workspaces button { +#workspaces button, #tags button { transition: none; background: transparent; color: @background; } -#workspaces button.active { - text-shadow: 0px 1px 0px @color1; +#tags button.occupied { + background: @color2; } -#workspaces button:hover { +#workspaces button.active, #tags button.focused { + background-color: @color6; + border-bottom: 6px solid @color4; + +} + +#workspaces button:hover, #tags button:hover { transition: none; color: @color8; } +#tags button { + margin: 0; + padding-left: 5px; + padding-right: 5px; +} + #mpd { color: @background; padding: 0 16px; -- cgit v1.2.3 From 6d4e211f9b45adf939c6e52fe4811e1385c7e8a2 Mon Sep 17 00:00:00 2001 From: Raymaekers Luca Date: Tue, 17 Oct 2023 23:19:32 +0200 Subject: renamed mpassgen to mpwgen --- bin/menuscripts/mpassgen | 23 ----------------------- bin/menuscripts/mpwgen | 23 +++++++++++++++++++++++ config/hyprland/hypr/binds.conf | 4 ++-- 3 files changed, 25 insertions(+), 25 deletions(-) delete mode 100755 bin/menuscripts/mpassgen create mode 100755 bin/menuscripts/mpwgen (limited to 'bin') diff --git a/bin/menuscripts/mpassgen b/bin/menuscripts/mpassgen deleted file mode 100755 index 51b9bc4..0000000 --- a/bin/menuscripts/mpassgen +++ /dev/null @@ -1,23 +0,0 @@ -#!/usr/bin/env sh - -input () { commander -c -i -p "$1"; } - -choice="$(printf "multiline\nsingle\n" | commander -c -d)" -[ "$choice" ] || exit 1 - -password="$(input "name:")" -[ "$password" ] || exit 1 - -if [ "$choice" = "multiline" ] -then - login="$(find "${PASSWORD_STORE_DIR:=$HOME/.password-store}"/e-mails -type f -maxdepth 1 -iname "*.gpg" -printf "%f\n" | - sed 's/\.gpg$//' | commander -c -d -p 'login:')" - [ "$login" ] || exit 1 - url="$(input "url:")" - [ "$url" ] || exit 1 - printf "%s\nlogin: %s\nurl: %s\n" "${password}" "${login}" "${url}" | - pass insert -mf "${password}" - pass generate -ci "${password}" -else - pass generate -cf "${password}" -fi diff --git a/bin/menuscripts/mpwgen b/bin/menuscripts/mpwgen new file mode 100755 index 0000000..51b9bc4 --- /dev/null +++ b/bin/menuscripts/mpwgen @@ -0,0 +1,23 @@ +#!/usr/bin/env sh + +input () { commander -c -i -p "$1"; } + +choice="$(printf "multiline\nsingle\n" | commander -c -d)" +[ "$choice" ] || exit 1 + +password="$(input "name:")" +[ "$password" ] || exit 1 + +if [ "$choice" = "multiline" ] +then + login="$(find "${PASSWORD_STORE_DIR:=$HOME/.password-store}"/e-mails -type f -maxdepth 1 -iname "*.gpg" -printf "%f\n" | + sed 's/\.gpg$//' | commander -c -d -p 'login:')" + [ "$login" ] || exit 1 + url="$(input "url:")" + [ "$url" ] || exit 1 + printf "%s\nlogin: %s\nurl: %s\n" "${password}" "${login}" "${url}" | + pass insert -mf "${password}" + pass generate -ci "${password}" +else + pass generate -cf "${password}" +fi diff --git a/config/hyprland/hypr/binds.conf b/config/hyprland/hypr/binds.conf index 406c7ba..75b0d14 100644 --- a/config/hyprland/hypr/binds.conf +++ b/config/hyprland/hypr/binds.conf @@ -103,8 +103,8 @@ bind = $mainMod, E, exec, memoji bind =, E, exec, memoji bind = $mainMod, F, exec, dmfm bind =, F, exec, dmfm -bind = $mainMod, G, exec, mpassgen -bind =, G, exec, mpassgen +bind = $mainMod, G, exec, mpwgen +bind =, G, exec, mpwgen bind = $mainMod, H, exec, mhelp bind =, H, exec, mhelp bind = $mainMod, I, exec, mapimg -- cgit v1.2.3 From ab885c9cab1fbb7ee63a0f3a9dc23d4d843d334c Mon Sep 17 00:00:00 2001 From: Raymaekers Luca Date: Wed, 18 Oct 2023 19:01:02 +0200 Subject: use desktop agnostic way to get monitors --- bin/guiscripts/locker | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) (limited to 'bin') diff --git a/bin/guiscripts/locker b/bin/guiscripts/locker index 7c42cda..a0a9eac 100755 --- a/bin/guiscripts/locker +++ b/bin/guiscripts/locker @@ -1,9 +1,8 @@ #!/bin/sh -which swaylock grim pixelate > /dev/null || - exit 1 +which swaylock grim pixelate > /dev/null || exit 1 umask 077 -monitors="$(hyprctl monitors -j | jq -r '.[].name' | xargs)" +monitors="$(xrandr --listactivemonitors | awk '/^ [0-9]/ {print $4}')" for monitor in $monitors do @@ -15,5 +14,5 @@ do files="$files $file" done -swaylock -f -u $img_opt +swaylock --indicator-radius 0 $img_opt shred -uz -- $files -- cgit v1.2.3 From 6e4cec018d845664b077a7b5df8ef1234e35ddfc Mon Sep 17 00:00:00 2001 From: Raymaekers Luca Date: Wed, 18 Oct 2023 19:01:47 +0200 Subject: use dwl specific config --- bin/guiscripts/startdwl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'bin') diff --git a/bin/guiscripts/startdwl b/bin/guiscripts/startdwl index 64b2515..8681eaf 100755 --- a/bin/guiscripts/startdwl +++ b/bin/guiscripts/startdwl @@ -45,5 +45,5 @@ eval "$(keychain --dir "$XDG_CONFIG_HOME/keychain" --eval --quiet --agents gpg,s eval "$(keychain --dir "$XDG_CONFIG_HOME/keychain" --eval --quiet --agents gpg 3A626DD20A32EB2E5DD9CE71CFD9ABC97158CD5D 2> /dev/null)" while true; -do dwl -s $HOME/.config/hypr/startup.sh +do dwl -s $HOME/.config/dwl/startup.sh done -- cgit v1.2.3 From 1f206fe858761b72307d3b71ef444be304c10cd1 Mon Sep 17 00:00:00 2001 From: Raymaekers Luca Date: Wed, 18 Oct 2023 19:08:50 +0200 Subject: cleanup --- bin/guiscripts/startdwl | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) (limited to 'bin') diff --git a/bin/guiscripts/startdwl b/bin/guiscripts/startdwl index 8681eaf..bb5fec0 100755 --- a/bin/guiscripts/startdwl +++ b/bin/guiscripts/startdwl @@ -39,11 +39,6 @@ export IMAGE="imv" # env = __GLX_VENDOR_LIBRARY_NAME,nvidia # env = WLR_NO_HARDWARE_CURSORS,1 -(cd ~/.config/waybar/ && ln -sf dwl.jsonc config.jsonc) - -eval "$(keychain --dir "$XDG_CONFIG_HOME/keychain" --eval --quiet --agents gpg,ssh)" -eval "$(keychain --dir "$XDG_CONFIG_HOME/keychain" --eval --quiet --agents gpg 3A626DD20A32EB2E5DD9CE71CFD9ABC97158CD5D 2> /dev/null)" - while true; -do dwl -s $HOME/.config/dwl/startup.sh +do dwl -s "$HOME"/.config/dwl/startup.sh done -- cgit v1.2.3 From 067b07eb24262b34c00fe7be786cbdcfcd6383c6 Mon Sep 17 00:00:00 2001 From: Raymaekers Luca Date: Thu, 19 Oct 2023 11:22:31 +0200 Subject: refactor --- bin/guiscripts/dmfm | 28 +++++++++++++++------------- bin/menuscripts/mhelp | 6 +++--- 2 files changed, 18 insertions(+), 16 deletions(-) (limited to 'bin') diff --git a/bin/guiscripts/dmfm b/bin/guiscripts/dmfm index 969c111..d1dd8b8 100755 --- a/bin/guiscripts/dmfm +++ b/bin/guiscripts/dmfm @@ -1,17 +1,19 @@ #!/bin/sh -file=1 -while [ "$file" ]; do - file=$(ls -1 --group-directories-first | dmenu -i -l 8 -g 1 -p "$(basename $(pwd)):") - if [ -e "$file" ]; then - owd=$(pwd) - if [ -d "$file" ]; then - cd "$file" - else [ -f "$file" ] - if which xdg-open &> /dev/null; then - exec xdg-open "$owd/$file" & - unset file - fi - fi +while true +do + file=$(find . -maxdepth 1 -mindepth 1 -not -name '.*' -printf '%y\t%f\n' | + sort -k 1 -k 2 | cut -f 2- | + commander -xcd -p "$PWD>") + + [ "$file" ] || break + [ ! -e "$file" ] && continue + + if [ -d "$file" ] + then + cd "$file" || continue + else + setsid xdg-open "$PWD/$file" & fi + done diff --git a/bin/menuscripts/mhelp b/bin/menuscripts/mhelp index 339d6bf..cb7977b 100755 --- a/bin/menuscripts/mhelp +++ b/bin/menuscripts/mhelp @@ -1,16 +1,16 @@ #!/usr/bin/env sh -program="$(commander -r -c -d)" +program="$(commander -rcd)" [ "$program" ] || exit 1 option="$("$program" --help | # Parse options - grep "^ *-[-a-zA-Z0-9]* " | + grep -- "^ *-[-a-zA-Z0-9]* " | tr -s ' ' | sort | uniq | column -l 2 -t | - commander -l -x -c -d | + commander -lxcd | awk '{print $1}')" [ "$option" ] || exit 1 -- cgit v1.2.3