summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorElliott Baron <ebaron@fedoraproject.org>2009-09-20 23:09:05 -0400
committerElliott Baron <ebaron@fedoraproject.org>2009-09-20 23:09:05 -0400
commit5eed1c9cfeb139c2cb5c3ceb6442bd2b9d3b3e54 (patch)
tree2ec54b30596fdf8dbd21a3c98bc26607376e08d9
parent795189ebbdea927e43e8f9ca147ec1f6210e8604 (diff)
downloadalac-tools-master.tar.gz
alac-tools-master.tar.xz
alac-tools-master.zip
Fixed cover art option, execute python scripts relative to main script.HEADmaster
* flac2alac.sh: Corrected bug with -c option, use dirname to find path to python scripts.
-rwxr-xr-xflac2alac.sh21
1 files changed, 11 insertions, 10 deletions
diff --git a/flac2alac.sh b/flac2alac.sh
index 4b6a8b2..ec28172 100755
--- a/flac2alac.sh
+++ b/flac2alac.sh
@@ -32,6 +32,8 @@ if [ $# -eq 0 ]; then
usage
fi
+basedir=`dirname $0`
+
for i in "$@"
do
# Convert from FLAC to ALAC
@@ -43,18 +45,17 @@ do
exit $rc
fi
# Migrate tags
- alac_copy_tags.py "$flac" "$alac"
+ $basedir/alac_copy_tags.py "$flac" "$alac"
rc=$?
if [ $rc -ne 0 ]; then
exit $rc
fi
-done
-
-# Embed Album Art
-if [ -z "$cover" ]; then
- alac_embed_art.py "$cover" "$@"
- rc=$?
- if [ $rc -ne 0 ]; then
- exit $rc
+ # Embed Album Art
+ if [ ! -z "$cover" ]; then
+ $basedir/alac_embed_art.py "$cover" "$alac"
+ rc=$?
+ if [ $rc -ne 0 ]; then
+ exit $rc
+ fi
fi
-fi
+done