Last active
April 29, 2016 16:02
-
-
Save thde/48c61b640266b3f7a8086bacec2d4c0d to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
SNIPPETS_DIR="snippets" | |
SNIPPETS_LENGTH="00:00:30" | |
SNIPPETS_START="00:02:00" | |
mkdir "${SNIPPETS_DIR}" | |
for file in "$@" | |
do | |
filename=$(basename "${file}" .wav) | |
ffmpeg -ss "${SNIPPETS_START}" -i "${file}" -t "${SNIPPETS_LENGTH}" -codec:a libmp3lame -q:a 0 "${SNIPPETS_DIR}/${filename}.mp3" | |
done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment