Skip to content

Instantly share code, notes, and snippets.

@simonjodet
Created June 1, 2013 18:57
Show Gist options
  • Save simonjodet/5691373 to your computer and use it in GitHub Desktop.
Save simonjodet/5691373 to your computer and use it in GitHub Desktop.
This is how you add a video to iTunes as a TV Show with AppleScript. Save it as "add_to_iTunes.scpt" using /Applications/Utilities/AppleScript Editor Run it with "osascript add_to_iTunes.scpt /absolute/path/to/video/file.mp4"
on run {input}
tell application "iTunes"
set newFile to input as POSIX file
set newAddition to (add newFile)
tell newAddition to set video kind to TV show
end tell
end run
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment