Restore in-app updater and add Mega web fallback path
Build and Release / build (push) Has been cancelled
Build and Release / build (push) Has been cancelled
This commit is contained in:
@@ -2,6 +2,7 @@ export const IPC_CHANNELS = {
|
||||
GET_SNAPSHOT: "app:get-snapshot",
|
||||
GET_VERSION: "app:get-version",
|
||||
CHECK_UPDATES: "app:check-updates",
|
||||
INSTALL_UPDATE: "app:install-update",
|
||||
OPEN_EXTERNAL: "app:open-external",
|
||||
UPDATE_SETTINGS: "app:update-settings",
|
||||
ADD_LINKS: "queue:add-links",
|
||||
|
||||
@@ -1,9 +1,10 @@
|
||||
import type { AddLinksPayload, AppSettings, UiSnapshot, UpdateCheckResult } from "./types";
|
||||
import type { AddLinksPayload, AppSettings, UiSnapshot, UpdateCheckResult, UpdateInstallResult } from "./types";
|
||||
|
||||
export interface ElectronApi {
|
||||
getSnapshot: () => Promise<UiSnapshot>;
|
||||
getVersion: () => Promise<string>;
|
||||
checkUpdates: () => Promise<UpdateCheckResult>;
|
||||
installUpdate: () => Promise<UpdateInstallResult>;
|
||||
openExternal: (url: string) => Promise<boolean>;
|
||||
updateSettings: (settings: Partial<AppSettings>) => Promise<AppSettings>;
|
||||
addLinks: (payload: AddLinksPayload) => Promise<{ addedPackages: number; addedLinks: number; invalidCount: number }>;
|
||||
|
||||
@@ -19,6 +19,8 @@ export type DebridProvider = "realdebrid" | "megadebrid" | "bestdebrid" | "allde
|
||||
export interface AppSettings {
|
||||
token: string;
|
||||
megaToken: string;
|
||||
megaLogin: string;
|
||||
megaPassword: string;
|
||||
bestToken: string;
|
||||
allDebridToken: string;
|
||||
rememberToken: boolean;
|
||||
@@ -143,9 +145,15 @@ export interface UpdateCheckResult {
|
||||
latestVersion: string;
|
||||
latestTag: string;
|
||||
releaseUrl: string;
|
||||
setupAssetUrl?: string;
|
||||
error?: string;
|
||||
}
|
||||
|
||||
export interface UpdateInstallResult {
|
||||
started: boolean;
|
||||
message: string;
|
||||
}
|
||||
|
||||
export interface ParsedHashEntry {
|
||||
fileName: string;
|
||||
algorithm: "crc32" | "md5" | "sha1";
|
||||
|
||||
Reference in New Issue
Block a user