Fixing non-free software link removal patch. Adding feature to replace they/them/their.
This commit is contained in:
@@ -20,49 +20,6 @@ LWD="$PWD"
|
||||
|
||||
echo "Removing links to nonfree services..."
|
||||
|
||||
error() {
|
||||
echo "Failed to patch, exiting..."
|
||||
exit 1
|
||||
}
|
||||
|
||||
cd "${1}"
|
||||
|
||||
|
||||
if test -f ".${1}/src/components/views/dialogs/ShareDialog.tsx"; then
|
||||
|
||||
patchtsx_content=$(cat << EOF
|
||||
--- a${1}/src/components/views/dialogs/ShareDialog.tsx
|
||||
+++ b${1}/src/components/views/dialogs/ShareDialog.tsx
|
||||
@@ -24,26 +24,6 @@ import { useSettingValue } from "../../../hooks/useSettings.ts";
|
||||
|
||||
/* eslint-disable @typescript-eslint/no-require-imports */
|
||||
const SOCIALS = [
|
||||
- {
|
||||
- name: "Facebook",
|
||||
- img: require("../../../../res/img/social/facebook.png"),
|
||||
- url: (url: string) => `https://www.facebook.com/sharer/sharer.php?u=${url}`,
|
||||
- },
|
||||
- {
|
||||
- name: "Twitter",
|
||||
- img: require("../../../../res/img/social/twitter-2.png"),
|
||||
- url: (url: string) => `https://twitter.com/home?status=${url}`,
|
||||
- },
|
||||
- {
|
||||
- name: "LinkedIn",
|
||||
- img: require("../../../../res/img/social/linkedin.png"),
|
||||
- url: (url: string) => `https://www.linkedin.com/shareArticle?mini=true&url=${url}`,
|
||||
- },
|
||||
- {
|
||||
- name: "Reddit",
|
||||
- img: require("../../../../res/img/social/reddit.png"),
|
||||
- url: (url: string) => `https://www.reddit.com/submit?url=${url}`,
|
||||
- },
|
||||
{
|
||||
name: "email",
|
||||
img: require("../../../../res/img/social/email-1.png"),
|
||||
EOF
|
||||
)
|
||||
|
||||
echo "${patchtsx_content}" | patch -t -p1 || error
|
||||
fi
|
||||
cd $1
|
||||
patch --forward -p1 < $LWD/files/remove_nonfree.patch
|
||||
cd $LWD
|
||||
|
||||
Reference in New Issue
Block a user