2024-06-08 09:14:08 +05:00
|
|
|
|
#!/bin/sh
|
2024-04-30 17:50:22 +05:00
|
|
|
|
|
|
|
|
|
word=$(xclip -o -selection "clipboard")
|
2024-06-13 15:04:48 +05:00
|
|
|
|
word=$(echo "$word" | sed 's/^[ \t]*//;s/[ \t]*$//')
|
2024-04-30 17:50:22 +05:00
|
|
|
|
|
|
|
|
|
if [ -z "$word" ]; then
|
|
|
|
|
notify-send "No query."
|
|
|
|
|
exit 1
|
|
|
|
|
fi
|
|
|
|
|
|
|
|
|
|
st \
|
|
|
|
|
-n "dictionary" \
|
|
|
|
|
-g 74x20+800 \
|
2024-09-03 10:45:41 +05:00
|
|
|
|
-f "JetBrainsMono Nerd Font:size=10" \
|
|
|
|
|
sh -c "dict -d wn \"$word\" | nvim --clean +'source ~/.local/share/script-data/init.lua' -R -";
|
2024-07-15 16:28:23 +05:00
|
|
|
|
# sh -c "dict -d wn \"$word\" | colorit | sed -e '1,3d' -e 's/\[34;47m/[34m/g' | less -R";
|