dropout-dl/readme.md

116 lines
5.2 KiB
Markdown
Raw Normal View History

2023-02-09 00:42:34 +00:00
<div align="center">
2023-02-09 00:40:32 +00:00
<img src="https://raw.githubusercontent.com/mosswg/dropout-dl/main/assets/dropout_dl_logo.png" width="50%" />
2023-02-09 00:42:34 +00:00
</div>
dropout-dl is tool to download [dropout.tv](https://www.dropout.tv) episodes. It can download single episodes, seasons, or full series.
2022-09-14 01:07:03 +00:00
2022-12-22 03:42:50 +00:00
* [Installation](#installation)
2023-03-18 05:05:42 +00:00
* [Docker](#docker)
2022-12-22 03:42:50 +00:00
* [How to Build](#how-to-build)
* [Dependencies](#Dependencies)
* [Usage](#how-to-use)
2023-03-18 05:05:42 +00:00
* [Options](#options)
* [Login](#login)
* [Cookies](#cookies)
2022-12-22 03:42:50 +00:00
# Installation
2023-03-18 05:05:42 +00:00
## Docker
A docker image was created that makes it easier to build and use dropout-dl. You can simply build the docker image without worrying about installing any system dependencies:
```shell
docker build -t dropout-dl:latest .
```
After its done building, you can use it by adding your arguments to the end of the `docker run` command:
```shell
docker run --rm -it -v $PWD/login:/app/login -v $PWD/out:/Downloads dropout-dl:latest --output-directory /Downloads --captions -e https://www.dropout.tv/dimension-20/season:10/videos/the-chosen-ones
```
**Note:** The docker image expects the `login` file to be at `/app/login`.\
You must specify an output directory and mount that directory to the host so that you can retrieve the files from the docker container. In the above command I tell dropout-dl to output everything in `/Downloads` inside the container, which is mounted to a folder named `out` inside the current directory (`$PWD` is current directory).
2022-10-01 02:54:00 +00:00
## How to Build
2022-09-14 01:07:03 +00:00
```
cmake -S <source-dir> -B <build-dir>
cd <build-dir>
make
```
2022-12-22 03:42:50 +00:00
### Dependencies
### Required
2022-12-22 03:49:20 +00:00
* [cURL](https://curl.se/libcurl/) - Required for downloading pages and videos.
2022-12-22 03:42:50 +00:00
### Optional
2023-02-05 19:40:07 +00:00
* [SQLite](https://www.sqlite.org/index.html) - Required for retrieving cookies from browsers.
2022-12-22 03:42:50 +00:00
* [libgcrypt](https://www.gnupg.org/software/libgcrypt/index.html) - Used for decrypting chrome cookies retrieved from the sqlite database.
2022-09-14 01:07:03 +00:00
#### Void
2022-09-14 01:07:03 +00:00
```
2023-02-05 19:40:07 +00:00
sudo xbps-install -S libcurl
2022-09-14 01:07:03 +00:00
```
#### Debian
2022-09-14 01:07:03 +00:00
```
2023-02-05 19:40:07 +00:00
sudo apt install libcurl4-gnutls-dev
2022-09-14 01:07:03 +00:00
```
2022-09-29 03:15:20 +00:00
## How to Use
2022-09-14 01:07:03 +00:00
```
./dropout-dl [options] <url>
2022-09-29 03:15:20 +00:00
```
By default, dropout-dl will download episodes in a season with the format `<series>/<season>/<series> - S<season-num>E<episode-num> - <episode-name>.mp4` and single episodes with the format `<series>/<season>/<series> - <season> - <episode-name>.mp4`.
2022-09-29 03:15:20 +00:00
### Options
```
2023-02-09 01:58:15 +00:00
--help -h Display this message
--quality -q Set the quality of the downloaded video. Quality can be set to 'all' which
will download all qualities and place them into separate folders
--output -o Set the output filename. Only works for single episode downloads
--output-directory -d Set the directory where files are output
--verbose -v Display debug information while running
--browser-cookies -bc Use cookies from the browser placed in 'firefox_profile' or 'chrome_profile'
--force-cookies Interpret the next to argument as the session cookie
--series -S Interpret the url as a link to a series and download all episodes from all seasons
--season -s Interpret the url as a link to a season and download all episodes from all seasons
--episode -e Interpret the url as a link to a single episode
--captions -c Download the captions along with the episode
2022-09-14 01:07:03 +00:00
```
If series, season, or episode is not used, the type will be inferred based on the link format.
2023-02-05 19:40:07 +00:00
### Login
Login in information must be placed in a file called `login` in the same directory as the executable. The file must be email then on a new line password. For example if your email is `email@example.com` and password `password123` the file would be:
```
email@example.com
password123
```
### Cookies
If you would like to avoid putting logging in for any reason cookies can be used. The option `browser-cookies` must be provided.
#### Firefox
2022-12-22 03:42:50 +00:00
Create a file named `firefox_profile` in the build directory and paste in your [firefox profile folder path](https://support.mozilla.org/en-US/kb/profiles-where-firefox-stores-user-data)
2023-02-05 19:40:07 +00:00
#### Chrome
2022-12-22 03:42:50 +00:00
Install libgcrypt and create a file named `chrome_profile` in the build directory and paste in your chrome profile folder path (found on [chrome://version](chrome://version))
2023-02-05 19:40:07 +00:00
#### Other/No Sqlite
2022-12-22 03:42:50 +00:00
Use the `--force-cookies` program option to manually input cookies.
2022-09-30 18:19:38 +00:00
## TODO
- [x] Create tests
- [x] Handle non-alphanumeric characters
- [ ] Test build process on other setups with other OSs.
2022-09-30 18:19:38 +00:00
2022-12-22 03:42:50 +00:00
## Contributing
[![PRs Welcome](https://img.shields.io/badge/PRs-welcome-brightgreen.svg?style=flat-square)](https://makeapullrequest.com)
### Issues
If you have any issues or would like a feature to be added please don't hesitate to submit an issue after checking to make sure it hasn't already been submitted. Using the templates is a good place to start, but sometimes they're overkill. For example, if the program segfaults for you, you don't need to state that the intended behaviour is to not segfault. \
\
If you'd like to contribute a good place to start is looking at open issues and trying to fix one with a pull request. \
**Working on your first Pull Request?** You can learn how from this *free* series [How to Contribute to an Open Source Project on GitHub](https://kcd.im/pull-request)
## Contributors
- Moss - [mossx-dev](https://github.com/mossx-dev)