diff options
Diffstat (limited to 'scripts')
-rw-r--r-- | scripts/prep-librewolf-dpkg.conf | 8 | ||||
-rwxr-xr-x | scripts/prep-librewolf-dpkg.sh | 193 |
2 files changed, 45 insertions, 156 deletions
diff --git a/scripts/prep-librewolf-dpkg.conf b/scripts/prep-librewolf-dpkg.conf index f18b018..d480445 100644 --- a/scripts/prep-librewolf-dpkg.conf +++ b/scripts/prep-librewolf-dpkg.conf @@ -1,14 +1,14 @@ # Config file for prep-librewolf-dpkg.sh # Configure these settings before running that script. -# Available options for DISTRO: ubuntu debian +# Available options for DISTRO: debian DISTRO=${DISTRO:-'debian'} # current version of Firefox package in target distro -distro_firefox_version=${distro_firefox_version:-'99.0-1'} +distro_firefox_version=${distro_firefox_version:-'100.0.2-1'} # current version of Firefox, as defined by name of the orig tarball. -firefox_version=${firefox_version:-'99.0'} +firefox_version=${firefox_version:-'100.0.2'} # Tag for LibreWolf linux repo -librewolf_version=${librewolf_version:-'99.0-2'} +librewolf_version=${librewolf_version:-'100.0.2-1'} settings_commit=${settings_commit:-'master'} CI_PROJECT_DIR=${CI_PROJECT_DIR:-$(realpath $(dirname $0)/../)} output_dir=${CI_PROJECT_DIR}/out diff --git a/scripts/prep-librewolf-dpkg.sh b/scripts/prep-librewolf-dpkg.sh index 554d9c2..1b6cc79 100755 --- a/scripts/prep-librewolf-dpkg.sh +++ b/scripts/prep-librewolf-dpkg.sh @@ -1,7 +1,7 @@ #!/bin/sh # File: prep-librewolf-dpkg.sh # Location: https://gitlab.com/bgstack15/librewolf-linux.git -# Latest supported version: librewolf-99.0-1 +# Latest supported version: librewolf-100.0-1 # Author: bgstack15 # SPDX-License-Identifier: CC-BY-SA-4.0 # Startdate: 2020-11-29 @@ -196,162 +196,51 @@ librewolf/stop-undesired-requests.patch -p1 librewolf/about-dialog.patch -p1 EOF else - # for 99.0, the vpn-ad one appears to be broken, but also unnecessary? - cp -pr $( sed -r "${git_source_dir}"/source/assets/patches.txt -e "s@^@/${git_source_dir}/source/@" -e '/vpn-ad/d' ) \ - "${debian_dir}"/patches/librewolf/ - awk -F'/' '{print "librewolf/"$NF}' "${git_source_dir}"/source/assets/patches.txt | \ - sed -r -e 's@$@ -p1@' -e '/vpn-ad/d' >> "${debian_dir}"/patches/series - # For 99.0 to fix this patch. - cat <<EOF >"${debian_dir}/patches/librewolf/remove-branding-urlbar.patch" ---- a/browser/locales/en-US/browser/browser.ftl.orig 2022-03-22 12:57:21.330016999 -0400 -+++ b/browser/locales/en-US/browser/browser.ftl 2022-03-22 13:01:42.740728393 -0400 -@@ -543,7 +543,7 @@ - # A label shown above the "Firefox Suggest" (bookmarks/history) group in the - # urlbar results. - urlbar-group-firefox-suggest = -- .label = { -firefox-suggest-brand-name } -+ .label = Suggestions - - # A label shown above the search suggestions group in the urlbar results. It - # should use sentence case. -EOF - patch -p1 "${debian_dir}/patches/librewolf/remove-organization-policy-banner.patch" <<EOF -diff --git a/patches/ui-patches/remove-organization-policy-banner.patch b/patches/ui-patches/remove-organization-policy-banner.patch -index 688c17c..1475de9 100644 ---- a/patches/ui-patches/remove-organization-policy-banner.patch -+++ b/patches/ui-patches/remove-organization-policy-banner.patch -@@ -1,6 +1,6 @@ - --- a/browser/components/preferences/preferences.js - +++ b/browser/components/preferences/preferences.js --@@ -161,8 +161,6 @@ -+@@ -234,8 +234,6 @@ - this.removeAttribute("keyboard-navigation"); - }); - -@@ -8,4 +8,4 @@ - - - window.addEventListener("hashchange", onHashChange); - -- gotoPref().then(() => { -+ document.getElementById("focusSearch1").addEventListener("command", () => { -EOF - test -n "" && patch -p1 "${debian_dir}/patches/librewolf/ui-patches/remap-links.patch" <<EOF -diff --git a/patches/ui-patches/remap-links.patch b/patches/ui-patches/remap-links.patch -index a1c3966..5d052f6 100644 ---- a/patches/ui-patches/remap-links.patch -+++ b/patches/ui-patches/remap-links.patch -@@ -1,6 +1,6 @@ - --- a/browser/components/preferences/main.js - +++ b/browser/components/preferences/main.js --@@ -311,6 +311,14 @@ -+@@ -312,6 +312,14 @@ var gMainPane = { - "performance"; - performanceSettingsLink.setAttribute("href", performanceSettingsUrl); - -@@ -15,7 +15,7 @@ - this.updateDefaultPerformanceSettingsPref(); - - let defaultPerformancePref = Preferences.get( --@@ -542,7 +550,7 @@ -+@@ -543,7 +551,7 @@ var gMainPane = { - - let drmInfoURL = - Services.urlFormatter.formatURLPref("app.support.baseURL") + -@@ -24,7 +24,7 @@ - document - .getElementById("playDRMContentLink") - .setAttribute("href", drmInfoURL); --@@ -869,7 +877,8 @@ -+@@ -870,7 +878,8 @@ var gMainPane = { - - const link = document.getElementById("browserContainersLearnMore"); - link.href = -@@ -36,7 +36,7 @@ - this.readBrowserContainersCheckbox(); - --- a/browser/components/preferences/privacy.js - +++ b/browser/components/preferences/privacy.js --@@ -282,7 +282,7 @@ -+@@ -283,7 +283,7 @@ function setUpContentBlockingWarnings() - let links = document.querySelectorAll(".contentBlockWarningLink"); - let contentBlockingWarningUrl = - Services.urlFormatter.formatURLPref("app.support.baseURL") + -@@ -45,7 +45,7 @@ - for (let link of links) { - link.setAttribute("href", contentBlockingWarningUrl); - } --@@ -477,7 +477,7 @@ -+@@ -478,7 +478,7 @@ var gPrivacyPane = { - let link = document.getElementById("httpsOnlyLearnMore"); - let httpsOnlyURL = - Services.urlFormatter.formatURLPref("app.support.baseURL") + -@@ -54,7 +54,7 @@ - link.setAttribute("href", httpsOnlyURL); - - // Set radio-value based on the pref value --@@ -643,7 +643,7 @@ -+@@ -644,7 +644,7 @@ var gPrivacyPane = { - ); - const breachAlertsLearnMoreUrl = - Services.urlFormatter.formatURLPref("app.support.baseURL") + -@@ -63,7 +63,7 @@ - breachAlertsLearnMoreLink.setAttribute("href", breachAlertsLearnMoreUrl); - - this._initSafeBrowsing(); --@@ -750,7 +750,7 @@ -+@@ -751,7 +751,7 @@ var gPrivacyPane = { - ); - let url = - Services.urlFormatter.formatURLPref("app.support.baseURL") + -@@ -72,7 +72,7 @@ - document.getElementById("siteDataLearnMoreLink").setAttribute("href", url); - - let notificationInfoURL = --@@ -923,7 +923,7 @@ -+@@ -924,7 +924,7 @@ var gPrivacyPane = { - let link = document.getElementById("contentBlockingLearnMore"); - let contentBlockingUrl = - Services.urlFormatter.formatURLPref("app.support.baseURL") + -@@ -81,7 +81,7 @@ - link.setAttribute("href", contentBlockingUrl); - - // Toggles the text "Cross-site and social media trackers" based on the --@@ -2268,7 +2268,7 @@ -+@@ -2276,7 +2276,7 @@ var gPrivacyPane = { - let learnMoreLink = document.getElementById("primaryPasswordLearnMoreLink"); - let learnMoreURL = - Services.urlFormatter.formatURLPref("app.support.baseURL") + -@@ -90,7 +90,7 @@ - learnMoreLink.setAttribute("href", learnMoreURL); - }, - --@@ -2466,7 +2466,7 @@ -+@@ -2474,7 +2474,7 @@ var gPrivacyPane = { - let learnMoreLink = document.getElementById("enableSafeBrowsingLearnMore"); - let phishingUrl = - Services.urlFormatter.formatURLPref("app.support.baseURL") + -@@ -101,7 +101,7 @@ - enableSafeBrowsing.addEventListener("command", function() { - --- a/toolkit/mozapps/extensions/content/aboutaddons.js - +++ b/toolkit/mozapps/extensions/content/aboutaddons.js --@@ -1997,7 +1997,7 @@ -+@@ -1997,7 +1997,7 @@ class SidebarFooter extends HTMLElement - icon: "chrome://global/skin/icons/help.svg", - createLinkElement: () => { - let link = document.createElement("a", { is: "support-link" }); -@@ -109,4 +109,4 @@ - + link.setAttribute("support-page", "do-you-recommend-using-any-extensions"); - link.id = "help-button"; - return link; -- }, -\ No newline at end of file -+ }, -EOF +# # for 99.0, the vpn-ad one appears to be broken, but also unnecessary? +# cp -pr $( sed -r "${git_source_dir}"/source/assets/patches.txt -e "s@^@/${git_source_dir}/source/@" -e '/vpn-ad/d' ) \ +# "${debian_dir}"/patches/librewolf/ +# awk -F'/' '{print "librewolf/"$NF}' "${git_source_dir}"/source/assets/patches.txt | \ +# sed -r -e 's@$@ -p1@' -e '/vpn-ad/d' >> "${debian_dir}"/patches/series +# # For 99.0 to fix this patch. +# cat <<EOF >"${debian_dir}/patches/librewolf/remove-branding-urlbar.patch" +#--- a/browser/locales/en-US/browser/browser.ftl.orig 2022-03-22 12:57:21.330016999 -0400 +#+++ b/browser/locales/en-US/browser/browser.ftl 2022-03-22 13:01:42.740728393 -0400 +#@@ -543,7 +543,7 @@ +# # A label shown above the "Firefox Suggest" (bookmarks/history) group in the +# # urlbar results. +# urlbar-group-firefox-suggest = +#- .label = { -firefox-suggest-brand-name } +#+ .label = Suggestions +# +# # A label shown above the search suggestions group in the urlbar results. It +# # should use sentence case. +#EOF +# patch -p1 "${debian_dir}/patches/librewolf/remove-organization-policy-banner.patch" <<EOF +#diff --git a/patches/ui-patches/remove-organization-policy-banner.patch b/patches/ui-patches/remove-organization-policy-banner.patch +#index 688c17c..1475de9 100644 +#--- a/patches/ui-patches/remove-organization-policy-banner.patch +#+++ b/patches/ui-patches/remove-organization-policy-banner.patch +#@@ -1,6 +1,6 @@ +# --- a/browser/components/preferences/preferences.js +# +++ b/browser/components/preferences/preferences.js +#-@@ -161,8 +161,6 @@ +#+@@ -234,8 +234,6 @@ +# this.removeAttribute("keyboard-navigation"); +# }); +# +#@@ -8,4 +8,4 @@ +# - +# window.addEventListener("hashchange", onHashChange); +# +#- gotoPref().then(() => { +#+ document.getElementById("focusSearch1").addEventListener("command", () => { +#EOF # remove xmas because it does the same tasks as what we accomplish in this script, # and librewolf-pren-pane because it is experimental sed -i -r -e '/(xmas|librewolf-pref-pane)\.patch/s/^/#/;' "${debian_dir}"/patches/series # Fixes to the LibreWolf patches for version 96.0.1. # remove_addons.patch will be fixed when https://gitlab.com/librewolf-community/browser/source/-/merge_requests/10 - test -n "a" && patch -p1 "${debian_dir}/patches/librewolf/remove_addons.patch" <<EOF + test -n "" && patch -p1 "${debian_dir}/patches/librewolf/remove_addons.patch" <<EOF diff --git a/patches/remove_addons.patch b/patches/remove_addons.patch index a6585ed..3487f6d 100644 --- a/patches/remove_addons.patch |