diff options
-rwxr-xr-x | scripts/prep-librewolf-dpkg.sh | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/scripts/prep-librewolf-dpkg.sh b/scripts/prep-librewolf-dpkg.sh index 9da9d71..0275fd7 100755 --- a/scripts/prep-librewolf-dpkg.sh +++ b/scripts/prep-librewolf-dpkg.sh @@ -442,17 +442,22 @@ cp -p "${git_source_dir}"/source/assets/search-config.json "${debian_dir}"/ sed -i -r "${debian_dir}"/rules \ -e '/override_dh_auto_configure/a\ cp -pf debian/search-config.json services/settings/dumps/main/' +# Fetch latest uBlock Origin webextensions +latest_ubo_url="$( curl --silent https://api.github.com/repos/gorhill/uBlock/releases/latest | jq '.assets[].browser_download_url | match(".*firefox.*xpi").string' | tr -d '"' )" +curl --silent --output "${debian_dir}/uBlock0@raymondhill.net.xpi" "${latest_ubo_url}" + if test "${DISTRO}" = "debian" ; then cat <<EOF >> "${debian_dir}"/browser.install.in - debian/librewolf_settings/@browser@.cfg usr/share/@browser@ debian/librewolf_settings/defaults/pref/local-settings.js usr/share/@browser@/defaults/pref debian/librewolf_settings/distribution/policies.json usr/share/@browser@/distribution +debian/uBlock0@raymondhill.net.xpi usr/lib/@browser@/browser/extensions +EOF + cat <<EOF >> "${debian_dir}/source/include-binaries" +debian/uBlock0@raymondhill.net.xpi EOF - cat <<EOF >> "${debian_dir}"/browser.links.in - /usr/share/distribution/policies.json usr/lib/@browser@/distribution/policies.json /usr/share/@browser@/defaults/pref/local-settings.js usr/lib/@browser@/defaults/pref/local-settings.js /usr/share/@browser@/@browser@.cfg /usr/lib/@browser@/@browser@.cfg |