mirror of
https://github.com/mintycube/dotfiles.git
synced 2024-10-22 14:05:41 +02:00
17 lines
475 B
Bash
Executable File
17 lines
475 B
Bash
Executable File
#!/bin/sh
|
||
|
||
word=$(xclip -o -selection "clipboard")
|
||
word=$(echo "$word" | sed 's/^[ \t]*//;s/[ \t]*$//')
|
||
|
||
if [ -z "$word" ]; then
|
||
notify-send "No query."
|
||
exit 1
|
||
fi
|
||
|
||
st \
|
||
-n "dictionary" \
|
||
-g 74x20+800 \
|
||
-f "JetBrainsMono Nerd Font:size=12" \
|
||
sh -c "dict -d wn \"$word\" | nvim -R -";
|
||
# sh -c "dict -d wn \"$word\" | colorit | sed -e '1,3d' -e 's/\[34;47m/[34m/g' | less -R";
|