youtube_dl

package module
v0.0.0-...-9ca8baf Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 20, 2017 License: MPL-2.0 Imports: 1 Imported by: 0

README

Go-Youtube-dl

A GoLang library for downloading youtube subtitles and meta data using the known Youtube-dl application.

Go-youtube-dl logo



Features

  • Usage of the famous known application Youtube-dl .
  • Optional placeholder interpolation

Requirements

  • Go 1.2 or higher
  • Youtube-dl application to be installed on your server or whatever the machine running the Go code.

Installation

Simple install the package to your $GOPATH with the go tool from shell:

$ go get github.com/youtube-videos/go-youtube-dl

Make sure Git is installed on your machine and in your system's PATH.

Usage

Example of usage is as follow:

ytdl := youtube_dl.YoutubeDl{}
ytdl.Path = "$GOPATH/src/app/srts" // for example
err := ytdl.DownloadVideo(video.Id)
if err != nil {
    log.Printf("%v", err)
}

Then you can handle the downloaded file in the specified path.


License

Go-Youtube-dl is licensed under the Mozilla Public License Version 2.0

Mozilla summarizes the license scope as follows:

MPL: The copyleft applies to any files containing MPLed code.

That means:

  • You can use the unchanged source code both in private and commercially
  • When distributing, you must publish the source code of any changed files licensed under the MPL 2.0 under a) the MPL 2.0 itself or b) a compatible license (e.g. GPL 3.0 or Apache License 2.0)
  • You needn't publish the source code of your library as long as the files licensed under the MPL 2.0 are unchanged

Please read the MPL 2.0 FAQ if you have further questions regarding the license.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type YoutubeDl

type YoutubeDl struct {
	Path string
}

Youtube-dl SRT Downloader

func (YoutubeDl) DownloadVideo

func (youtubedl YoutubeDl) DownloadVideo(id string) error

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL