Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #!/bin/bash
- result="$1"
- config="$HOME/.config/rofi/config-translate.rasi"
- theme="$HOME/.config/rofi/theme-translate.rasi"
- command="/usr/local/sbin/rofi-1.6.1 -p Translate -config $config -theme $theme -dmenu"
- if [[ -n "$1" && "$1" != *"Найдено"* ]]; then
- result=$(sdcv -n -u 'LingvoUniversal (Ru-En)' "$result")
- echo -e "$result" | $command
- else
- $command -mesg "Enter a word for translation"
- fi
- exit 0
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement