From fc1e2879ac9facd177fcbe714d78f9eacbfd75c6 Mon Sep 17 00:00:00 2001 From: zachir Date: Sat, 1 Oct 2022 22:21:29 -0500 Subject: tagmp3 also tag flac files --- tagmp3 | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'tagmp3') diff --git a/tagmp3 b/tagmp3 index 6ecb6f8..baed43f 100755 --- a/tagmp3 +++ b/tagmp3 @@ -36,6 +36,8 @@ ARTISTNAME=`echo $ARTISTNAME | sed 's/^ //'` ALBUMNAME=`echo $ALBUMNAME | sed 's/^ //'` SONGNAME=`echo $SONGNAME | sed 's/^ //'` +echo "\n$FILENAME\n" + # guess artist name from title ARTISTNAME_GUESS=`echo "$FILENAME" | cut -d'-' -f1 | sed 's/_*$//;s/_/ /g'` @@ -46,7 +48,7 @@ ALBUMNAME_GUESS=`echo "$FILENAME" | cut -d'-' -f2 | sed 's/^_*//;s/_*$//;s/_/ /g TRACKNUMBER_GUESS=`echo "$FILENAME" | cut -d'-' -f3 | cut -d'_' -f2` # guess song name from title -SONGNAME_GUESS=`echo "$FILENAME" | cut -d'-' -f3 | sed 's/^_[0-9]*_//;s/_/ /g;s/\.mp3$//'` +SONGNAME_GUESS=`echo "$FILENAME" | cut -d'-' -f3 | sed 's/^_[0-9]*_//;s/_/ /g;s/\.mp3$//;s/\.flac$//'` # get the artist name input [ -z "$ARTISTNAME" ] && echo "Input the Artist name:\nGuessed name is $ARTISTNAME_GUESS" && read ARTISTNAME -- cgit v1.2.3