From 6f336b18d359a4ff53eee012e4710a8b57fdd0cb Mon Sep 17 00:00:00 2001 From: gibbyb Date: Fri, 28 Feb 2025 12:59:09 -0600 Subject: [PATCH] Add a bunch of self hosted services --- .env.example | 8 +++++- README.md | 6 +++++ src/bang.ts | 75 +++++++++++++++++++++++++++++++++++++++++----------- 3 files changed, 72 insertions(+), 17 deletions(-) diff --git a/.env.example b/.env.example index 7c21830..68f1d64 100644 --- a/.env.example +++ b/.env.example @@ -1,10 +1,16 @@ # All environment variables must be prefixed with VITE_ to be seen by client. -# Self-hosted Services URLs. +# Self-hosted Services URLs. Do not include the trailing slash. VITE_BANG_URL="https://bang." VITE_GITEA_URL="https://git." VITE_SEARXNG_URL="https://search." VITE_OPENWEBUI_URL="https://chat." +VITE_NEXTCLOUD_URL="https://apps.cloud." +VITE_PLEX_URL="https://plex." +VITE_OVERSEERR_URL="https://overseerr." +VITE_SONARR_URL="https://sonarr." +VITE_RADARR_URL="https://radarr." +VITE_LIDARR_URL="https://lidarr." # Set default bang here. For example "g" would be Google. # Google is the default if you don't set this. diff --git a/README.md b/README.md index 827f7bb..ee50ddb 100644 --- a/README.md +++ b/README.md @@ -9,6 +9,12 @@ This fork allows anyone to easily self host this service & add bangs for their o - Searxng *!s* - Gitea *!tea* - OpenWebUI *!ai* +- Nextcloud App Store *!cloudapp* +- Plex *!plex* +- Overseerr *!ov* +- Sonarr *!tv* +- Radarr *!mv* +- Lidarr *!mp3* *Note: We have replaced some of the default bangs from duckduckgo with our own bangs in order to have more simple bangs for the self-hosted websites.* diff --git a/src/bang.ts b/src/bang.ts index 5bb0e03..1a42021 100644 --- a/src/bang.ts +++ b/src/bang.ts @@ -3,6 +3,13 @@ const SEARXNG_URL = import.meta.env.VITE_SEARXNG_URL as string; const GITEA_URL = import.meta.env.VITE_GITEA_URL as string; const OPENWEBUI_URL = import.meta.env.VITE_OPENWEBUI_URL as string; +const NEXTCLOUD_APPS_URL = import.meta.env.VITE_NEXTCLOUD_URL as string ?? "https://apps.nextcloud.com"; +const PLEX_URL = import.meta.env.VITE_PLEX_URL as string; +const OVERSEERR_URL = import.meta.env.VITE_OVERSEERR_URL as string; +const SONARR_URL = import.meta.env.VITE_SONARR_URL as string; +const RADARR_URL = import.meta.env.VITE_RADARR_URL as string; +const LIDARR_URL = import.meta.env.VITE_LIDARR_URL as string; + const LLAMA_MODEL = import.meta.env.VITE_LLAMA_MODEL.replace(":", "%3A") as string; const DEEPSEEK_MODEL = import.meta.env.VITE_DEEPSEEK_MODEL.replace(":", "%3A") as string; const OPENAI_MODEL = import.meta.env.VITE_OPENAI_MODEL as string; @@ -27,6 +34,51 @@ export const bangs = [ t: "tea", u: `${GITEA_URL}/?repo-search-query={{{s}}}`, }, + { + c: "Entertainment", + d: PLEX_URL, + r: 0, + s: "Plex", + sc: "Movies", + t: "plex", + u: `${PLEX_URL}/web/index.html#!/search?pivot=top&query=query={{{s}}}`, + }, + { + c: "Entertainment", + d: OVERSEERR_URL, + r: 0, + s: "Overseerr", + sc: "Movies", + t: "ov", + u: `${OVERSEERR_URL}/search?query={{{s}}}`, + }, + { + c: "Entertainment", + d: LIDARR_URL, + r: 0, + s: "Lidarr", + sc: "Music", + t: "mp3", + u: `${LIDARR_URL}/add/new?term={{{s}}}`, + }, + { + c: "Entertainment", + d: SONARR_URL, + r: 0, + s: "Sonarr", + sc: "TV", + t: "tv", + u: `${SONARR_URL}/add/new?term={{{s}}}`, + }, + { + c: "Entertainment", + d: RADARR_URL, + r: 0, + s: "Radarr", + sc: "Movies", + t: "mv", + u: `${RADARR_URL}/add/new?term={{{s}}}`, + }, { c: "AI", d: OPENWEBUI_URL, @@ -71422,7 +71474,7 @@ export const bangs = [ r: 10, s: "Myvideo", sc: "Video", - t: "mv", + t: "myvideo", u: "http://www.myvideo.de/Videos_A-Z?searchWord={{{s}}}", }, { @@ -73531,12 +73583,12 @@ export const bangs = [ }, { c: "Tech", - d: "apps.nextcloud.com", + d: NEXTCLOUD_APPS_URL, r: 0, s: "Nextcloud App Store", sc: "Sysadmin", - t: "nextcloudapp", - u: "https://apps.nextcloud.com/?search={{{s}}}", + t: "cloudapp", + u: `${NEXTCLOUD_APPS_URL}/?q={{{s}}}`, }, { c: "Entertainment", @@ -78861,7 +78913,7 @@ export const bangs = [ r: 0, s: "StackOverflow", sc: "Programming", - t: "ov", + t: "ovfl", u: "http://stackoverflow.com/search?q={{{s}}}", }, { @@ -106814,15 +106866,6 @@ export const bangs = [ t: "tva", u: "https://tweakers.net/aanbod/zoeken/?keyword={{{s}}}", }, - { - c: "Entertainment", - d: "www.tv.com", - r: 0, - s: "TV.com", - sc: "TV", - t: "tvcom", - u: "http://www.tv.com/search?q={{{s}}}", - }, { c: "Entertainment", d: "www.thetvdb.com", @@ -106982,8 +107025,8 @@ export const bangs = [ r: 31, s: "tv.com", sc: "TV", - t: "tv", - u: "http://www.tv.com/search?q= {{{s}}}", + t: "tvcom", + u: "http://www.tv.com/search?q={{{s}}}", }, { c: "Shopping",