diff options
author | Rasmus Steinke <rasi@xssn.at> | 2014-08-03 22:26:00 +0200 |
---|---|---|
committer | Rasmus Steinke <rasi@xssn.at> | 2014-08-03 22:26:00 +0200 |
commit | edb18056d69dc04595c3041829b9b167a657a59a (patch) | |
tree | 3a990e232dd6c9e74881e341efbf1533b48e49c4 /clerk | |
parent | d27c0f1170fdd67eb7bcdbb1c178926e71d03f72 (diff) | |
download | perl-app-clerk-edb18056d69dc04595c3041829b9b167a657a59a.tar.gz perl-app-clerk-edb18056d69dc04595c3041829b9b167a657a59a.tar.xz |
made flat mode available for all add arguments
Diffstat (limited to 'clerk')
-rwxr-xr-x | clerk | 36 |
1 files changed, 18 insertions, 18 deletions
@@ -588,7 +588,7 @@ playRandomTracks () { } -AddAlbum() { +AddAlbumTags() { declare -i seen=0 while read TRACK do @@ -597,7 +597,7 @@ AddAlbum() { then dplayPrompt else if [[ "$TRACK" == "Adding Mode: Add" ]] - then InsertAlbum + then InsertAlbumTags else artist=$(echo "$TRACK" | awk -F " $seperator " '{print $1}') date=$(echo "$TRACK" | awk -F " $seperator " '{print $3}') @@ -614,14 +614,14 @@ AddAlbum() { } -InsertAlbum() { +InsertAlbumTags() { while read TRACK do if [[ "$TRACK" = "0 Return to Main Menu" ]] then dplayPrompt else if [[ "$TRACK" == "Adding Mode: Insert" ]] - then ReplaceAlbum + then ReplaceAlbumTags else artist=$(echo "$TRACK" | awk -F " $seperator " '{print $1}') date=$(echo "$TRACK" | awk -F " $seperator " '{print $3}') @@ -632,7 +632,7 @@ InsertAlbum() { done < <(echo -e "0 Return to Main Menu\n---\nAdding Mode: Insert\n---\n$(echo "$album_temp")" | dmenu_t -dmenu -p "Choose Album > ") } -ReplaceAlbum() { +ReplaceAlbumTags() { declare -i seen=0 while read TRACK do @@ -708,7 +708,7 @@ ReplaceAlbumFlat () { dplayPrompt else if [[ "$TRACK" == "Adding Mode: Flat Replace" ]]; then - AddAlbum + AddAlbumTags else mpc clear && mpc findadd album "$TRACK" && mpc play fi @@ -722,14 +722,14 @@ ReplaceAlbumFlat () { -AddTrack() { +AddTrackTags() { while read TRACK do if [[ "$TRACK" == "0 Return to Main Menu" ]] then dplayPrompt else if [[ "$TRACK" == "Adding Mode: Add" ]] - then InsertTrack + then InsertTrackTags else artist=$(echo "$TRACK" | awk -F " $seperator " '{print $1}') album=$(echo "$TRACK" | awk -F " $seperator " '{print $4}') @@ -741,14 +741,14 @@ AddTrack() { done < <(echo -e "0 Return to Main Menu\n---\nAdding Mode: Add\n---\n$(echo "$tracks_temp")"| dmenu_t -dmenu -p "Choose Track > ") } -InsertTrack() { +InsertTrackTags() { while read TRACK do if [[ "$TRACK" == "0 Return to Main Menu" ]] then dplayPrompt else if [[ "$TRACK" == "Adding Mode: Insert" ]] - then AddTrack + then AddTrackFlat else artist=$(echo "$TRACK" | awk -F " $seperator " '{print $1}') album=$(echo "$TRACK" | awk -F " $seperator " '{print $4}') @@ -790,7 +790,7 @@ InsertTrackFlat() { then dplayPrompt else if [[ "$TRACK" == "Adding Mode: Insert Flat" ]] - then AddAlbum + then AddAlbumTags else mpc insert "$TRACK" fi @@ -911,8 +911,8 @@ browseLibPrompt() { case "$(prompt "${menu[@]}")" in 1*) browseArtist ;; 2*) browseDate ;; - 3*) $AddAlbum ;; - 4*) $AddTrack ;; + 3*) AddAlbum$quirkAlbum ;; + 4*) AddTrack$quirkTrack ;; 5*) updateCache && browseLibPrompt ;; 0*) dplayPrompt ;; *) exit @@ -1054,15 +1054,15 @@ if [[ "$1" == "-h" ]]; then elif [[ "$1" == "-a" ]]; then - $AddAlbum + AddAlbum$quirkAlbum elif [[ "$1" == "-ai" ]]; then - InsertAlbum + InsertAlbum$quirkAlbum elif [[ "$1" == "-ar" ]]; then - ReplaceAlbum + ReplaceAlbum$quirkAlbum elif [[ "$1" == "-t" ]]; then - $AddTrack + AddTrack$quirkTrack elif [[ "$1" == "-ti" ]]; then - InsertTrack + InsertTrack$quirkTrack elif [[ "$1" == "-ralbum" ]]; then rateAlbum elif [[ "$1" == "-rate" ]]; then |