Downpour

Downpour was built for Fetch — a Put.io client — to parse TV & Movie information from downloaded files. It can be used on any platform that can run Swift as it only relies on Foundation.
It can gather the following from a raw video file name:
- TV or movie title
- Year of release
- TV season number
- TV episode number
It can gather the following from an audio file on macOS:
- Title
- Creation Date
- Type
- Format
- Copyrights
- Album
- Artist
- Artwork
- Publisher
- Creator
- Subject
- Summary (AKA Description)
- Contributer
- Last Modified Date
- Language
- Author
And from Linux (Ubuntu if the libimage-exiftool-perl package is installed):
- Title
- Creation Date
- Type
- Format
- Copyrights
- Album
- Artist
- Artwork
NOTE: None of the fields are guaranteed to be there or even picked up, it’s kinda hard to extract metadata from file names with only a few clever regexes and audio data from files is difficult to do cross-platform. Please open an issue if you know the data is there, but it’s not being picked up. Also, it means everything is Optional and be sure to use guard/if let
or nil-coalescing (??
) to program safely. :)
Installation
Swift Package Manager:
This supports SPM installation for swift 5.0 by adding the following to your Package.swift dependencies:
.package(url: "https://github.com/Ponyboy47/Downpour.git", from: "0.8.0")
For swift 4.x use 0.7.x
For swift 3 use 0.4.x
Usage
Using Downpour is easy. Just create a new instance and it’ll do the rest.
let dvd_rip = Downpour(filename: filename)
let title = dvd_rip.title
let year = dvd_rip.year
if downpour.type == .tv {
let season = dvd_rip.season
let episode = dvd_rip.episode
}
Common Scenarios:
- Backing up your dvd/blu-ray collection
- Designed to work with media ripped using the popular MakeMKV utility
- Organizing your media files
Downpour
Downpour was built for Fetch — a Put.io client — to parse TV & Movie information from downloaded files. It can be used on any platform that can run Swift as it only relies on Foundation.
It can gather the following from a raw video file name:
It can gather the following from an audio file on macOS:
And from Linux (Ubuntu if the libimage-exiftool-perl package is installed):
NOTE: None of the fields are guaranteed to be there or even picked up, it’s kinda hard to extract metadata from file names with only a few clever regexes and audio data from files is difficult to do cross-platform. Please open an issue if you know the data is there, but it’s not being picked up. Also, it means everything is Optional and be sure to use
guard/if let
or nil-coalescing (??
) to program safely. :)Installation
Swift Package Manager:
This supports SPM installation for swift 5.0 by adding the following to your Package.swift dependencies:
For swift 4.x use 0.7.x For swift 3 use 0.4.x
Usage
Using Downpour is easy. Just create a new instance and it’ll do the rest.
Common Scenarios: