Starchive A browser extension and local backend system that automatically archives YouTube videos when visited. The system consists of a Firefox extension that detects YouTube video pages and a Go backend that downloads the videos using yt-dlp. Components Backend (Go) HTTP Server ( main.go ): Runs on port 3009 with two endpoints: / : Basic health check endpoint /youtube : POST endpoint that accepts video IDs and triggers downloads ( ): Runs on port 3009 with two endpoints: Video Downloader ( youtube.go ): Uses yt-dlp and ffmpeg to download YouTube videos and convert them to MOV format with h264_videotoolbox encoding ( ): Uses yt-dlp and ffmpeg to download YouTube videos and convert them to MOV format with h264_videotoolbox encoding Subtitle Support: Downloads English subtitles in VTT format (currently disabled in retry loop) Browser Extension (Firefox) Manifest ( manifest.json ): Defines extension permissions and structure ( ): Defines extension permissions and structure Content Script ( content.js ): Automatically detects YouTube video pages and extracts video IDs from URLs ( ): Automatically detects YouTube video pages and extracts video IDs from URLs Background Script ( background.js ): Handles communication between content script and backend API ( ): Handles communication between content script and backend API Popup Interface ( popup.html/js ): Provides a simple UI for manual data fetching How It Works When you visit a YouTube video page, the content script automatically detects the video ID from the URL The video ID is sent to the background script, which makes a POST request to http://localhost:3009/youtube The Go backend receives the video ID and uses yt-dlp to download the video Videos are saved to the ./data/ directory and converted to MOV format using ffmpeg with hardware acceleration The system also supports subtitle downloading (though currently limited to 1 attempt) Setup Start the Go backend: go run . Load the Firefox extension from the firefox/ direct...
First seen: 2025-08-02 18:15
Last seen: 2025-08-03 03:16