Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
39 changes: 23 additions & 16 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,34 +1,41 @@
<h1 align="center">NOTFLIX</h1>
<p align="center">f@#k netflix use notflix a tool which search magnet links and stream it with peerflix</p>

##
<p align="center">
<img src="./preview.gif" alt="Video Preview" width="500px">
</p>

> Watch this video to understand - [bugswriter's notflix](https://youtu.be/FbE19_omaWY)
<h1 align="center">NOTFLIX ANDROID</h1>
<p align="center">f@#k netflix use notflix a tool which search magnet links and stream it with peerflix in VLC Android, based in notflix by bugswriter</p>

### How does this work?

This is a shell script. It scape 1337x and get the magnet link.
After this it use [peerflix](https://github.com/mafintosh/peerflix) to stream the video from magnet link.
For scraping script use simple gnu utils like sed, awk, paste, cut.
This is a shell script. It uses TPB API to get the magnet link.
After this, it uses [peerflix](https://github.com/mafintosh/peerflix) to stream the video from magnet link.
The scraper script uses curl, jq, tr, and other tools in termux, then, it automatically plays it using VLC.

## Requirements

* [peerflix](https://github.com/mafintosh/peerflix) - A tool to stream torrent. `sudo npm install peerflix -g`
* [Termux](https://termux.dev)

* nodejs, jq, curl. In termux `pkg i nodejs-lts jq curl`

* [VLC](https://www.videolan.org/vlc/download-android.html)

* [peerflix](https://github.com/mafintosh/peerflix) - A tool to stream torrent. `npm install peerflix -g`

* modify torrent-stream to use termux /tmp folder instead of Android's one. `nano ../usr/lib/node_modules/peerflix/node_modules/torrent-stream/index.js` change in line 36 `/tmp` to `../usr/tmp`

## Installation

### cURL
cURL **notflix** to your **$PATH** and give execute permissions.

```sh
$ sudo curl -sL "https://raw.githubusercontent.com/Bugswriter/notflix/master/notflix" -o /usr/local/bin/notflix
$ sudo chmod +x /usr/local/bin/notflix
$ curl -sL "https://raw.githubusercontent.com/mgueji/notflix-android/android/notflix" -o /data/data/com.termux/files/usr/bin/notflix
$ chmod +x /data/data/com.termux/files/usr/bin/notflix
```
- To update, just do `curl` again, no need to `chmod` anymore.
- To uninstall, simply remove `notflix` from your **$PATH**, for example `sudo rm -f /usr/local/bin/notflix.
- To uninstall, simply remove `notflix` from your **$PATH**, for example `rm -f /data/data/com.termux/files/usr/bin/notflix

## Usage

`notflix query`

For example, to watch a TV show use `notflix Show Name s01e01` were s01 is the season number and e01 is the episode number, this will start playing the first result on the search from TPB.org that usually is the best, you can also add the resolution `notflix Show Name s02e03 1080p` for better results.

## License
This project is licensed under [GPL-3.0](https://raw.githubusercontent.com/Illumina/licenses/master/gpl-3.0.txt).
Expand Down
11 changes: 6 additions & 5 deletions notflix
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
#!/bin/sh
#!/data/data/com.termux/files/usr/bin/bash

query=$(printf '%s' "$*" | tr ' ' '+' )
movie=$(curl -s https://1337x.to/search/$query/1/ | grep -Eo "torrent\/[0-9]{7}\/[a-zA-Z0-9?%-]*/" | head -n 1)
magnet=$(curl -s https://1337x.to/$movie | grep -Po "magnet:\?xt=urn:btih:[a-zA-Z0-9]*" | head -n 1)
peerflix -l -k $magnet
query=$(printf '%s' "$*" | tr ' ' '+')
magnet=$(curl -s "https://apibay.org/q.php?q=$query" | jq -r '.[0].info_hash')
peerflix $magnet &
sleep 5
am start -n org.videolan.vlc/org.videolan.vlc.gui.video.VideoPlayerActivity -a android.intent.action.VIEW -d http://127.0.0.1:8888