From 842951379af23646070317bc23b6803869da41ca Mon Sep 17 00:00:00 2001 From: dogeystamp Date: Sat, 27 Jul 2024 15:23:05 -0400 Subject: [PATCH] clipedit.sh: use alacritty --- src/.local/bin/deskutils/clipedit.sh | 18 +++++++++++++----- 1 file changed, 13 insertions(+), 5 deletions(-) diff --git a/src/.local/bin/deskutils/clipedit.sh b/src/.local/bin/deskutils/clipedit.sh index f00d6f6..82754dd 100755 --- a/src/.local/bin/deskutils/clipedit.sh +++ b/src/.local/bin/deskutils/clipedit.sh @@ -3,8 +3,16 @@ TMPFILE="$(mktemp)" -#xsel -b > "$TMPFILE" -st -g 60x8+0+800 -c popup-bottom-center \ - -e nvim -c "set binary noeol" -c "startinsert" "$TMPFILE" -c "highlight Normal ctermbg=016" -cat "$TMPFILE" | xsel -ib -rm "$TMPFILE" +xsel -b > "$TMPFILE" + +newterm() { + alacritty msg create-window "$@" || + alacritty "$@" +} + +newterm \ + -o 'window.class = { instance = "popup-bottom-center", general="popup-bottom-center" }' \ + -o 'window.opacity = 1.0' \ + -o 'window.dimensions = { columns = 84, lines = 10 }' \ + -o 'window.position = { x = 0, y = 1200 }' \ + -e sh -c "xsel -b > '$TMPFILE'; nvim -c 'set binary noeol textwidth=80' '$TMPFILE' && cat '$TMPFILE' | xsel -ib && rm '$TMPFILE'"