Skip to content

Instantly share code, notes, and snippets.

@Amodio
Created January 31, 2026 06:45
Show Gist options
  • Select an option

  • Save Amodio/c46c65ad76f7b3a305294dc811961d62 to your computer and use it in GitHub Desktop.

Select an option

Save Amodio/c46c65ad76f7b3a305294dc811961d62 to your computer and use it in GitHub Desktop.
Copy the video links of Anime-Sama in a single click.
// ==UserScript==
// @name Anime Sama
// @namespace https://anime-sama.eu/
// @version 2025-11-07
// @description Download animes with one click/command
// @author You
// @match https://anime-sama.org/catalogue/*
// @match https://anime-sama.fr/catalogue/*
// @match https://anime-sama.eu/catalogue/*
// @match https://anime-sama.si/catalogue/*
// @icon https://www.google.com/s2/favicons?sz=64&domain=anime-sama.eu
// @grant none
// ==/UserScript==
(function() {
'use strict';
var nextBtn = document.getElementById("nextEpisode");
if (nextBtn) {
var eps = window.eps1 || window.eps2 || window.eps3;
var eps2 = eps == window.eps1 ? window.eps2 || window.eps3 : window.eps3;
var btn = document.createElement("button");
var btn2 = document.createElement("button2");
btn.id = "copyYtDlpBtn";
btn.className = "flex bg-emerald-700 hover:opacity-80 rounded uppercase font-semibold text-white justify-center items-center cursor-pointer outline outline-gray-500 outline-1 py-1 p-3 mr-5 my-2 transition-all duration-200";
btn.innerHTML = `
<svg xmlns="http://www.w3.org/2000/svg" class="h-7 w-7 md:h-5 md:w-5 md:mr-3" viewBox="0 0 20 20" fill="currentColor">
<path fill-rule="evenodd" d="M4 4a2 2 0 012-2h4a2 2 0 012 2v2h2a2 2 0 012 2v8a2 2 0 01-2 2H8a2 2 0 01-2-2v-2H4a2 2 0 01-2-2V6a2 2 0 012-2h2V4z" clip-rule="evenodd"></path>
</svg>
<p class="hidden md:block">Copy yt-dlp cmd</p>
`;
btn2.id = "copyYtDlpBtn2";
btn2.className = "flex bg-emerald-700 hover:opacity-80 rounded uppercase font-semibold text-white justify-center items-center cursor-pointer outline outline-gray-500 outline-1 py-1 p-3 mr-5 my-2 transition-all duration-200";
btn2.innerHTML = `
<svg xmlns="http://www.w3.org/2000/svg" class="h-7 w-7 md:h-5 md:w-5 md:mr-3" viewBox="0 0 20 20" fill="currentColor">
<path fill-rule="evenodd" d="M4 4a2 2 0 012-2h4a2 2 0 012 2v2h2a2 2 0 012 2v8a2 2 0 01-2 2H8a2 2 0 01-2-2v-2H4a2 2 0 01-2-2V6a2 2 0 012-2h2V4z" clip-rule="evenodd"></path>
</svg>
<p class="hidden md:block">Copy² yt-dlp cmd</p>
`;
btn.onclick = function () {
navigator.clipboard.writeText("yt-dlp " + eps.join(" ").replaceAll("vidmoly.to", "vidmoly.net"));
};
btn2.onclick = function () {
navigator.clipboard.writeText("yt-dlp " + eps2.join(" ").replaceAll("vidmoly.to", "vidmoly.net"));
};
// insert after the "Suivant" button
nextBtn.insertAdjacentElement("afterend", btn2);
nextBtn.insertAdjacentElement("afterend", btn);
}
})();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment