magnet-scrape-cli

CLI wrapper for magnet-scrape

Usage no npm install needed!

<script type="module">
  import magnetScrapeCli from 'https://cdn.skypack.dev/magnet-scrape-cli';
</script>

README

magnet-scrape

CLI wrapper for magnet-scrape

  • magnet-scrape works with any site that contains magnet links in the response!

Install

npm i -g magnet-scrape-cli

Usage

curl https://domain.tld/search?q=example | magnet-scrape | head -1

Advanced Usage

Copy link to clipboard: curl & xclip
curl -GL 'https://thepiratebay.org/s/?apps=on\&page=0\&orderby=99' --data-urlencode "q=ubuntu desktop" | magnet-scrape | head -1 | xclip -sel clipboard -i
Download Ubuntu Desktop: curl & aria2
aria2c $(curl -GL 'https://thepiratebay.org/s/?apps=on\&page=0\&orderby=99' --data-urlencode "q=ubuntu desktop" | magnet-scrape | head -1)
Stream videos: curl & peerflix
#!/bin/bash

set -e
peerflix $(curl -GL 'https://thepiratebay.org/s/?video=on\&page=0\&orderby=99' --data-urlencode "q=$*" | magnet-scrape | head -1)