nyon-stream
A python script that uses webtorrent to stream nyaa videos directly to mpv.
usage
python3 nyaascraper.py <keywords - optional>
important info
This script was made to be a notflix, nyaa edition. It was also designed to be linux-only at first.
You can however run it on other OSes by setting the "TUImode" value to True in the config, at the cost of the fancy menu shown in the demo (you'll have to use your terminal instead)
A Working windows build is in the latest release with the required external dependencies
config
Edit the script on lines 14-21 to change your config
Values:
getDefaultRows
type: boolean (bool)default value: False
description: Get default (white) rows on nyaa
getDangerRows
type: boolean (bool)default value: False
description: Get danger (red) rows on nyaa
TUImode
type: boolean (bool)default value: False
description: Use a tui instead of dmenu, made for windows users and linux users without dmenu
loggingLevel
type: integer (int)default value: logging.ERROR
description: Change the logging level, use logging.INFO or logging.DEBUG to get debug info
maxPageNum
type: integer (int)default value: 5
description: Max page to get on nyaa, if your page number is too high you may encounter some delay
baseUrl
type: string (str)default value: "https://nyaa.si/?s=seeders&o=desc"
description: Change the base url for nyaa, by default searches by most seeders
webtorrentArgs
type: string (str)default value: "--keep-seeding --mpv"
description: Arguments to pass to webtorrent, by default starts mpv
dmenuArgs
type: dictionary (dict)default value: {"font": "Ubuntu-15"}
description: Additional arguments to pass to the dmenu python wrapper
proxies
type: dictionary (dict)default value: None
description: Proxies to use for the nyaa requests
example: {'http': 'socks5://127.0.0.1:9050', 'https': 'socks5://127.0.0.1:9050'} (tor w default port)
/!\These are NOT for the torrent, only the nyaa requests/!\
dependencies
python dependencies
BeautifulSoup
requests
dmenu only if TUImode disabled
external dependencies
dmenu (arch) only if TUImode disabled
webtorrent (arch aur)
For Windows :
wlines (https://github.com/JerwuQu/wlines)
mpv player (executable only)
node (executable only)
webtorrents-cli