Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
58 changes: 44 additions & 14 deletions ci/src/updater.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
# -*-coding: utf-8 -*-
import asyncio
import aiohttp
from zipfile import ZipFile
import re
from io import BytesIO
from typing import List
from os import getenv
from sys import argv
Expand Down Expand Up @@ -68,14 +70,29 @@ async def batch_github_plugin_info(
browser_download_url or assets[0]["browser_download_url"]
)

if webhook_url:
await send_notification(
info,
clean(latest_rel["tag_name"], "v"),
latest_rel,
webhook_url,
latest_ver = clean(latest_rel["tag_name"], "v")
if version_tuple(info[version]) != version_tuple(latest_ver):
tqdm.write(f"Update detected: {info[plugin_name]} {latest_ver}")

metadata = await get_plugin_dot_json(
info[url_download], session=session
)
info[version] = clean(latest_rel["tag_name"], "v")
for key in (
description,
author,
language_name,
website,
):
info[key] = metadata[key]

if webhook_url:
await send_notification(
info,
latest_ver,
latest_rel,
webhook_url,
)
info[version] = latest_ver

tags[info[id_name]] = res.headers.get(etag, "")

Expand All @@ -86,6 +103,21 @@ async def batch_github_plugin_info(
return info


async def get_plugin_dot_json(download_url: str, *, session: aiohttp.ClientSession):
async with session.get(download_url) as res:
data = await res.read()

with ZipFile(BytesIO(data)) as zip:
for fileinfo in zip.filelist:
if not fileinfo.filename.endswith("plugin.json"):
continue

with zip.open(fileinfo, "r") as file:
return json.loads(file.read())

raise ValueError(f"plugin.json file not found. Download Url: {download_url}")


async def batch_plugin_infos(
plugin_infos: Ps, tags: ETagsType, github_token, webhook_url: str | None = None
) -> Ps:
Expand Down Expand Up @@ -114,17 +146,15 @@ def remove_unused_etags(plugin_infos: PluginsType, etags: ETagsType) -> ETagsTyp


async def send_notification(
info: PluginType, latest_ver, release, webhook_url: str | None = None
info: PluginType, latest_ver: str, release, webhook_url: str | None = None
) -> None:
if not webhook_url:
return

if version_tuple(info[version]) != version_tuple(latest_ver):
tqdm.write(f"Update detected: {info[plugin_name]} {latest_ver}")
try:
await update_hook(webhook_url, info, latest_ver, release)
except Exception as e:
tqdm.write(str(e))
try:
await update_hook(webhook_url, info, latest_ver, release)
except Exception as e:
tqdm.write(str(e))


async def main():
Expand Down
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
{
"ID": "90f799c3-c04e-443b-bce8-eec5fbcba1e9",
"Name": "Amazing Marvin",
"Description": "Communication with Amazing Marvin over API",
"Description": "Plugin to run Amazing Marvin",
"Author": "RrobertRr",
"Version": "0.2.0",
"Language": "python",
"Website": "https://github.com/rrFlowLauncher/amazing_marvin",
"Website": "https://github.com/rrFlowLauncher/amazing_marvin/",
"UrlDownload": "https://github.com/rrFlowLauncher/amazing_marvin/releases/download/v0.2.0/amazing_marvin.zip",
"UrlSourceCode": "https://github.com/rrFlowLauncher/amazing_marvin",
"IcoPath": "https://github.com/rrFlowLauncher/amazing_marvin/blob/main/Images/Amazing_Marvin.09233c09.png",
Expand Down
2 changes: 1 addition & 1 deletion plugins/Anilist-08AF784C-A014-4A03-822F-6C2F3665A843.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"ID": "08AF784C-A014-4A03-822F-6C2F3665A843",
"Name": "Anilist",
"Description": "an anilist plugin for Flow-Launcher",
"Description": "An Anilist plugin for Flow-Launcher",
"Author": "DiekoMA",
"Version": "1.0.7",
"Language": "csharp",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,13 @@
"Name": "AnyVideo Downloader",
"Description": "Plugin for downloading videos from YouTube, Facebook, Twitter, Instagram, and many other websites.",
"Author": "z1nc0r3",
"Version": "2.1.2",
"Version": "2.1.3",
"Language": "python",
"Website": "https://github.com/z1nc0r3/AnyVideo-Downloader-Flow-Plugin",
"UrlDownload": "https://github.com/z1nc0r3/AnyVideo-Downloader-Flow-Plugin/releases/download/v2.1.2/Flow.Launcher.Plugin.AnyVideo.Downloader.zip",
"UrlDownload": "https://github.com/z1nc0r3/AnyVideo-Downloader-Flow-Plugin/releases/download/v2.1.3/Flow.Launcher.Plugin.AnyVideo.Downloader.zip",
"UrlSourceCode": "https://github.com/z1nc0r3/AnyVideo-Downloader-Flow-Plugin/tree/main",
"IcoPath": "https://cdn.jsdelivr.net/gh/z1nc0r3/AnyVideo-Downloader-Flow-Plugin@main/Images/app.png",
"Tested": true,
"DateAdded": "2024-07-30T07:46:00Z",
"LatestReleaseDate": "2025-03-02T06:47:38Z"
"LatestReleaseDate": "2025-03-13T18:16:39Z"
}
4 changes: 2 additions & 2 deletions plugins/AppsSnapshoter-0F7232DB70E54C9B91205480C0C56D1F.json
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
{
"ID": "0F7232DB70E54C9B91205480C0C56D1F",
"Name": "AppsSnapshoter",
"Description": "Snapshot opened apps with help of plugin for Flow-Launcher for future open",
"Description": "Snapshot opened apps with help of plugin for Flow-Launcher",
"Author": "spinozanilast",
"Version": "1.2.1",
"Language": "csharp",
"Website": "https://github.com/Spinozanilast/Flow.Launcher.Plugin.AppsSnapshoter",
"Website": "https://github.com/spinozanilast/Flow.Launcher.Plugin.AppsSnapshoter",
"UrlDownload": "https://github.com/Spinozanilast/Flow.Launcher.Plugin.AppsSnapshoter/releases/download/v1.2.1/AppsSnapshoter-1.2.1.zip",
"UrlSourceCode": "https://github.com/Spinozanilast/Flow.Launcher.Plugin.AppsSnapshoter/tree/master",
"IcoPath": "https://cdn.jsdelivr.net/gh/Spinozanilast/Flow.Launcher.Plugin.AppsSnapshoter@master/icon.png",
Expand Down
2 changes: 1 addition & 1 deletion plugins/Astro-d429a0ef-94e5-4ba6-8eba-b4dd0e69dc48.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"ID": "d429a0ef-94e5-4ba6-8eba-b4dd0e69dc48",
"Name": "Astro",
"Description": "Search Astro Docs",
"Author": "palmiak",
"Author": "Maciek Palmowski",
"Version": "0.0.2",
"Language": "javascript",
"Website": "https://github.com/palmiak/astro-flow-launcher-plugin",
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"ID": "C04175CF5284406DAA9E30A85EC7DA76",
"Name": "Audio Device Selector",
"Description": "Easily change your playback device",
"Description": "Easy change your playback device",
"Author": "AttilaKapostyak",
"Version": "1.0.3",
"Language": "csharp",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
"Author": "SUPEROLEJKAAA",
"Version": "1.0.0",
"Language": "JavaScript",
"Website": "https://github.com/SUPEROLEJKAAA/Flow.Launcher.Plugin.BinancePrice",
"Website": "https://github.com/SUPEROLEJKAAA/flow-binance-price",
"UrlDownload": "https://github.com/SUPEROLEJKAAA/Flow.Launcher.Plugin.BinancePrice/releases/download/v1.0.0/Flow.Launcher.Plugin.BinancePrice.zip",
"UrlSourceCode": "https://github.com/SUPEROLEJKAAA/Flow.Launcher.Plugin.BinancePrice",
"IcoPath": "https://cdn.jsdelivr.net/gh/SUPEROLEJKAAA/Flow.Launcher.Plugin.BinancePrice@master/icons/app.png",
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"ID": "2d5036e2-eccc-4254-b88e-de78580e2195",
"Name": "Bulk URL Opener",
"Description": "Opens groups of tabs",
"Description": "Opens groups of tabs. To edit the tab groups, edit the tab_groups.yaml file in the plugin directory.",
"Author": "Tarik Jaber",
"Version": "2.0.0",
"Language": "python",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"ID": "28b1bc8d-06e1-4bda-8311-f36e8d4f9915",
"Name": "CPPreference",
"Description": "Search cppreference.com efficiently",
"Author": "Peter Schussheim",
"Author": "Peter Schussheim, Jonas de Bruin",
"Version": "1.1.0",
"Language": "csharp",
"Website": "https://github.com/peterschussheim/CPPreference-flow-plugin",
Expand Down
2 changes: 1 addition & 1 deletion plugins/Cider-4e2018ca-4ed0-11ed-bdc3-0242ac120002.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
"Author": "Monochromish",
"Version": "1.1.1",
"Language": "javascript",
"Website": "https://github.com/Monochromish/Flow.Launcher.Plugin.Cider",
"Website": "https://github.com/Monchromish/Flow.Launcher.Plugin.Cider",
"UrlDownload": "https://github.com/Monochromish/Flow.Launcher.Plugin.Cider/releases/download/v1.1.1/Flow.Launcher.Plugin.Cider.zip",
"UrlSourceCode": "https://github.com/Monochromish/Flow.Launcher.Plugin.Cider/tree/main",
"IcoPath": "https://cdn.jsdelivr.net/gh/Monochromish/Flow.Launcher.Plugin.Cider@main/Assets/app.png",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"ID": "8025ce8b-b1ce-49cd-af48-b343a0df8606",
"Name": "Clipboard History",
"Description": "a Clipboard History Plugin for FlowLauncher",
"Author": "liberize,Xenolphthalein",
"Author": "liberize",
"Version": "1.1.1",
"Language": "csharp",
"Website": "https://github.com/liberize/Flow.Launcher.Plugin.ClipboardHistory",
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"ID": "b6a9192c-6646-4c77-bc6b-be4f8195ffda",
"Name": "Date Calculator",
"Description": "Date Calculator using Flow's embedded python",
"Description": "Date Calculator",
"Author": "jasonz3157",
"Version": "0.2.1",
"Language": "python",
Expand Down
2 changes: 1 addition & 1 deletion plugins/DdFlow-735A3608B5D240E5A44357CCF852E329.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"ID": "735A3608B5D240E5A44357CCF852E329",
"Name": "DdFlow",
"Description": "Plugin for Get the day from the date",
"Description": "all-in-one date plugin",
"Author": "Ahmed ElSaeed",
"Version": "2.0.0",
"Language": "python",
Expand Down
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
{
"ID": "1b7c732781f94b748ed08351f8200894",
"Name": "Direct Translate",
"Description": "Translate between any languages supported by textblob.",
"Description": "Translate between any languages supported by Googletrans",
"Author": "Drimix20",
"Version": "2.1.0",
"Language": "python",
"Website": "https://github.com/deefrawley/Flow.Launcher.Plugin.DirectTranslate",
"Website": "https://github.com/Drimix20/Flow.Launcher.Plugin.DirectTranslate",
"UrlDownload": "https://github.com/deefrawley/Flow.Launcher.Plugin.DirectTranslate/releases/download/2.1.0/Flow.Launcher.Plugin.DirectTranslate-2.1.0.zip",
"UrlSourceCode": "https://github.com/deefrawley/Flow.Launcher.Plugin.DirectTranslate/tree/master",
"IcoPath": "https://cdn.jsdelivr.net/gh/deefrawley/Flow.Launcher.Plugin.DirectTranslate@master/assets/favicon.ico",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
"Description": "Generate discord timestamps",
"Author": "Jessuh",
"Version": "1.0.1",
"Language": "executable",
"Language": "JavaScript",
"Website": "https://github.com/Jessuhh/discord-timestamps-flowlauncher-plugin",
"UrlDownload": "https://github.com/Jessuhh/discord-timestamps-flowlauncher-plugin/releases/download/v1.0.1/Flow.Launcher.Plugin.DiscordTimestamps.zip",
"UrlSourceCode": "https://github.com/Jessuhh/discord-timestamps-flowlauncher-plugin",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
"Author": "Garulf",
"Version": "2.0.0",
"Language": "python",
"Website": "https://github.com/Garulf/Epic-Games-Store-Launcher",
"Website": "https://github.com/Garulf/epic_games_store_launcher",
"UrlDownload": "https://github.com/Garulf/Epic-Games-Store-Launcher/releases/download/v2.0.0/Epic-Games-Store-Launcher.zip",
"UrlSourceCode": "https://github.com/Garulf/Epic-Games-Store-Launcher/tree/main",
"IcoPath": "https://cdn.jsdelivr.net/gh/Garulf/Epic-Games-Store-Launcher@main/icon.png",
Expand Down
2 changes: 1 addition & 1 deletion plugins/FabCalc-4f9e42bbcd9045e1969f97293dfaf4c7.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"ID": "4f9e42bbcd9045e1969f97293dfaf4c7",
"Name": "FabCalc",
"Description": "Advanced algebric and symbolic Calculator",
"Description": "Advanced Calculator (symbolic, numeric, UUID, IP, dates, websearches, etc.)",
"Author": "Fabio",
"Version": "1.4.2",
"Language": "python",
Expand Down
2 changes: 1 addition & 1 deletion plugins/Fake Data-8BE6E623BC294D4684F86A47CA797742.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
"Author": "Yusyuriv",
"Version": "1.0.0",
"Language": "csharp",
"Website": "https://github.com/Yusyuriv/Flow.Launcher.Plugin.FakeData/tree/main",
"Website": "https://github.com/Yusyuriv/Flow.Launcher.Plugin.FakeData",
"UrlDownload": "https://github.com/Yusyuriv/Flow.Launcher.Plugin.FakeData/releases/download/1.0.0/Flow.Launcher.Plugin.FakeData.zip",
"UrlSourceCode": "https://github.com/Yusyuriv/Flow.Launcher.Plugin.FakeData/tree/main",
"IcoPath": "https://cdn.jsdelivr.net/gh/Yusyuriv/Flow.Launcher.Plugin.FakeData@main/app.png",
Expand Down
4 changes: 2 additions & 2 deletions plugins/Fancy Emoji-FF2C31D6A47348FFB9ED4EB26F6794E2.json
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
{
"ID": "FF2C31D6A47348FFB9ED4EB26F6794E2",
"Name": "Fancy Emoji",
"Description": "Search for emoji and add to your clipboard automatically",
"Description": "Search for emoji and add to your clipboard automatically.",
"Author": "Mave",
"Version": "1.0.9",
"Language": "python",
"Website": "https://github.com/Ma-ve/Flow.Launcher.Plugin.FancyEmoji",
"Website": "https://github.com/Ma-ve",
"UrlDownload": "https://github.com/Ma-ve/Flow.Launcher.Plugin.FancyEmoji/releases/download/1.0.9/Flow.Launcher.Plugin.FancyEmoji.zip",
"UrlSourceCode": "https://github.com/Ma-ve/Flow.Launcher.Plugin.FancyEmoji/tree/master",
"IcoPath": "https://cdn.jsdelivr.net/gh/Ma-ve/Flow.Launcher.Plugin.FancyEmoji@master/icon.png",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
"Author": "cibere",
"Version": "0.2.3",
"Language": "python_v2",
"Website": "https://github.com/cibere/Flow.Launcher.Plugin.FirefoxKeywordBookmarks",
"Website": "https://github.com/cibere/Flow.Launcher.Plugin.FirefoxKeywordBookmarks/tree/v0.2.2",
"UrlDownload": "https://github.com/cibere/FirefoxKeywordBookmarks/releases/download/v0.2.3/FirefoxKeywordBookmarks.zip",
"UrlSourceCode": "https://github.com/cibere/Flow.Launcher.Plugin.FirefoxKeywordBookmarks",
"IcoPath": "https://i.imgur.com/1cGHQTp.png",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
"Author": "cibere",
"Version": "0.0.4",
"Language": "python_v2",
"Website": "https://github.com/cibere/Flow.Launcher.Plugin.FlowLoadNotification",
"Website": "https://github.com/cibere/Flow.Launcher.Plugin.FlowLoadNotification/tree/v0.0.4",
"UrlDownload": "https://github.com/cibere/Flow.Launcher.Plugin.FlowLoadNotification/releases/download/v0.0.4/Flow.Launcher.Plugin.FlowLoadNotification.zip",
"UrlSourceCode": "https://github.com/cibere/Flow.Launcher.Plugin.FlowLoadNotification",
"IcoPath": "https://i.imgur.com/G0lVumf.png",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
"Author": "cxfksword",
"Version": "1.0",
"Language": "csharp",
"Website": "https://github.com/taooceros/Flow.Plugin.UrlEncode",
"Website": "https://github.com/cxfksword/Wox.Plugin.UrlEncode",
"UrlDownload": "https://github.com/taooceros/Flow.Plugin.UrlEncode/releases/download/v1.0/Flow.Plugin.UrlEncode.zip",
"UrlSourceCode": "https://github.com/taooceros/Flow.Plugin.UrlEncode",
"IcoPath": "https://cdn.jsdelivr.net/gh/taooceros/Flow.Plugin.UrlEncode@master/Images/app.png",
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"ID": "54545DC7B3A542DBB6C7DA50DEAD455B",
"Name": "GamesLauncher",
"Description": "Search and launch games from multiple platforms like Steam, Epic Games etc.",
"Description": "Search and launch games from multiple platforms like Steam, Epic Games, Xbox etc.",
"Author": "KrystianLesniak",
"Version": "1.9.2",
"Language": "csharp",
Expand Down
2 changes: 1 addition & 1 deletion plugins/Godot-D8AF059F555C48A380AAD5D57B4A5D61.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"ID": "D8AF059F555C48A380AAD5D57B4A5D61",
"Name": "Godot",
"Description": "Quickly launch your Godot projects from flow launcher",
"Description": "Quickly launch your godot projects from flow launcher",
"Author": "DiekoMA",
"Version": "1.0.3",
"Language": "csharp",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
"Author": "N.Duong",
"Version": "1.1.1",
"Language": "csharp",
"Website": "https://github.com/NDiiong/Flow.Launcher.Plugin.GuidConverter/tree/main",
"Website": "https://github.com/NDiiong/Flow.Launcher.Plugin.GuidConverter.git",
"UrlDownload": "https://github.com/NDiiong/Flow.Launcher.Plugin.GuidConverter/releases/download/v1.1.1/Flow.Launcher.Plugin.GuidConverter.zip",
"UrlSourceCode": "https://github.com/NDiiong/Flow.Launcher.Plugin.GuidConverter/tree/main",
"IcoPath": "https://cdn.jsdelivr.net/gh/NDiiong/Flow.Launcher.Plugin.GuidConverter@main/Flow.Launcher.Plugin.GuidConverter/Images/icon.png",
Expand Down
2 changes: 1 addition & 1 deletion plugins/Heidi-76148ECE-AA72-4C68-AFD5-54BA8A3C1F61.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"ID": "76148ECE-AA72-4C68-AFD5-54BA8A3C1F61",
"Name": "Heidi",
"Description": "Launch HeidiSQL Sessions.",
"Description": "Launch Heidi Sessions",
"Author": "LostPing",
"Version": "1.0.0",
"Language": "csharp",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
"Description": "Searches for the provided Name and returns the Playtime from HowLongToBeat",
"Author": "Tueska",
"Version": "1.0.1",
"Language": "javascript",
"Language": "JavaScript",
"ExecuteFileName": "main.js",
"Website": "https://github.com/Tueska/fl-howlongtobeat",
"IcoPath": "https://cdn.jsdelivr.net/gh/Tueska/fl-HowLongToBeat/Images/howlongtobeat.png",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,10 @@
"ID": "a6da9c8f-523f-4806-a140-45f10af18e21",
"Name": "KeePass2Flow",
"Description": "Hook up Flow to KeePass 2",
"Author": "geisterfurz007",
"Author": "mvarendorff",
"Version": "1.1.7",
"Language": "csharp",
"Website": "https://github.com/geisterfurz007/KeePass2Flow",
"Website": "https://github.com/mvarendorff/KeePass2Flow",
"UrlDownload": "https://github.com/mvarendorff/KeePass2Flow/releases/download/v1.1.7/KeePass2Flow.zip",
"UrlSourceCode": "https://github.com/geisterfurz007/KeePass2Flow",
"IcoPath": "https://cdn.jsdelivr.net/gh/geisterfurz007/KeePass2Flow@master/Flow.Launcher.Plugin.KeePass2Flow/icon.png",
Expand Down
2 changes: 1 addition & 1 deletion plugins/Kitty-898FC7F0-4F38-401B-82E0-A852798C2D59.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"ID": "898FC7F0-4F38-401B-82E0-A852798C2D59",
"Name": "Kitty",
"Description": "Launch Kitty Sessions.",
"Description": "Launch Kitty Sessions",
"Author": "LostPing",
"Version": "1.0.6",
"Language": "csharp",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
"Author": "taooceros",
"Version": "1.0.1",
"Language": "csharp",
"Website": "https://github.com/taooceros/Flow.LibreTranslate",
"Website": "https://github.com/taooceros/Flow.Launcher.Plugin.LibreTranslate",
"UrlDownload": "https://github.com/taooceros/Flow.LibreTranslate/releases/download/v1.0.1/Flow.LibreTranslate.zip",
"UrlSourceCode": "https://github.com/taooceros/Flow.LibreTranslate/tree/main",
"IcoPath": "https://cdn.jsdelivr.net/gh/taooceros/Flow.LibreTranslate@main/Flow.LibreTranslate/Images/translate.png",
Expand Down
Loading