From a98ae6bd5a1c7e2d278c5df2b927c0a5427141d0 Mon Sep 17 00:00:00 2001 From: Raymaekers Luca Date: Tue, 31 Oct 2023 14:31:32 +0100 Subject: turn aliases into scripts This allows for better integration, and makes it possible to call these from other programs, such as window managers, ... --- bin/guiscripts/clipo | 4 ++++ bin/guiscripts/clipp | 4 ++++ config/essentials/zsh/aliases.sh | 9 ++------- 3 files changed, 10 insertions(+), 7 deletions(-) create mode 100755 bin/guiscripts/clipo create mode 100755 bin/guiscripts/clipp diff --git a/bin/guiscripts/clipo b/bin/guiscripts/clipo new file mode 100755 index 0000000..e3ae714 --- /dev/null +++ b/bin/guiscripts/clipo @@ -0,0 +1,4 @@ +#!/bin/sh +[ "$WAYLAND_DISPLAY" ] && + wl-paste -n || + xclip -o -selection clipboard -r diff --git a/bin/guiscripts/clipp b/bin/guiscripts/clipp new file mode 100755 index 0000000..538f69b --- /dev/null +++ b/bin/guiscripts/clipp @@ -0,0 +1,4 @@ +#!/bin/sh +[ "$WAYLAND_DISPLAY" ] && + wl-copy -n || + xclip -selection clipboard -r diff --git a/config/essentials/zsh/aliases.sh b/config/essentials/zsh/aliases.sh index e9c7e2f..575502c 100644 --- a/config/essentials/zsh/aliases.sh +++ b/config/essentials/zsh/aliases.sh @@ -17,18 +17,13 @@ then alias calc='bc <<<' - if [ "$WAYLAND_DISPLAY" ] - then - alias -g clipp='wl-copy -n' - alias -g clipo='wl-paste -n' - else + if [ -z "$WAYLAND_DISPLAY" ] + then if which devour > /dev/null 2>&1 then alias mpv='devour mpv' alias zathura='devour zathura' fi - alias -g clipp='xclip -selection clipboard -r' - alias -g clipo='xclip -o -selection clipboard -r' fi alias clipic='clipo > /tmp/pic.png' -- cgit v1.2.3 From d99323430cf89e6566899483419f99453140c665 Mon Sep 17 00:00:00 2001 From: Raymaekers Luca Date: Tue, 31 Oct 2023 14:34:37 +0100 Subject: make help more generic --- bin/extra/supd | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/extra/supd b/bin/extra/supd index 48638bd..e8eacd4 100755 --- a/bin/extra/supd +++ b/bin/extra/supd @@ -7,7 +7,7 @@ then >&2 cat <<-EOF usage: supd Update dirs in current dir - ls ~/projects | supd Update dirs read from stdin + ... | supd Update dirs read from stdin supd -h Show help EOF exit -- cgit v1.2.3 From e79d30ae56260aadeab037f9c52c5c329153bf08 Mon Sep 17 00:00:00 2001 From: Raymaekers Luca Date: Tue, 31 Oct 2023 17:26:41 +0100 Subject: added sound on gurk notifications --- config/wayland/mako/config | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/config/wayland/mako/config b/config/wayland/mako/config index 2df4b1d..4380506 100644 --- a/config/wayland/mako/config +++ b/config/wayland/mako/config @@ -23,3 +23,7 @@ default-timeout=0 [category=mpd] default-timeout=2000 group-by=category + +[app-name=gurk] +# 45887 = 70% +on-notify=exec paplay --volume=45887 ~/.local/share/sounds/ring1.ogg -- cgit v1.2.3 From af6487bdb195c61574fa353e3bdd5bfe54b2073b Mon Sep 17 00:00:00 2001 From: Raymaekers Luca Date: Tue, 31 Oct 2023 17:31:52 +0100 Subject: cleanup --- bin/menuscripts/memoji | 17 +++-------------- 1 file changed, 3 insertions(+), 14 deletions(-) diff --git a/bin/menuscripts/memoji b/bin/menuscripts/memoji index 9c45950..b957981 100755 --- a/bin/menuscripts/memoji +++ b/bin/menuscripts/memoji @@ -5,30 +5,19 @@ # If this file includes emojis below "__DATA__" it is generated. # This file was generated: 2022-04-21 12:38:03+00:00 -if [ "$WAYLAND_DISPLAY" ] -then - alias copycmd="wl-copy" -else - alias copycmd="xclip -sel c" -fi set -e case "$1" in - "list") - data=$(sed '0,/^__DATA__$/d' "$0") - printf "%s" "$data" - ;; + "list") printf "%s" "$(sed '0,/^__DATA__$/d' "$0")" ;; "copy") input=$(tee | cut -f 1 -d ' ') if [ "$input" ] then notify-send "dmemoji" "$input copied!" - printf "%s" "$input" | copycmd + printf "%s" "$input" | clipp fi ;; - "") - sh "$0" list | commander -p "Emoji:" -l -x | sh "$0" copy - ;; + "") sh "$0" list | commander -p "Emoji:" -l -x | sh "$0" copy ;; esac exit -- cgit v1.2.3 From c7e869a7a13d43ef98821c2aa63310b3578146e7 Mon Sep 17 00:00:00 2001 From: Raymaekers Luca Date: Tue, 31 Oct 2023 17:32:07 +0100 Subject: reset duckduckgo to searchengine --- config/extra/tridactyl/tridactylrc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/config/extra/tridactyl/tridactylrc b/config/extra/tridactyl/tridactylrc index d9cab9e..977578b 100644 --- a/config/extra/tridactyl/tridactylrc +++ b/config/extra/tridactyl/tridactylrc @@ -1,5 +1,5 @@ set newtab http://localhost:28669 -set searchengine qwant +set searchengine duckduckgo " Searchurls set searchurls.1x https://www.1377x.to/search/%s/1 -- cgit v1.2.3 From c3e98662e367049d32a9a27805c620c178be603d Mon Sep 17 00:00:00 2001 From: Raymaekers Luca Date: Tue, 31 Oct 2023 17:32:29 +0100 Subject: added plantuml support with plugin --- config/essentials/nvim/after/plugin/plantuml.lua | 10 ++++++++++ config/essentials/nvim/lua/user/packer.lua | 21 ++++++++++++++------- 2 files changed, 24 insertions(+), 7 deletions(-) create mode 100644 config/essentials/nvim/after/plugin/plantuml.lua diff --git a/config/essentials/nvim/after/plugin/plantuml.lua b/config/essentials/nvim/after/plugin/plantuml.lua new file mode 100644 index 0000000..da14862 --- /dev/null +++ b/config/essentials/nvim/after/plugin/plantuml.lua @@ -0,0 +1,10 @@ +require('plantuml').setup +{ + renderer = { + type = 'text', + options = { + split_cmd = 'split', -- Allowed values: `split`, `vsplit`. + } + }, + render_on_write = true, -- Set to false to disable auto-rendering. +} diff --git a/config/essentials/nvim/lua/user/packer.lua b/config/essentials/nvim/lua/user/packer.lua index 36f9ec0..ed2bbf1 100644 --- a/config/essentials/nvim/lua/user/packer.lua +++ b/config/essentials/nvim/lua/user/packer.lua @@ -45,13 +45,20 @@ return require('packer').startup(function(use) use('christoomey/vim-tmux-navigator') - -- utils - use('godlygeek/tabular') - use('renerocksai/calendar-vim') - use('ojroques/vim-oscyank', {branch = "main"}) - use("potamides/pantran.nvim") - use('alx741/vinfo') - -- use('github/copilot.vim') + -- utils + use('godlygeek/tabular') + use('renerocksai/calendar-vim') + use('ojroques/vim-oscyank', {branch = "main"}) + use("potamides/pantran.nvim") + use('alx741/vinfo') + use('sheerun/vim-polyglot') + -- use('github/copilot.vim') + -- + use { + 'https://gitlab.com/itaranto/plantuml.nvim', + tag = '*', + config = function() require('plantuml').setup() end + } -- objects use('michaeljsmith/vim-indent-object') -- cgit v1.2.3 From cfb3aed2b81be807d385845cf0807d99dc0d1ac4 Mon Sep 17 00:00:00 2001 From: Raymaekers Luca Date: Tue, 31 Oct 2023 17:35:38 +0100 Subject: use width and height parameters instead of list --- bin/menuscripts/memoji | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/menuscripts/memoji b/bin/menuscripts/memoji index b957981..45a74f1 100755 --- a/bin/menuscripts/memoji +++ b/bin/menuscripts/memoji @@ -17,7 +17,7 @@ case "$1" in printf "%s" "$input" | clipp fi ;; - "") sh "$0" list | commander -p "Emoji:" -l -x | sh "$0" copy ;; + "") sh "$0" list | commander -p "Emoji:" -x -w 44 -y 10 -c | sh "$0" copy ;; esac exit -- cgit v1.2.3 From 442fdac531a6b042a396eafc096811e46bc063ca Mon Sep 17 00:00:00 2001 From: Raymaekers Luca Date: Tue, 31 Oct 2023 17:38:44 +0100 Subject: check if git dir before doing anything --- bin/extra/supd | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/bin/extra/supd b/bin/extra/supd index e8eacd4..61ea144 100755 --- a/bin/extra/supd +++ b/bin/extra/supd @@ -17,9 +17,10 @@ fi for dir in $dirs do - printf '%s:' "$dir" | >&2 sed "s#$HOME#~#" ( cd "$dir" || return + git rev-parse > /dev/null 2>&1 || return + printf '%s:' "$dir" | >&2 sed "s#$HOME#~#" git "${1:-fetch}" > /dev/null 2>&1 && printf ' o' || printf ' x' -- cgit v1.2.3