ytkit
TypeScript icon, indicating that this package has built-in type declarations

1.4.45 • Public • Published

YTKIT

A youtube command line utility kit

oclif Version CircleCI Downloads/week License codecov.io Join the chat at https://gitter.im/ytkit/community Known Vulnerabilities

Usage

$ npm install -g ytkit
$ ytkit COMMAND
running command...
$ ytkit (-v|--version|version)
ytkit/1.4.45 linux-x64 node-v17.1.0
$ ytkit --help [COMMAND]
USAGE
  $ ytkit COMMAND
...

Commands

ytkit download

download video to a file or to stdout

USAGE
  $ ytkit download

OPTIONS
  -o, --output=output                         Save to file, template by {prop}, default: stdout or {title}
  -u, --url=url                               (required) Youtube video or playlist url
  --begin=begin                               Time to begin video, format by 1:30.123 and 1m30s
  --filter=(video|videoonly|audio|audioonly)  Can be video, videoonly, audio, audioonly
  --filter-container=filter-container         Filter in format container
  --filter-resolution=filter-resolution       Filter in format resolution
  --json                                      format output as json
  --quality=quality                           Video quality to download, default: highest
  --range=range                               Byte range to download, ie 10355705-12452856
  --unfilter-container=unfilter-container     Filter out format container
  --unfilter-resolution=unfilter-resolution   Filter out format container
  --urlonly                                   Print direct download URL

EXAMPLE
  $ ytdl download -u https://www.youtube.com/watch?v=aqz-KE-bpKQ

See code: src/commands/download.ts

ytkit help [COMMAND]

display help for ytkit

USAGE
  $ ytkit help [COMMAND]

ARGUMENTS
  COMMAND  command to show help for

OPTIONS
  --all  see all commands in CLI

See code: @oclif/plugin-help

ytkit info

display information about a video

USAGE
  $ ytkit info

OPTIONS
  -f, --formats  Display available video formats
  -u, --url=url  (required) Youtube video or playlist url
  --json         format output as json

EXAMPLE
  $ ytdl info -u https://www.youtube.com/watch?v=aqz-KE-bpKQ

See code: src/commands/info.ts

ytkit search

Search for Youtube for Videos

USAGE
  $ ytkit search

OPTIONS
  -l, --limit=limit  [default: 100] Limits the pulled items, defaults to 100, set to Infinity to get the whole list of
                     search results

  -o, --options      Search options

  -q, --query=query  (required) Query term

  --json             format output as json

  --safe-search      Pull items in youtube restriction mode

EXAMPLE
  $ ytdl search -q banana

See code: src/commands/search.ts

Contributing

If you are interested in contributing, please take a look at the CONTRIBUTING guide.

Development

If you are interested in building this package locally, please take a look at the DEVELOPING doc.

Releases

Run ytkit version to display the version of YTKIT CLI installed on your computer.

Run ytkit update to update the CLI to the latest available version.

Installation

You can install this by either using an OS-specific installer available here, by directly installing it with npm or yarn (see the instructions below).

Installing with npm or yarn

To get started, you'll need to install node v12 or greater, though we recommend using the latest v14 (LTS) for the best experience. While this can be done using an installer from nodejs.com or via an OS-specific package manager, we recommend using nvm to easily manage multiple node versions.

If using nvm, be sure that you've selected the appropriate version with something like nvm use v14.x.y, where x and y are specific to the version that you installed. If you want to use this version by default run nvm alias default node -- otherwise, when you restart your shell nvm will revert to whatever version configured prior to installing the latest.

npm

npm is installed automatically with Node.js. Install the CLI using npm as follows:

> npm install --global ytkit

yarn

yarn is another popular Node.js package manager that can be used to install the CLI, but it needs to be installed separately from Node.js if you choose to use it.

Note that by default yarn will attempt to install the binary in a location that may conflict with the location used by the installers, so you may additionally want to run the following command to avoid collision should you want to maintain two separate installations: yarn config set prefix ~/.yarn (macOS and Linux). Then, use the following:

> yarn global add ytkit

Debugging with VSCode

We provide tree convinient methods for you to debug this application as follows:

  • Launch Program: launches the program with the given argument (edit the aruments in launch.json).
  • Debug All Tests: launches the debugger on all tests.
  • Debug Active Test: launches the debugger on the current working test.

Docker Images

We provide versioned images on dockerhub.

Example

> docker pull rbmaggi/ytkit # choose a tag to pull and run
> ytkit version # then run any ytkit command you like
> exit # when done, type exit to leave the container

ATTENTION

While this tool makes it easy to download content from Youtube, I do not endorse the theft of content created by hardworking citizens of the Internet. If you use Youtube as a primary source of entertainment, then please remember to turn off ad-block, buy their merchandise, or donate to the content creators you love to watch. And if you can't do that then simply like, comment, and subscribe to help them get more people enjoying their content.

Package Sidebar

Install

npm i ytkit

Weekly Downloads

2

Version

1.4.45

License

MIT

Unpacked Size

99 kB

Total Files

23

Last publish

Collaborators

  • maggiben