From 95ec4f4bdc1f45d9a6b75844a4a1112cb427c724 Mon Sep 17 00:00:00 2001 From: matt1432 Date: Fri, 20 Oct 2023 00:35:03 -0400 Subject: [PATCH] feat(firefox): add ttv-lol-pro addon --- modules/firefox/addons/addons.json | 3 +++ .../addons/generated-firefox-addons.nix | 25 +++++++++++++++++++ modules/firefox/default.nix | 1 + updateSha.sh | 2 +- 4 files changed, 30 insertions(+), 1 deletion(-) diff --git a/modules/firefox/addons/addons.json b/modules/firefox/addons/addons.json index 169ac58..6b34664 100644 --- a/modules/firefox/addons/addons.json +++ b/modules/firefox/addons/addons.json @@ -8,6 +8,9 @@ { "slug": "checkmarks-web-ext" }, + { + "slug": "ttv-lol-pro" + }, { "slug": "opera-gx-witchcraft-purple" } diff --git a/modules/firefox/addons/generated-firefox-addons.nix b/modules/firefox/addons/generated-firefox-addons.nix index 44e40f6..b46b882 100644 --- a/modules/firefox/addons/generated-firefox-addons.nix +++ b/modules/firefox/addons/generated-firefox-addons.nix @@ -77,4 +77,29 @@ platforms = platforms.all; }; }; + "ttv-lol-pro" = buildFirefoxXpiAddon { + pname = "ttv-lol-pro"; + version = "2.2.1"; + addonId = "{76ef94a4-e3d0-4c6f-961a-d38a429a332b}"; + url = "https://addons.mozilla.org/firefox/downloads/file/4179399/ttv_lol_pro-2.2.1.xpi"; + sha256 = "83d012878021fb5fe25bee1101a7a760974ae9e2949b80fd99b73d3da48b1f99"; + meta = with lib; + { + homepage = "https://github.com/younesaassila/ttv-lol-pro"; + description = "TTV LOL PRO removes most livestream ads from Twitch."; + license = licenses.gpl3; + mozPermissions = [ + "proxy" + "storage" + "webRequest" + "webRequestBlocking" + "https://*.ttvnw.net/*" + "https://*.twitch.tv/*" + "https://perfprod.com/ttvlolpro/telemetry" + "https://www.twitch.tv/*" + "https://m.twitch.tv/*" + ]; + platforms = platforms.all; + }; + }; } \ No newline at end of file diff --git a/modules/firefox/default.nix b/modules/firefox/default.nix index 2fe8a7a..bf47e58 100644 --- a/modules/firefox/default.nix +++ b/modules/firefox/default.nix @@ -162,6 +162,7 @@ in sound-volume google-container checkmarks-web-ext + ttv-lol-pro opera-gx-witchcraft-purple ]); }; diff --git a/updateSha.sh b/updateSha.sh index 4b7e503..af1226e 100755 --- a/updateSha.sh +++ b/updateSha.sh @@ -22,7 +22,7 @@ parseNurl "https://github.com/lukas-reineke/indent-blankline.nvim" updateFirefoxAddons() { echo "Updating firefox addons using mozilla-addons-to-nix" - (cd /home/matt/.nix/nixos/home/firefox/addons || return; + (cd /home/matt/.nix/modules/firefox/addons || return; file=generated-firefox-addons.nix if [[ -f $file ]]; then