Commits

neonacho  committed 3f55296

Added support for intro/outro clips

  • Participants
  • Parent commits 5e9b77e

Comments (0)

Files changed (2)

File examples/config

 
 ## FTP upload URL
 TARGET_URL='ftp://user:password@example.com/wp-content/uploads/'
+
+## Optional intro and outro files, need to be readable by sox
+INTRO=/foo/bar/nyan_cat.wav
+OUTRO=/foo/bar/nyan_cat.wav

File nachocast.sh

 		MUXED="muxed.tmp$$.wav"
 		sox -m "$TRACK1" "$TRACK2" "$MUXED"
 		rm -f "$TRACK1" "$TRACK2"
+
+    # Add intro and outro (if defined in configuration)
+    if [ -n "$INTRO" -o -n "$OUTRO" ]
+    then
+      MUXED2="muxed2.tmp$$.wav"
+      sox "$INTRO" "$MUXED" "$OUTRO" "$MUXED2"
+      rm -f "$MUXED"
+      MUXED="$MUXED2"
+    fi
 		
 		# Apply audio filters
 		if [ -n "$SOX_FILTERS" ]