Skip to content
/ subdb Public
forked from wilkerlucio/subdb

Ruby client and API for SubDB download and upload

License

Notifications You must be signed in to change notification settings

jrhames/subdb

 
 

Repository files navigation

Ruby SubDB

This project aims to provide a simple API for accessing SubDB

GUI client

We are proud to annouce now we have a GUI client to make it easy for anyone to use SubDB, you can download client with following links:

Mac Version
Windows / Linux version

Just download, open, and drag your files on program window. It will work in same way as Command Line tool.

Installation

gem install subdb

Command Line Usage

You can simply use it by command line to sync your subtitles with SubDB, let’s say you have a folder called ~/Movies where all your movies are placed, you can do simple:

subdb ~/Movies

It will upload any subtitle that you already have to SubDB, and will try to download subtitles for movies that don’t already have a local one.

Library Usage

If you plan to use on your project, SubDB gem also provides a simple interface for it. You can figure it all with the following example:

require 'subdb'

file = Subdb.new("path_to_your_movie.mp4")
file.search                         # will retrieve a string with available languages (ex: "pt,en") or nil if don't have anyone
file.download(["en", "pt"])         # will download the subtitle for given language, it tries in order of array
file.upload("path_to_subtitle.str") # will upload a subtitle for this movie

It’s only this :)

About

Ruby client and API for SubDB download and upload

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Ruby 100.0%