Pa-software community
Help, support and conversation
Welcome! ( login | register )
 
  Forum » ID3 Editor » MP3 file problems » Bash shell script?
 

Pages: << prev 1 next >>
Bash shell script?
This member is currently offline kds
Newbie


Member Level

Group: Members
Posts: 2
Joined: May 2, 2016

Add kds to your buddy list Send an email to kds Reply with a quote from this post Go to the top of the page

I am thinking that I would like to use the command line interface in a Bash shell script on a Macintosh. Is this possible? If so, what would the proper command be? (/Users/kds/Desktop/MyRecordings/Song1.mp3) I can do it through Terminal but am stuck with the shell scripting aspect.

Posted May 2, 2016, 5:04 pm
This member is currently offline jamesrae
Member


Member Level

Group: Moderators
Posts: 63
Joined: Dec 13, 2008

Add jamesrae to your buddy list Send an email to jamesrae Send a personal messsage to jamesrae Reply with a quote from this post Go to the top of the page

If you have installed the CLI rather than copying it (it is installed in /usr/local/bin), you just need to use the name and the track (using the full path of the track) e.g.:
id3edsmd -ti "My Title" /Users/kds/Desktop/MyRecordings/Song1.mp3

If you copied the CLI just use the full path e.g.:
/Users/kds/Desktop/id3edcmd -ti "My Title" /Users/kds/Desktop/MyRecordings/Song1.mp3

If you are scripting lots of files, just replace the full file path with the variable you require e.g.:

echo "Parsing directory '$1'..."
for FILE in "$1"/*
do
    if [[ -f "$FILE" ]]; then
        id3edcmd -ti "A title" "$FILE"
    fi
done

Where $1 is the path used when calling the script.
.........................
James Rae
Pa-software support

Posted May 12, 2016, 5:57 pm
This member is currently offline kds
Newbie


Member Level

Group: Members
Posts: 2
Joined: May 2, 2016

Add kds to your buddy list Send an email to kds Reply with a quote from this post Go to the top of the page

Thanks!! I'll give it a try!

*Posted May 17, 2016, 1:19 pm
Pages: << prev 1 next >>