Skip to content

Instantly share code, notes, and snippets.

@FlorianHeigl
Last active November 18, 2018 15:39
Show Gist options
  • Select an option

  • Save FlorianHeigl/b2782e12106a3fd2370eadac5504776c to your computer and use it in GitHub Desktop.

Select an option

Save FlorianHeigl/b2782e12106a3fd2370eadac5504776c to your computer and use it in GitHub Desktop.
most simple webm to mp4 converter for itunes, deletes original after conversion
#!/usr/bin/env bash
DELETE=y
fullfile="${1}"
filename=$(basename -- "$fullfile")
extension="${filename##*.}"
filename="${filename%.*}"
if [[ "${extension}" == "webm" ]] && ! [[ -r "${filename}".mp4 ]]; then
ffmpeg -i "${fullfile}" -q:a 0 "${filename}.mp4" &&
rm "${fullfile}"
fi
@FlorianHeigl
Copy link
Author

didnt continue on this since it lacks protection for movies.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment