docs/src/installation.md
111 lines · 3330 bytes
1# Installation
2
3The YouTube TUI is *not* intended for Windows, pull requests to make it work are welcome.
4
5## Install from Crates.io (recommended)
6
7Crates.io is a repository for programs written in Rust, and the YouTube TUI is available <a href="https://crates.io/crates/youtube-tui" target=_blank>*there*</a>.
8
9To install using this method, you will need `rustc` and `cargo` present. <a href="https://www.rust-lang.org/tools/install" target=_blank>*Here*</a>'s a tutorial on how to get them.
10
11Now, run the following command:
12
13```sh
14cargo install youtube-tui
15```
16
17> To check and update all programs installed from Crates.io, you can use CLI tools like <a href="https://crates.io/crates/cargo-update" target=_blank>*cargo-update*</a>.
18
19## AUR for Arch Linux (recommended)
20
21The YouTube TUI is available in the AUR <a href="https://aur.archlinux.org/packages/youtube-tui-git" target=_blank>*here*</a>.
22
23Use an <a href="https://aur.archlinux.org" target=_blank>AUR</a> helper like <a href="https://aur.archlinux.org/packages/yay" target=_blank>`yay`</a> to install.
24
25```sh
26yay -S youtube-tui # lastest crates.io release, recommended
27yay -S youtube-tui-git # latest git version, potentially untested
28yay -S youtube-tui-full-bin # default binary (out of date)
29yay -S youtube-tui-nodefaults-bin # minimal binary (out of date)
30```
31## Installation on NixOS (recommended)
32
33Add the following Nix code to your NixOS Configuration
34
35```nix
36environment.systemPackages = [
37 pkgs.youtube-tui
38];
39```
40
41## Installation on NixOS **with flakes** (recommended)
42
43```nix
44{
45 inputs.youtube-tui.url = "github:Siriusmart/youtube-tui";
46
47 ...
48}
49```
50
51## Build from source
52
53Use the `cargo` command:
54
55```sh
56cargo install --git https://github.com/siriusmart/youtube-tui
57```
58
59### Confirm YouTube TUI has been installed
60
61Run the following command in terminal:
62
63```sh
64youtube-tui
65```
66
67If installed correctly, a TUI should be launched. Press `q` to close the TUI.
68
69## Features
70
71The TUI has features that can be enabled/disabled when compiling.
72
73```sh
74cargo install youtube-tui # install with all default features
75cargo install youtube-tui --no-default-features -F feature1 -F feature2 # install with only the specified features
76cargo install youtube-tui --all-features # install with all features (even if not included in default)
77```
78
79### `halfblock` (default)
80
81Display images through HalfBlocks, work best in terminals with TrueColour support.
82
83### `sixel` (default)
84
85Display images with Sixels, allows the display of images at full definition. Not present on windows.
86
87Enabling this will also enable `halfblock`.
88
89Requires <a href="https://github.com/saitoha/libsixel" target=_blank>`libsixel`</a>.
90
91### `clipboard` (default)
92
93Allows clipboard pasting in commands and search bar.
94
95Requires <a href="https://xcb.freedesktop.org/" target=_blank>`libxcb`</a>.
96
97### `mpv` (default)
98
99Embedded audio player
100
101Requires <a href="https://mpv.io/" target=_blank>`mpv`</a> (libmpv) to be installed in your system.
102
103### rustypipe (default)
104
105Rustypipe backend for fetching video information, Rustypipe runs on your local machine, it's a bit like yt-dlp.
106
107### invidious
108
109invidious backend for fetching video information, requires a working Invidious instance with API enabled set in [`main.yml`](./config/main.md).
110
111> You *must* enable at least one of the two backends.