From 789721946a35e3d2228179ac3585d35fbd5ff8b5 Mon Sep 17 00:00:00 2001 From: Erich Eckner Date: Thu, 15 Dec 2016 15:15:28 +0100 Subject: only join if necessary --- burn-audio-cd | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/burn-audio-cd b/burn-audio-cd index 45659c5..d5915e4 100755 --- a/burn-audio-cd +++ b/burn-audio-cd @@ -1,7 +1,16 @@ #!/bin/bash -shncue "$@" > cd.cue -shnjoin "$@" +if [ ! -r cd.cue ] \ + || [ ! -r joined.wav ] \ + || [ "$(ls -1t cd.cue joined.wav "$@" \ + | head -n2 \ + | sort \ + | tr '\n' ' ')" \ + != "cd.cue joined.wav " ] +then + shncue "$@" > cd.cue + shnjoin "$@" +fi su -c ' /etc/rc.d/boinc stop -- cgit v1.2.3-70-g09d2