Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

update README.md #334

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
29 changes: 9 additions & 20 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,20 +19,19 @@ This tool is meant to be used to download CC0 licenced content, we do not suppor

## Installation

### Install via go get

Please ensure you have installed Go 1.21 or later.
### Run Manually

```shell
go get github.com/kkdai/youtube/v2
git clone https://github.com/kkdai/youtube.git && cd youtube
go run ./cmd/youtubedr
```

### From source code
### Install via Go

Please ensure you have installed Go 1.21 or later.

```shell
git clone https://github.com/kkdai/youtube.git
cd youtube
go run ./cmd/youtubedr
go install github.com/kkdai/youtube/v2/cmd/youtubedr@latest
```

### Mac
Expand All @@ -56,8 +55,8 @@ pkg install youtubedr
It's really simple to use, just get the video id from youtube url - ex: `https://www.youtube.com/watch?v=rFejpH_tAHM`, the video id is `rFejpH_tAHM`

```shell
$ youtubedr download QAGDGja7kbs
$ youtubedr download https://www.youtube.com/watch?v=rFejpH_tAHM
youtubedr download rFejpH_tAHM
youtubedr download https://www.youtube.com/watch?v=rFejpH_tAHM
```


Expand All @@ -69,8 +68,6 @@ Please check out the [example_test.go](example_test.go) for example code.
## Example:
* ### Get information of dotGo-2015-rob-pike video for downloading

`go get github.com/kkdai/youtube/v2/youtubedr`

Download video from [dotGo 2015 - Rob Pike - Simplicity is Complicated](https://www.youtube.com/watch?v=rFejpH_tAHM)

```
Expand All @@ -87,8 +84,6 @@ Please check out the [example_test.go](example_test.go) for example code.
```
* ### Download dotGo-2015-rob-pike-video

`go get github.com/kkdai/youtube/v2/youtubedr`

Download video from [dotGo 2015 - Rob Pike - Simplicity is Complicated](https://www.youtube.com/watch?v=rFejpH_tAHM)

```
Expand All @@ -97,8 +92,6 @@ Please check out the [example_test.go](example_test.go) for example code.

* ### Download video to specific folder and name

`go get github.com/kkdai/youtube/v2/youtubedr`

Download video from [dotGo 2015 - Rob Pike - Simplicity is Complicated](https://www.youtube.com/watch?v=rFejpH_tAHM) to current directory and name the file to simplicity-is-complicated.mp4

```
Expand All @@ -107,8 +100,6 @@ Please check out the [example_test.go](example_test.go) for example code.

* ### Download video with specific quality

`go get github.com/kkdai/youtube/v2/youtubedr`

Download video from [dotGo 2015 - Rob Pike - Simplicity is Complicated](https://www.youtube.com/watch?v=rFejpH_tAHM) with specific quality

```
Expand All @@ -125,8 +116,6 @@ Please check out the [example_test.go](example_test.go) for example code.

* ### Download video with specific itag

`go get github.com/kkdai/youtube/v2/youtubedr`

Download video from [dotGo 2015 - Rob Pike - Simplicity is Complicated](https://www.youtube.com/watch?v=rFejpH_tAHM)

```
Expand Down