-
Notifications
You must be signed in to change notification settings - Fork 8
Expand file tree
/
Copy pathgmb-external-tools
More file actions
executable file
·26 lines (21 loc) · 1.07 KB
/
Copy pathgmb-external-tools
File metadata and controls
executable file
·26 lines (21 loc) · 1.07 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
#! /bin/bash
dir=$(dirname "$1")
EXTERNAL_TOOLS=$(yad --center --list --no-headers --class="GMB-External-Tools" --name="GMB External Tools" --window-icon="gtk-execute" --image="gtk-execute" --text="Run a command on \"$(dirname "$dir")\"" --column="" \
"Open with Picard" "Open with Ex Falso" "Open with Easy TAG" "Open Terminal" "Add cover mp3/flac" "" \
--width=350 --height=270 --title="External Tools - GMB" --button="Close:1" --button="gtk-ok:0")
EXTERNAL_TOOLS_fix=$(sed -e "s/|//" <<< "$EXTERNAL_TOOLS")
if [[ $EXTERNAL_TOOLS_fix = "Open with Picard" ]]; then
# gmb-call-picard ermittelt den Verzeichnisnamen selbst
"$HOME/bin/gmb-call-picard" "$1"
elif [[ $EXTERNAL_TOOLS_fix = "Open with Ex Falso" ]]; then
"$HOME/bin/gmb-call-exfalso" "$1"
elif [[ $EXTERNAL_TOOLS_fix = "Open with Easy TAG" ]]; then
"$HOME/bin/gmb-call-easytag" "$1"
elif [[ $EXTERNAL_TOOLS_fix = "Open Terminal" ]]; then
"$HOME/bin/gmb-call-terminal" "$1"
elif [[ $EXTERNAL_TOOLS_fix = "Add cover mp3/flac" ]]; then
"$HOME/bin/add_cover_mp3" "$dir"; "$HOME/bin/add_cover_flac" "$dir"
else
exit
fi
exit 0