Skip to content

amithm7/webext-open-player

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

45 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Web Extension: Open In Player

Opens URLs (video) in mpv or vlc media players

Installation

1. Install your media players

Supported players:

  • mpv
  • vlc

2. Get the Extension

  • FireFox: Install extension from Mozilla Add-Ons if not already.
  • Chromium Browsers: Download this repo and load unpacked from and point to the src directory here.

3. Setup

Important

For mpv setup, ytdl:// URL's need to be associated with mpv

For vlc setup, vlc:// URL handler needs to be created, such URLs be associate with it

3a. System wide (Linux)

Download and run the install.sh script. Option to choose players will be provided.

chmod +x ./install.sh
./install.sh

3b. mpv can be setup for Firefox browser only:

  • Navigate to address about:support.
  • Look for an entry Profile Directory or Profile Folder (on Windows).
  • Open this directory or folder to find handlers.json file.
  • Open the file to edit it (you may need to format it to be readable, you could do that with your text editor or an online tool like jsonlint.com).
  • In this JSON file, there are few schemes defined, you will need to add a new one named ytdl with and empty object {} at the end of schemes object value, like this:
     "schemes": {
     	// <other schemes here already>,
     	"ytdl": {}
     }
  • Restart Firefox.
  • Navigate to address about:preferences#general and find the Applications section. Here, you will find the ytdl entry.
  • Choose the Action for the ytdl entry as to open with mpv.