{"id":13624453,"url":"https://github.com/crunchy-labs/crunchy-cli","last_synced_at":"2025-12-15T04:18:05.395Z","repository":{"id":38085176,"uuid":"394457250","full_name":"crunchy-labs/crunchy-cli","owner":"crunchy-labs","description":"👇 Command-line downloader for Crunchyroll","archived":true,"fork":false,"pushed_at":"2024-07-01T16:43:16.000Z","size":1226,"stargazers_count":614,"open_issues_count":13,"forks_count":61,"subscribers_count":12,"default_branch":"master","last_synced_at":"2025-02-06T00:28:33.443Z","etag":null,"topics":["anime","anime-downloader","anime-streaming","crunchyroll","crunchyroll-api","crunchyroll-downloader","crunchyroll-enhancer","downloader","hacktoberfest","rust","rust-lang","rustlang"],"latest_commit_sha":null,"homepage":"","language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/crunchy-labs.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null}},"created_at":"2021-08-09T22:33:46.000Z","updated_at":"2025-02-04T13:32:36.000Z","dependencies_parsed_at":"2023-11-19T19:30:12.017Z","dependency_job_id":"8c887ad0-1331-4bc5-b9ef-0d9b314ea146","html_url":"https://github.com/crunchy-labs/crunchy-cli","commit_stats":{"total_commits":464,"total_committers":10,"mean_commits":46.4,"dds":"0.16594827586206895","last_synced_commit":"a6bfe0be2e13deaa31f2f9180250a02c3e063c19"},"previous_names":["bytedream/crunchyroll"],"tags_count":63,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/crunchy-labs%2Fcrunchy-cli","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/crunchy-labs%2Fcrunchy-cli/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/crunchy-labs%2Fcrunchy-cli/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/crunchy-labs%2Fcrunchy-cli/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/crunchy-labs","download_url":"https://codeload.github.com/crunchy-labs/crunchy-cli/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":239073968,"owners_count":19577123,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["anime","anime-downloader","anime-streaming","crunchyroll","crunchyroll-api","crunchyroll-downloader","crunchyroll-enhancer","downloader","hacktoberfest","rust","rust-lang","rustlang"],"created_at":"2024-08-01T21:01:42.772Z","updated_at":"2025-10-21T04:48:23.689Z","avatar_url":"https://github.com/crunchy-labs.png","language":"Rust","funding_links":[],"categories":["Rust"],"sub_categories":[],"readme":"# This project has been sunset as Crunchyroll moved to a DRM-only system. See [#362](https://github.com/crunchy-labs/crunchy-cli/issues/362).\n\n# crunchy-cli\n\n👇 A Command-line downloader for [Crunchyroll](https://www.crunchyroll.com).\n\n\u003cp align=\"center\"\u003e\n  \u003ca href=\"https://github.com/crunchy-labs/crunchy-cli\"\u003e\n    \u003cimg src=\"https://img.shields.io/github/languages/code-size/crunchy-labs/crunchy-cli?style=flat-square\" alt=\"Code size\"\u003e\n  \u003c/a\u003e\n  \u003ca href=\"https://github.com/crunchy-labs/crunchy-cli/releases/latest\"\u003e\n    \u003cimg src=\"https://img.shields.io/github/downloads/crunchy-labs/crunchy-cli/total?style=flat-square\" alt=\"Download Badge\"\u003e\n  \u003c/a\u003e\n  \u003ca href=\"https://github.com/crunchy-labs/crunchy-cli/blob/master/LICENSE\"\u003e\n    \u003cimg src=\"https://img.shields.io/github/license/crunchy-labs/crunchy-cli?style=flat-square\" alt=\"License\"\u003e\n  \u003c/a\u003e\n  \u003ca href=\"https://github.com/crunchy-labs/crunchy-cli/releases\"\u003e\n    \u003cimg src=\"https://img.shields.io/github/v/release/crunchy-labs/crunchy-cli?include_prereleases\u0026style=flat-square\" alt=\"Release\"\u003e\n  \u003c/a\u003e\n  \u003ca href=\"https://discord.gg/PXGPGpQxgk\"\u003e\n    \u003cimg src=\"https://img.shields.io/discord/994882878125121596?label=discord\u0026style=flat-square\" alt=\"Discord\"\u003e\n  \u003c/a\u003e\n  \u003ca href=\"https://github.com/crunchy-labs/crunchy-cli/actions/workflows/build.yml\"\u003e\n    \u003cimg src=\"https://img.shields.io/github/actions/workflow/status/crunchy-labs/crunchy-cli/build.yml?branch=master\u0026style=flat-square\" alt=\"Build\"\u003e\n  \u003c/a\u003e\n\u003c/p\u003e\n\n\u003cp align=\"center\"\u003e\n  \u003ca href=\"#%EF%B8%8F-usage\"\u003eUsage 🖥️\u003c/a\u003e\n  •\n  \u003ca href=\"#-disclaimer\"\u003eDisclaimer 📜\u003c/a\u003e\n  •\n  \u003ca href=\"#-license\"\u003eLicense ⚖\u003c/a\u003e\n\u003c/p\u003e\n\n\u003e We are in no way affiliated with, maintained, authorized, sponsored, or officially associated with Crunchyroll LLC or any of its subsidiaries or affiliates.\n\u003e The official Crunchyroll website can be found at [www.crunchyroll.com](https://www.crunchyroll.com/).\n\n## ✨ Features\n\n- Download single videos and entire series from [Crunchyroll](https://www.crunchyroll.com).\n- Archive episodes or seasons in an `.mkv` file with multiple subtitles and audios.\n- Specify a range of episodes to download from an anime.\n- Search through the Crunchyroll collection and return metadata (title, duration, direct stream link, ...) of all media types.\n\n## 💾 Get the executable\n\n### 📥 Download the latest binaries\n\nCheck out the [releases](https://github.com/crunchy-labs/crunchy-cli/releases) tab and get the binary from the latest (pre-)release.\n\n### 📦 Get it via a package manager\n\n- [AUR](https://aur.archlinux.org/)\n\n  If you're using Arch or an Arch based Linux distribution you are able to install our [AUR](https://aur.archlinux.org/) package.\n  You need an [AUR helper](https://wiki.archlinux.org/title/AUR_helpers) like [yay](https://github.com/Jguer/yay) to install it.\n\n  ```shell\n  # this package builds crunchy-cli manually (recommended)\n  $ yay -S crunchy-cli\n  # this package installs the latest pre-compiled release binary\n  $ yay -S crunchy-cli-bin\n  ```\n\n- [Scoop](https://scoop.sh/)\n\n  For Windows users, we support the [scoop](https://scoop.sh/#/) command-line installer.\n\n  ```shell\n  $ scoop bucket add extras\n  $ scoop install extras/crunchy-cli\n  ```\n\n- [Homebrew](https://brew.sh/)\n\n  For macOS/linux users, we support the [brew](https://brew.sh/#/) command-line installer. Packages are compiled by the [homebrew project](https://formulae.brew.sh/formula/crunchy-cli), and will also install the `openssl@3` and `ffmpeg` dependencies.\n\n  ```shell\n  $ brew install crunchy-cli\n  ```\n\n  Supported archs: `x86_64_linux`, `arm64_monterey`, `sonoma`, `ventura`\n\n- [Nix](https://nixos.org/)\n\n  This requires [nix](https://nixos.org) and you'll probably need `--extra-experimental-features \"nix-command flakes\"`, depending on your configurations.\n\n  ```shell\n  $ nix \u003crun|shell|develop\u003e github:crunchy-labs/crunchy-cli\n  ```\n\n### 🛠 Build it yourself\n\nSince we do not support every platform and architecture you may have to build the project yourself.\nThis requires [git](https://git-scm.com/) and [Cargo](https://doc.rust-lang.org/cargo).\n\n```shell\n$ git clone https://github.com/crunchy-labs/crunchy-cli\n$ cd crunchy-cli\n# either just build it (will be available in ./target/release/crunchy-cli)...\n$ cargo build --release\n# ... or install it globally\n$ cargo install --force --path .\n```\n\n## 🖥️ Usage\n\n\u003e All shown commands are examples 🧑🏼‍🍳\n\n### Global Flags\n\ncrunchy-cli requires you to log in.\nThough you can use a non-premium account, you will not have access to premium content without a subscription.\nYou can authenticate with your credentials (email:password) or by using a refresh token.\n\n- \u003cspan id=\"global-credentials\"\u003eCredentials\u003c/span\u003e\n\n  ```shell\n  $ crunchy-cli --credentials \"email:password\" \u003ccommand\u003e\n  ```\n\n- \u003cspan id=\"global-anonymous\"\u003eStay Anonymous\u003c/span\u003e\n\n  Login without an account (you won't be able to access premium content):\n\n  ```shell\n  $ crunchy-cli --anonymous \u003ccommand\u003e\n  ```\n\n### Global settings\n\nYou can set specific settings which will be\n\n- \u003cspan id=\"global-verbose\"\u003eVerbose output\u003c/span\u003e\n\n  If you want to include debug information in the output, use the `-v` / `--verbose` flag to show it.\n\n  ```shell\n  $ crunchy-cli -v \u003ccommand\u003e\n  ```\n\n  This flag can't be used in combination with `-q` / `--quiet`.\n\n- \u003cspan id=\"global-quiet\"\u003eQuiet output\u003c/span\u003e\n\n  If you want to hide all output, use the `-q` / `--quiet` flag to do so.\n  This is especially useful if you want to pipe the output video to an external program (like a video player).\n\n  ```shell\n  $ crunchy-cli -q \u003ccommand\u003e\n  ```\n\n  This flag can't be used in combination with `-v` / `--verbose`.\n\n- \u003cspan id=\"global-lang\"\u003eLanguage\u003c/span\u003e\n\n  By default, the resulting metadata like title or description are shown in your system language (if Crunchyroll supports it, else in English).\n  If you want to show the results in another language, use the `--lang` flag to set it.\n\n  ```shell\n  $ crunchy-cli --lang de-DE \u003ccommand\u003e\n  ```\n\n- \u003cspan id=\"global-experimental-fixes\"\u003eExperimental fixes\u003c/span\u003e\n\n  Crunchyroll constantly changes and breaks its services or just delivers incorrect answers.\n  The `--experimental-fixes` flag tries to fix some of those issues.\n  As the *experimental* in `--experimental-fixes` states, these fixes may or may not break other functionality.\n\n  ```shell\n  $ crunchy-cli --experimental-fixes \u003ccommand\u003e\n  ```\n\n  For an overview which parts this flag affects, see the [documentation](https://docs.rs/crunchyroll-rs/latest/crunchyroll_rs/crunchyroll/struct.CrunchyrollBuilder.html) of the underlying Crunchyroll library, all functions beginning with `stabilization_` are applied.\n\n- \u003cspan id=\"global-proxy\"\u003eProxy\u003c/span\u003e\n\n  The `--proxy` flag supports https and socks5 proxies to route all your traffic through.\n  This may be helpful to bypass the geo-restrictions Crunchyroll has on certain series.\n  You are also able to set in which part of the cli a proxy should be used.\n  Instead of a normal url you can also use: `\u003curl\u003e:` (only proxies api requests), `:\u003curl\u003e` (only proxies download traffic), `\u003curl\u003e:\u003curl\u003e` (proxies api requests through the first url and download traffic through the second url).\n\n  ```shell\n  $ crunchy-cli --proxy socks5://127.0.0.1:8080 \u003ccommand\u003e\n  ```\n\n  Make sure that proxy can either forward TLS requests, which is needed to bypass the (cloudflare) bot protection, or that it is configured so that the proxy can bypass the protection itself.\n\n- \u003cspan id=\"global-user-agent\"\u003eUser Agent\u003c/span\u003e\n\n  There might be cases where a custom user agent is necessary, e.g. to bypass the cloudflare bot protection (#104).\n  In such cases, the `--user-agent` flag can be used to set a custom user agent.\n\n  ```shell\n  $ crunchy-cli --user-agent \"Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 5.1; Trident/4.0)\" \u003ccommand\u003e\n  ```\n  \n  Default is the user agent, defined in the underlying [library](https://github.com/crunchy-labs/crunchyroll-rs).\n\n- \u003cspan id=\"global-speed-limit\"\u003eSpeed limit\u003c/span\u003e\n\n  If you want to limit how fast requests/downloads should be, you can use the `--speed-limit` flag. Allowed units are `B` (bytes), `KB` (kilobytes) and `MB` (megabytes).\n\n  ```shell\n  $ crunchy-cli --speed-limit 10MB\n  ```\n\n### Login\n\nThe `login` command can store your session, so you don't have to authenticate every time you execute a command.\n\n```shell\n# save the refresh token which gets generated when login with credentials.\n# your email and password won't be stored at any time on disk\n$ crunchy-cli login --credentials \"email:password\"\n```\n\nWith the session stored, you do not need to pass `--credentials` / `--anonymous` anymore when you want to execute a command.\n\n### Download\n\nThe `download` command lets you download episodes with a specific audio language and optional subtitles.\n\n**Supported urls**\n\n- Single episode (with [episode filtering](#episode-filtering))\n  ```shell\n  $ crunchy-cli download https://www.crunchyroll.com/watch/GRDQPM1ZY/alone-and-lonesome\n  ```\n- Series (with [episode filtering](#episode-filtering))\n  ```shell\n  $ crunchy-cli download https://www.crunchyroll.com/series/GY8VEQ95Y/darling-in-the-franxx\n  ```\n\n**Options**\n\n- \u003cspan id=\"download-audio\"\u003eAudio language\u003c/span\u003e\n\n  Set the audio language with the `-a` / `--audio` flag.\n  This only works if the url points to a series since episode urls are language specific.\n\n  ```shell\n  $ crunchy-cli download -a de-DE https://www.crunchyroll.com/series/GY8VEQ95Y/darling-in-the-franxx\n  ```\n\n  Default is your system locale. If not supported by Crunchyroll, `en-US` (American English) is the default.\n\n- \u003cspan id=\"download-subtitle\"\u003eSubtitle language\u003c/span\u003e\n\n  Besides the audio, you can specify the subtitle language by using the `-s` / `--subtitle` flag.\n  In formats that support it (.mp4, .mov and .mkv ), subtitles are stored as soft-subs. All other formats are hardsubbed: the subtitles will be burned into the video track (cf. [hardsub](https://www.urbandictionary.com/define.php?term=hardsub)) and thus can not be turned off.\n\n  ```shell\n  $ crunchy-cli download -s de-DE https://www.crunchyroll.com/series/GY8VEQ95Y/darling-in-the-franxx\n  ```\n\n  Default is none.\n\n- \u003cspan id=\"download-output\"\u003eOutput template\u003c/span\u003e\n\n  Define an output template by using the `-o` / `--output` flag.\n\n  ```shell\n  $ crunchy-cli download -o \"ditf.mp4\" https://www.crunchyroll.com/watch/GRDQPM1ZY/alone-and-lonesome\n  ```\n\n  Default is `{title}.mp4`. See the [Template Options section](#output-template-options) below for more options.\n\n- \u003cspan id=\"download-output-specials\"\u003eOutput template for special episodes\u003c/span\u003e\n\n  Define an output template which only gets used when the episode is a special (episode number is 0 or has non-zero decimal places) by using the `--output-special` flag.\n\n  ```shell\n  $ crunchy-cli download --output-specials \"Special EP - {title}\" https://www.crunchyroll.com/watch/GY8D975JY/veldoras-journal\n  ```\n  \n  Default is the template, set by the `-o` / `--output` flag. See the [Template Options section](#output-template-options) below for more options.\n\n- \u003cspan id=\"download-universal-output\"\u003eUniversal output\u003c/span\u003e\n\n  The output template options can be forced to get sanitized via the `--universal-output` flag to be valid across all supported operating systems (Windows has a lot of characters which aren't allowed in filenames...).\n\n  ```shell\n  $ crunchy-cli download --universal-output -o https://www.crunchyroll.com/watch/G7PU4XD48/tales-veldoras-journal-2\n  ```\n\n- \u003cspan id=\"download-resolution\"\u003eResolution\u003c/span\u003e\n\n  The resolution for videos can be set via the `-r` / `--resolution` flag.\n\n  ```shell\n  $ crunchy-cli download -r worst https://www.crunchyroll.com/watch/GRDQPM1ZY/alone-and-lonesome\n  ```\n\n  Default is `best`.\n\n- \u003cspan id=\"download-language-tagging\"\u003eLanguage tagging\u003c/span\u003e\n\n  You can force the usage of a specific language tagging in the output file with the `--language-tagging` flag.\n  This might be useful as some video players doesn't recognize the language tagging Crunchyroll uses internally.\n\n  ```shell\n  $ crunchy-cli download --language-tagging ietf https://www.crunchyroll.com/watch/GRDQPM1ZY/alone-and-lonesome\n  ```\n\n- \u003cspan id=\"download-ffmpeg-preset\"\u003eFFmpeg Preset\u003c/span\u003e\n\n  You can specify specific built-in presets with the `--ffmpeg-preset` flag to convert videos to a specific coding while downloading.\n  Multiple predefined presets how videos should be encoded (h264, h265, av1, ...) are available, you can see them with `crunchy-cli download --help`.\n  If you need more specific ffmpeg customizations you could either convert the output file manually or use ffmpeg output arguments as value for this flag.\n\n  ```shell\n  $ crunchy-cli download --ffmpeg-preset av1-lossless https://www.crunchyroll.com/watch/GRDQPM1ZY/alone-and-lonesome\n  ```\n\n- \u003cspan id=\"download-ffmpeg-threads\"\u003eFFmpeg threads\u003c/span\u003e\n\n  If you want to manually set how many threads FFmpeg should use, you can use the `--ffmpeg-threads` flag. This does not work with every codec/preset and is skipped entirely when specifying custom ffmpeg output arguments instead of a preset for `--ffmpeg-preset`.\n\n  ```shell\n  $ crunchy-cli download --ffmpeg-threads 4 https://www.crunchyroll.com/watch/GRDQPM1ZY/alone-and-lonesome\n  ```\n\n- \u003cspan id=\"download-skip-existing\"\u003eSkip existing\u003c/span\u003e\n\n  If you re-download a series but want to skip episodes you've already downloaded, the `--skip-existing` flag skips the already existing/downloaded files.\n\n  ```shell\n  $ crunchy-cli download --skip-existing https://www.crunchyroll.com/series/GY8VEQ95Y/darling-in-the-franxx\n  ```\n\n- \u003cspan id=\"download-skip-specials\"\u003eSkip specials\u003c/span\u003e\n\n  If you doesn't want to download special episodes, use the `--skip-specials` flag to skip the download of them.\n\n  ```shell\n  $ crunchy-cli download --skip-specials https://www.crunchyroll.com/series/GYZJ43JMR/that-time-i-got-reincarnated-as-a-slime[S2]\n  ```\n\n- \u003cspan id=\"download-include-chapters\"\u003eInclude chapters\u003c/span\u003e\n\n  Crunchyroll sometimes provide information about skippable events like the intro or credits.\n  These information can be stored as chapters in the resulting video file via the `--include-chapters` flag.\n\n  ```shell\n  $ crunchy-cli download --include-chapters https://www.crunchyroll.com/watch/G0DUND0K2/the-journeys-end\n  ```\n\n- \u003cspan id=\"download-yes\"\u003eYes\u003c/span\u003e\n\n  Sometimes different seasons have the same season number (e.g. Sword Art Online Alicization and Alicization War of Underworld are both marked as season 3), in such cases an interactive prompt is shown which needs user further user input to decide which season to download.\n  The `--yes` flag suppresses this interactive prompt and just downloads all seasons.\n\n  ```shell\n  $ crunchy-cli download --yes https://www.crunchyroll.com/series/GR49G9VP6/sword-art-online\n  ```\n\n  If you've passed the `-q` / `--quiet` [global flag](#global-settings), this flag is automatically set.\n\n- \u003cspan id=\"download-force-hardsub\"\u003eForce hardsub\u003c/span\u003e\n\n  If you want to burn-in the subtitles, even if the output format/container supports soft-subs (e.g. `.mp4`), use the `--force-hardsub` flag to do so.\n\n  ```shell\n  $ crunchy-cli download --force-hardsub -s en-US https://www.crunchyroll.com/watch/GRDQPM1ZY/alone-and-lonesome\n  ```\n\n- \u003cspan id=\"download-threads\"\u003eThreads\u003c/span\u003e\n\n  To increase the download speed, video segments are downloaded simultaneously by creating multiple threads.\n  If you want to manually specify how many threads to use when downloading, do this with the `-t` / `--threads` flag.\n\n  ```shell\n  $ crunchy-cli download -t 1 https://www.crunchyroll.com/series/GY8VEQ95Y/darling-in-the-franxx\n  ```\n\n  The default thread count is the count of cpu threads your pc has.\n\n### Archive\n\nThe `archive` command lets you download episodes with multiple audios and subtitles and merges it into a `.mkv` file.\n\n**Supported urls**\n\n- Single episode (with [episode filtering](#episode-filtering))\n  ```shell\n  $ crunchy-cli archive https://www.crunchyroll.com/watch/GRDQPM1ZY/alone-and-lonesome\n  ```\n- Series (with [episode filtering](#episode-filtering))\n  ```shell\n  $ crunchy-cli archive https://www.crunchyroll.com/series/GY8VEQ95Y/darling-in-the-franxx\n  ```\n\n**Options**\n\n- \u003cspan id=\"archive-audio\"\u003eAudio languages\u003c/span\u003e\n\n  Set the audio language with the `-a` / `--audio` flag. Can be used multiple times.\n\n  ```shell\n  $ crunchy-cli archive -a ja-JP -a de-DE https://www.crunchyroll.com/series/GY8VEQ95Y/darling-in-the-franxx\n  ```\n\n  Default is your system locale (if not supported by Crunchyroll, `en-US` (American English) and `ja-JP` (Japanese) are used).\n\n- \u003cspan id=\"archive-subtitle\"\u003eSubtitle languages\u003c/span\u003e\n\n  Besides the audio, you can specify the subtitle language by using the `-s` / `--subtitle` flag.\n\n  ```shell\n  $ crunchy-cli archive -s de-DE https://www.crunchyroll.com/series/GY8VEQ95Y/darling-in-the-franxx\n  ```\n\n  Default is `all` subtitles.\n\n- \u003cspan id=\"archive-output\"\u003eOutput template\u003c/span\u003e\n\n  Define an output template by using the `-o` / `--output` flag.\n  _crunchy-cli_ exclusively uses the [`.mkv`](https://en.wikipedia.org/wiki/Matroska) container format, because of its ability to store multiple audio, video and subtitle tracks at once.\n\n  ```shell\n  $ crunchy-cli archive -o \"{title}.mkv\" https://www.crunchyroll.com/series/GY8VEQ95Y/darling-in-the-franxx\n  ```\n\n  Default is `{title}.mkv`. See the [Template Options section](#output-template-options) below for more options.\n\n- \u003cspan id=\"archive-output-specials\"\u003eOutput template for special episodes\u003c/span\u003e\n\n  Define an output template which only gets used when the episode is a special (episode number is 0 or has non-zero decimal places) by using the `--output-special` flag.\n  _crunchy-cli_ exclusively uses the [`.mkv`](https://en.wikipedia.org/wiki/Matroska) container format, because of its ability to store multiple audio, video and subtitle tracks at once.\n\n  ```shell\n  $ crunchy-cli archive --output-specials \"Special EP - {title}\" https://www.crunchyroll.com/watch/GY8D975JY/veldoras-journal\n  ```\n\n  Default is the template, set by the `-o` / `--output` flag. See the [Template Options section](#output-template-options) below for more options.\n\n- \u003cspan id=\"archive-universal-output\"\u003eUniversal output\u003c/span\u003e\n\n  The output template options can be forced to get sanitized via the `--universal-output` flag to be valid across all supported operating systems (Windows has a lot of characters which aren't allowed in filenames...).\n\n  ```shell\n  $ crunchy-cli archive --universal-output -o https://www.crunchyroll.com/watch/G7PU4XD48/tales-veldoras-journal-2\n  ```\n\n- \u003cspan id=\"archive-resolution\"\u003eResolution\u003c/span\u003e\n\n  The resolution for videos can be set via the `-r` / `--resolution` flag.\n\n  ```shell\n  $ crunchy-cli archive -r worst https://www.crunchyroll.com/series/GY8VEQ95Y/darling-in-the-franxx\n  ```\n\n  Default is `best`.\n\n- \u003cspan id=\"archive-merge\"\u003eMerge behavior\u003c/span\u003e\n\n  Due to censorship or additional intros, some episodes have multiple lengths for different languages.\n  In the best case, when multiple audio \u0026 subtitle tracks are used, there is only one *video* track and all other languages can be stored as audio-only.\n  But, as said, this is not always the case.\n  With the `-m` / `--merge` flag you can define the behaviour when an episodes' video tracks differ in length.\n  Valid options are `audio` - store one video and all other languages as audio only; `video` - store the video + audio for every language; `auto` - detect if videos differ in length: if so, behave like `video` - otherwise like `audio`; `sync` - detect if videos differ in length: if so, it tries to find the offset of matching audio parts and removes the offset from the beginning, otherwise it behaves like `audio`.\n  Subtitles will always match the primary audio and video.\n\n  ```shell\n  $ crunchy-cli archive -m audio https://www.crunchyroll.com/series/GY8VEQ95Y/darling-in-the-franxx\n  ```\n\n  Default is `auto`.\n\n- \u003cspan id=\"archive-merge-time-tolerance\"\u003eMerge time tolerance\u003c/span\u003e\n\n  Sometimes two video tracks are downloaded with `--merge` set to `auto` even if they only differ some milliseconds in length which shouldn't be noticeable to the viewer.\n  To prevent this, you can specify a range in milliseconds with the `--merge-time-tolerance` flag that only downloads one video if the length difference is in the given range.\n\n  ```shell\n  $ crunchy-cli archive -m auto --merge-time-tolerance 100 https://www.crunchyroll.com/series/GY8VEQ95Y/darling-in-the-franxx\n  ```\n  \n  Default are `200` milliseconds.\n\n- \u003cspan id=\"archive-merge-sync-tolerance\"\u003eMerge sync tolerance\u003c/span\u003e\n\n  Sometimes two video tracks are downloaded with `--merge` set to `sync` because the audio fingerprinting fails to identify matching audio parts (e.g. opening).\n  To prevent this, you can use the `--merge-sync-tolerance` flag to specify the difference by which two fingerprints are considered equal.\n\n  ```shell\n  $ crunchy-cli archive -m sync --merge-sync-tolerance 3 https://www.crunchyroll.com/watch/GRDQPM1ZY/alone-and-lonesome\n  ```\n\n  Default is `6`.\n\n- \u003cspan id=\"archive-merge-sync-precision\"\u003eMerge sync precision\u003c/span\u003e\n\n  If you use `--merge` set to `sync` and the syncing seems to be not accurate enough or takes to long, you can use the `--sync-precision` flag to specify the amount of offset determination runs from which the final offset is calculated.\n\n  ```shell\n  $ crunchy-cli archive -m sync --merge-sync-precision 3 https://www.crunchyroll.com/watch/GRDQPM1ZY/alone-and-lonesome\n  ```\n\n  Default is `4`.\n\n- \u003cspan id=\"archive-language-tagging\"\u003eLanguage tagging\u003c/span\u003e\n\n  You can force the usage of a specific language tagging in the output file with the `--language-tagging` flag.\n  This might be useful as some video players doesn't recognize the language tagging Crunchyroll uses internally.\n\n  ```shell\n  $ crunchy-cli archive --language-tagging ietf https://www.crunchyroll.com/series/GY8VEQ95Y/darling-in-the-franxx\n  ```\n\n- \u003cspan id=\"archive-ffmpeg-preset\"\u003eFFmpeg Preset\u003c/span\u003e\n\n  You can specify specific built-in presets with the `--ffmpeg-preset` flag to convert videos to a specific coding while downloading.\n  Multiple predefined presets how videos should be encoded (h264, h265, av1, ...) are available, you can see them with `crunchy-cli archive --help`.\n  If you need more specific ffmpeg customizations you could either convert the output file manually or use ffmpeg output arguments as value for this flag.\n\n  ```shell\n  $ crunchy-cli archive --ffmpeg-preset av1-lossless https://www.crunchyroll.com/watch/GRDQPM1ZY/alone-and-lonesome\n  ```\n\n- \u003cspan id=\"archive-ffmpeg-threads\"\u003eFFmpeg threads\u003c/span\u003e\n\n  If you want to manually set how many threads FFmpeg should use, you can use the `--ffmpeg-threads` flag. This does not work with every codec/preset and is skipped entirely when specifying custom ffmpeg output arguments instead of a preset for `--ffmpeg-preset`.\n\n  ```shell\n  $ crunchy-cli archive --ffmpeg-threads 4 https://www.crunchyroll.com/watch/GRDQPM1ZY/alone-and-lonesome\n  ```\n\n- \u003cspan id=\"archive-default-subtitle\"\u003eDefault subtitle\u003c/span\u003e\n\n  `--default-subtitle` Set which subtitle language is to be flagged as **default** and **forced**.\n\n  ```shell\n  $ crunchy-cli archive --default-subtitle en-US https://www.crunchyroll.com/series/GY8VEQ95Y/darling-in-the-franxx\n  ```\n\n  Default is none.\n\n- \u003cspan id=\"archive-include-fonts\"\u003eInclude fonts\u003c/span\u003e\n\n  You can include the fonts required by subtitles directly into the output file with the `--include-fonts` flag. This will use the embedded font for subtitles instead of the system font when playing the video in a video player which supports it.\n\n  ```shell\n  $ crunchy-cli archive --include-fonts https://www.crunchyroll.com/series/GY8VEQ95Y/darling-in-the-franxx\n  ```\n\n- \u003cspan id=\"archive-include-chapters\"\u003eInclude chapters\u003c/span\u003e\n\n  Crunchyroll sometimes provide information about skippable events like the intro or credits.\n  These information can be stored as chapters in the resulting video file via the `--include-chapters` flag.\n  This flag only works if `--merge` is set to `audio` because chapters cannot be mapped to a specific video steam.\n\n  ```shell\n  $ crunchy-cli archive --include-chapters https://www.crunchyroll.com/watch/G0DUND0K2/the-journeys-end\n  ```\n\n- \u003cspan id=\"archive-skip-existing\"\u003eSkip existing\u003c/span\u003e\n\n  If you re-download a series but want to skip episodes you've already downloaded, the `--skip-existing` flag skips the already existing/downloaded files.\n\n  ```shell\n  $ crunchy-cli archive --skip-existing https://www.crunchyroll.com/series/GY8VEQ95Y/darling-in-the-franxx\n  ```\n\n- \u003cspan id=\"archive-skip-existing-method\"\u003eSkip existing method\u003c/span\u003e\n\n  By default, already existing files are determined by their name and the download of the corresponding episode is skipped.\n  But sometimes Crunchyroll adds dubs or subs to an already existing episode and these changes aren't recognized and `--skip-existing` just skips it.\n  This behavior can be changed by the `--skip-existing-method` flag. Valid options are `audio` and `subtitle` (if the file already exists but the audio/subtitle are less from what should be downloaded, the episode gets downloaded and the file overwritten).\n\n  ```shell\n  $ crunchy-cli archive --skip-existing-method audio --skip-existing-method video https://www.crunchyroll.com/series/GY8VEQ95Y/darling-in-the-franxx\n  ```\n\n- \u003cspan id=\"archive-skip-specials\"\u003eSkip specials\u003c/span\u003e\n\n  If you doesn't want to download special episodes, use the `--skip-specials` flag to skip the download of them.\n\n  ```shell\n  $ crunchy-cli archive --skip-specials https://www.crunchyroll.com/series/GYZJ43JMR/that-time-i-got-reincarnated-as-a-slime[S2]\n  ```\n\n- \u003cspan id=\"archive-yes\"\u003eYes\u003c/span\u003e\n\n  Sometimes different seasons have the same season number (e.g. Sword Art Online Alicization and Alicization War of Underworld are both marked as season 3), in such cases an interactive prompt is shown which needs user further user input to decide which season to download.\n  The `--yes` flag suppresses this interactive prompt and just downloads all seasons.\n\n  ```shell\n  $ crunchy-cli archive --yes https://www.crunchyroll.com/series/GR49G9VP6/sword-art-online\n  ```\n\n  If you've passed the `-q` / `--quiet` [global flag](#global-settings), this flag is automatically set.\n\n- \u003cspan id=\"archive-threads\"\u003eThreads\u003c/span\u003e\n\n  To increase the download speed, video segments are downloaded simultaneously by creating multiple threads.\n  If you want to manually specify how many threads to use when downloading, do this with the `-t` / `--threads` flag.\n\n  ```shell\n  $ crunchy-cli archive -t 1 https://www.crunchyroll.com/series/GY8VEQ95Y/darling-in-the-franxx\n  ```\n  \n  The default thread count is the count of cpu threads your pc has.\n\n### Search\n\nThe `search` command is a powerful tool to query the Crunchyroll library.\nIt behaves like the regular search on the website but is able to further process the results and return everything it can find, from the series title down to the raw stream url.\n_Using this command with the `--anonymous` flag or a non-premium account may return incomplete results._\n\n**Supported urls/input**\n\n- Single episode (with [episode filtering](#episode-filtering))\n  ```shell\n  $ crunchy-cli search https://www.crunchyroll.com/watch/GRDQPM1ZY/alone-and-lonesome\n  ```\n- Series (with [episode filtering](#episode-filtering))\n  ```shell\n  $ crunchy-cli search https://www.crunchyroll.com/series/GY8VEQ95Y/darling-in-the-franxx\n  ```\n- Search input\n  ```shell\n  $ crunchy-cli search \"darling in the franxx\"\n  ```\n\n**Options**\n\n- \u003cspan id=\"search-audio\"\u003eAudio\u003c/span\u003e\n\n  Set the audio language to search via the `--audio` flag. Can be used multiple times.\n\n  ```shell\n  $ crunchy-cli search --audio en-US https://www.crunchyroll.com/series/GY8VEQ95Y/darling-in-the-franxx\n  ```\n\n  Default is your system locale.\n\n- \u003cspan id=\"search-result-limit\"\u003eResult limit\u003c/span\u003e\n\n  If your input is a search term instead of an url, you have multiple options to control which results to process.\n  The `--search-top-results-limit` flag sets the limit of top search results to process.\n  `--search-series-limit` sets the limit of only series, `--search-movie-listing-limit` of only movie listings, `--search-episode-limit` of only episodes and `--search-music-limit` of only concerts and music videos.\n\n  ```shell\n  $ crunchy-cli search --search-top-results-limit 10 \"darling in the franxx\"\n  # only return series which have 'darling' in it. do not return top results which might also be non-series items\n  $ crunchy-cli search --search-top-results-limit 0 --search-series-limit 10 \"darling\"\n  # this returns 2 top results, 3 movie listings, 5 episodes and 1 music item as result\n  $ crunchy-cli search --search-top-results-limit 2 --search-movie-listing-limit 3 --search-episode-limit 5 --search-music-limit 1 \"test\"\n  ```\n\n  Default is `5` for `--search-top-results-limit`, `0` for all others.\n\n- Output template\n\n  The search command is designed to show only the specific information you want.\n  This is done with the `-o`/`--output` flag.\n  You can specify keywords in a specific pattern, and they will get replaced in the output text.\n  The required pattern for this begins with `{{`, then the keyword, and closes with `}}` (e.g. `{{episode.title}}`).\n  For example, if you want to get the title of an episode, you can use `Title: {{episode.title}}` and `{{episode.title}}` will be replaced with the episode title.\n  You can see all supported keywords with `crunchy-cli search --help`.\n\n  ```shell\n  $ crunchy-cli search -o \"{{series.title}}\" https://www.crunchyroll.com/series/GY8VEQ95Y/darling-in-the-franxx\n  ```\n\n  Default is `S{{season.number}}E{{episode.number}} - {{episode.title}}`.\n\n---\n\n#### Output Template Options\n\nYou can use various template options to change how the filename is processed. The following tags are available:\n\n- `{title}`                    → Title of the video\n- `{series_name}`              → Name of the series\n- `{season_name}`              → Name of the season\n- `{audio}`                    → Audio language of the video\n- `{width}`                    → Width of the video\n- `{height}`                   → Height of the video\n- `{season_number}`            → Number of the season\n- `{episode_number}`           → Number of the episode\n- `{relative_episode_number}`  → Number of the episode relative to its season\n- `{sequence_number}`          → Like `{episode_number}` but without possible non-number characters\n- `{relative_sequence_number}` → Like `{relative_episode_number}` but with support for episode 0's and .5's\n- `{release_year}`             → Release year of the video\n- `{release_month}`            → Release month of the video\n- `{release_day} `             → Release day of the video\n- `{series_id}`                → ID of the series\n- `{season_id}`                → ID of the season\n- `{episode_id}`               → ID of the episode\n\nExample:\n\n```shell\n$ crunchy-cli archive -o \"[S{season_number}E{episode_number}] {title}.mkv\" https://www.crunchyroll.com/series/G8DHV7W21/dragon-ball\n# Output file: '[S01E01] Secret of the Dragon Ball.mkv'\n```\n\n#### Episode filtering\n\nFilters patterns can be used to download a specific range of episodes from a single series.\n\nA filter pattern may consist of either a season, an episode, or a combination of the two.\nWhen used in combination, seasons `S` must be defined before episodes `E`.\n\nThere are many possible patterns, for example:\n\n- `...[E5]` - Download the fifth episode.\n- `...[S1]` - Download the whole first season.\n- `...[-S2]` - Download the first two seasons.\n- `...[S3E4-]` - Download everything from season three, episode four, onwards.\n- `...[S1E4-S3]` - Download season one, starting at episode four, then download season two and three.\n- `...[S3,S5]` - Download season three and five.\n- `...[S1-S3,S4E2-S4E6]` - Download season one to three, then episodes two to six from season four.\n\nIn practice, it would look like this:\n\n```\nhttps://www.crunchyroll.com/series/GY8VEQ95Y/darling-in-the-franxx[E1-E5]\n```\n\n# 📜 Disclaimer\n\nThis tool is meant for private use only.\nYou need a [Crunchyroll Premium](https://www.crunchyroll.com/welcome#plans) subscription to access premium content.\n\n**You are entirely responsible for what happens when you use crunchy-cli.**\n\n# ⚖ License\n\nThis project is licensed under the MIT License - see the [LICENSE](LICENSE) file for more details.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcrunchy-labs%2Fcrunchy-cli","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcrunchy-labs%2Fcrunchy-cli","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcrunchy-labs%2Fcrunchy-cli/lists"}