SponsorBlock

Imatge

Spon­sor­Block is an open-source crowd­sour­ced brow­ser exten­sion to skip spon­sor segments in YouTube videos. Users submit when a spon­sor happens from the exten­sion, and the exten­sion auto­ma­ti­cally skips spon­sors it knows about. It also supports skip­ping other cate­go­ries, such as intros, outros and remin­ders to subs­cribe.

It also supports Invi­dio.us.

 

Impor­tant Links

See the Wiki for impor­tant links.

 

Server

The backend server code is avai­la­ble here: https://github.com/ajayyy/Spon­sor­Block­Ser­ver

To make sure that this project doesn’t die, I have made the data­base publicly down­lo­a­da­ble at https://spon­sor.ajay.app/data­base (License). If you are plan­ning on using the data­base in anot­her project, please read the API Docs page for more infor­ma­tion.

The data­set and API are now being used in some ports as well as a neural network.

 

API

You can read the API docs here.

 

Buil­ding

Rename config.json.exam­ple to config.json and adjust confi­gu­ra­tion as desi­red.

There are also other build scripts avai­la­ble. Install npm, then run npm install in the repo­si­tory to install depen­den­cies.

Run npm run build to gene­rate a Chrome exten­sion.

Use npm run build:fire­fox to gene­rate a Fire­fox exten­sion.

The result is in dist. This can be loaded as an unpac­ked exten­sion

 

Deve­lo­ping with a clean profile

Run npm run dev to run the exten­sion using a clean brow­ser profile with hot relo­a­ding. Use npm run dev:fire­fox for Fire­fox. This uses web-ext run.

Known chro­mium bug: Exten­sion is not loaded properly on first start. Visit chrome://exten­si­ons/ and reload the exten­sion.

For Fire­fox for Android, use npm run dev:fire­fox-android— —adb-device <ip-address of the device>. See the Fire­fox docu­men­ta­tion for more infor­ma­tion.

 

Attri­bu­tion Gene­ra­tion

If you contri­bute and add a depen­dency, update the attri­bu­tion file using the follo­wing steps:

Make sure the attri­bu­tion gene­ra­tor is insta­lled: npm i -g oss-attri­bu­tion-gene­ra­tor

gene­rate-attri­bu­tion
mv ./oss-attri­bu­tion/attri­bu­tion.txt ./public/oss-attri­bu­tion/attri­bu­tion.txt

 

Credit

The awesome Invi­di­ous API was previ­ously used, and the server is now using NewLeaf as a to get video info from YouTube.

Origi­nally forked from YTSpon­sorS­kip, but very little code remains.

Icons made by:

 

License

This project is licen­sed under GNU LGPL v3 or any later version