mirror of
https://github.com/bitwarden/browser
synced 2026-02-13 06:54:07 +00:00
Remove appimage support
This commit is contained in:
7
.github/workflows/build-desktop.yml
vendored
7
.github/workflows/build-desktop.yml
vendored
@@ -220,13 +220,6 @@ jobs:
|
||||
path: apps/desktop/dist/bitwarden_${{ env._PACKAGE_VERSION }}_amd64.snap
|
||||
if-no-files-found: error
|
||||
|
||||
- name: Upload .AppImage artifact
|
||||
uses: actions/upload-artifact@b4b15b8c7c6ac21ea08fcf65892d2ee8f75cf882 # v4.4.3
|
||||
with:
|
||||
name: Bitwarden-${{ env._PACKAGE_VERSION }}-x86_64.AppImage
|
||||
path: apps/desktop/dist/Bitwarden-${{ env._PACKAGE_VERSION }}-x86_64.AppImage
|
||||
if-no-files-found: error
|
||||
|
||||
- name: Upload auto-update artifact
|
||||
uses: actions/upload-artifact@b4b15b8c7c6ac21ea08fcf65892d2ee8f75cf882 # v4.4.3
|
||||
with:
|
||||
|
||||
7
.github/workflows/release-desktop-beta.yml
vendored
7
.github/workflows/release-desktop-beta.yml
vendored
@@ -185,13 +185,6 @@ jobs:
|
||||
path: apps/desktop/dist/bitwarden_${{ env._PACKAGE_VERSION }}_amd64.snap
|
||||
if-no-files-found: error
|
||||
|
||||
- name: Upload .AppImage artifact
|
||||
uses: actions/upload-artifact@b4b15b8c7c6ac21ea08fcf65892d2ee8f75cf882 # v4.4.3
|
||||
with:
|
||||
name: Bitwarden-${{ env._PACKAGE_VERSION }}-x86_64.AppImage
|
||||
path: apps/desktop/dist/Bitwarden-${{ env._PACKAGE_VERSION }}-x86_64.AppImage
|
||||
if-no-files-found: error
|
||||
|
||||
- name: Upload auto-update artifact
|
||||
uses: actions/upload-artifact@b4b15b8c7c6ac21ea08fcf65892d2ee8f75cf882 # v4.4.3
|
||||
with:
|
||||
|
||||
1
.github/workflows/release-desktop.yml
vendored
1
.github/workflows/release-desktop.yml
vendored
@@ -106,7 +106,6 @@ jobs:
|
||||
apps/desktop/artifacts/Bitwarden-${{ env.PKG_VERSION }}-x86_64.rpm,
|
||||
apps/desktop/artifacts/Bitwarden-${{ env.PKG_VERSION }}-x64.freebsd,
|
||||
apps/desktop/artifacts/bitwarden_${{ env.PKG_VERSION }}_amd64.snap,
|
||||
apps/desktop/artifacts/Bitwarden-${{ env.PKG_VERSION }}-x86_64.AppImage,
|
||||
apps/desktop/artifacts/Bitwarden-Portable-${{ env.PKG_VERSION }}.exe,
|
||||
apps/desktop/artifacts/Bitwarden-Installer-${{ env.PKG_VERSION }}.exe,
|
||||
apps/desktop/artifacts/Bitwarden-${{ env.PKG_VERSION }}-ia32-store.appx,
|
||||
|
||||
@@ -113,7 +113,7 @@
|
||||
"to": "desktop_proxy"
|
||||
}
|
||||
],
|
||||
"target": ["deb", "freebsd", "rpm", "AppImage", "snap"],
|
||||
"target": ["deb", "freebsd", "rpm", "snap"],
|
||||
"desktop": {
|
||||
"Name": "Bitwarden",
|
||||
"Type": "Application",
|
||||
@@ -238,9 +238,6 @@
|
||||
"artifactName": "${productName}-${version}-${arch}.${ext}",
|
||||
"depends": ["libnotify4", "libxtst6", "libnss3", "libsecret-1-0", "libxss1"]
|
||||
},
|
||||
"appImage": {
|
||||
"artifactName": "${productName}-${version}-${arch}.${ext}"
|
||||
},
|
||||
"rpm": {
|
||||
"artifactName": "${productName}-${version}-${arch}.${ext}"
|
||||
},
|
||||
|
||||
@@ -21,7 +21,6 @@ import { DesktopLoginComponentService } from "./desktop-login-component.service"
|
||||
|
||||
const defaultIpc = {
|
||||
platform: {
|
||||
isAppImage: false,
|
||||
isSnapStore: false,
|
||||
isDev: false,
|
||||
localhostCallbackService: {
|
||||
@@ -107,21 +106,16 @@ describe("DesktopLoginComponentService", () => {
|
||||
});
|
||||
|
||||
describe("launchSsoBrowserWindow", () => {
|
||||
// Array of all permutations of isAppImage, isSnapStore, and isDev
|
||||
// Array of all permutations of isSnapStore, and isDev
|
||||
const permutations = [
|
||||
[true, false, false], // Case 1: isAppImage true
|
||||
[false, true, false], // Case 2: isSnapStore true
|
||||
[false, false, true], // Case 3: isDev true
|
||||
[true, true, false], // Case 4: isAppImage and isSnapStore true
|
||||
[true, false, true], // Case 5: isAppImage and isDev true
|
||||
[false, true, true], // Case 6: isSnapStore and isDev true
|
||||
[true, true, true], // Case 7: all true
|
||||
[false, false, false], // Case 8: all false
|
||||
[false, false], // Case 1: both false
|
||||
[true, false], // Case 2: isSnapStore true
|
||||
[false, true], // Case 3: isDev true
|
||||
[true, true], // Case 4: both true
|
||||
];
|
||||
|
||||
permutations.forEach(([isAppImage, isSnapStore, isDev]) => {
|
||||
it(`executes correct logic for isAppImage=${isAppImage}, isSnapStore=${isSnapStore}, isDev=${isDev}`, async () => {
|
||||
(global as any).ipc.platform.isAppImage = isAppImage;
|
||||
permutations.forEach(([isSnapStore, isDev]) => {
|
||||
it(`executes correct logic for isSnapStore=${isSnapStore}, isDev=${isDev}`, async () => {
|
||||
(global as any).ipc.platform.isSnapStore = isSnapStore;
|
||||
(global as any).ipc.platform.isDev = isDev;
|
||||
|
||||
@@ -139,7 +133,7 @@ describe("DesktopLoginComponentService", () => {
|
||||
|
||||
await service.launchSsoBrowserWindow(email, clientId);
|
||||
|
||||
if (isAppImage || isSnapStore || isDev) {
|
||||
if (isSnapStore || isDev) {
|
||||
expect(superLaunchSsoBrowserWindowSpy).not.toHaveBeenCalled();
|
||||
|
||||
// Assert that the standard logic is executed
|
||||
|
||||
@@ -35,7 +35,7 @@ export class DesktopLoginComponentService
|
||||
}
|
||||
|
||||
override async launchSsoBrowserWindow(email: string, clientId: "desktop"): Promise<void | null> {
|
||||
if (!ipc.platform.isAppImage && !ipc.platform.isSnapStore && !ipc.platform.isDev) {
|
||||
if (!ipc.platform.isSnapStore && !ipc.platform.isDev) {
|
||||
return super.launchSsoBrowserWindow(email, clientId);
|
||||
}
|
||||
|
||||
|
||||
@@ -193,7 +193,7 @@ export class LoginComponentV1 extends BaseLoginComponent implements OnInit, OnDe
|
||||
}
|
||||
|
||||
async launchSsoBrowser(clientId: string, ssoRedirectUri: string) {
|
||||
if (!ipc.platform.isAppImage && !ipc.platform.isSnapStore && !ipc.platform.isDev) {
|
||||
if (!ipc.platform.isSnapStore && !ipc.platform.isDev) {
|
||||
return super.launchSsoBrowser(clientId, ssoRedirectUri);
|
||||
}
|
||||
|
||||
|
||||
@@ -4,7 +4,7 @@ import { autoUpdater } from "electron-updater";
|
||||
|
||||
import { I18nService } from "@bitwarden/common/platform/abstractions/i18n.service";
|
||||
|
||||
import { isAppImage, isDev, isMacAppStore, isWindowsPortable, isWindowsStore } from "../utils";
|
||||
import { isDev, isMacAppStore, isWindowsPortable, isWindowsStore } from "../utils";
|
||||
|
||||
import { WindowMain } from "./window.main";
|
||||
|
||||
@@ -22,12 +22,10 @@ export class UpdaterMain {
|
||||
) {
|
||||
autoUpdater.logger = log;
|
||||
|
||||
const linuxCanUpdate = process.platform === "linux" && isAppImage();
|
||||
const windowsCanUpdate =
|
||||
process.platform === "win32" && !isWindowsStore() && !isWindowsPortable();
|
||||
const macCanUpdate = process.platform === "darwin" && !isMacAppStore();
|
||||
this.canUpdate =
|
||||
!this.userDisabledUpdates() && (linuxCanUpdate || windowsCanUpdate || macCanUpdate);
|
||||
this.canUpdate = !this.userDisabledUpdates() && (windowsCanUpdate || macCanUpdate);
|
||||
}
|
||||
|
||||
async init() {
|
||||
|
||||
@@ -10,7 +10,7 @@ import {
|
||||
Message,
|
||||
UnencryptedMessageResponse,
|
||||
} from "../models/native-messaging";
|
||||
import { isAppImage, isDev, isFlatpak, isMacAppStore, isSnapStore, isWindowsStore } from "../utils";
|
||||
import { isDev, isFlatpak, isMacAppStore, isSnapStore, isWindowsStore } from "../utils";
|
||||
|
||||
import { ClipboardWriteMessage } from "./types/clipboard";
|
||||
|
||||
@@ -104,7 +104,6 @@ export default {
|
||||
isWindowsStore: isWindowsStore(),
|
||||
isFlatpak: isFlatpak(),
|
||||
isSnapStore: isSnapStore(),
|
||||
isAppImage: isAppImage(),
|
||||
reloadProcess: () => ipcRenderer.send("reload-process"),
|
||||
log: (level: LogLevelType, message?: any, ...optionalParams: any[]) =>
|
||||
ipcRenderer.invoke("ipc.log", { level, message, optionalParams }),
|
||||
|
||||
@@ -8,7 +8,7 @@ import { MessageSender } from "@bitwarden/common/platform/messaging";
|
||||
|
||||
/**
|
||||
* The SSO Localhost login service uses a local host listener as fallback in case scheme handling deeplinks does not work.
|
||||
* This way it is possible to log in with SSO on appimage, snap, and electron dev using the same methods that the cli uses.
|
||||
* This way it is possible to log in with SSO on snap, and electron dev using the same methods that the cli uses.
|
||||
*/
|
||||
export class SSOLocalhostCallbackService {
|
||||
private ssoRedirectUri = "";
|
||||
|
||||
@@ -29,10 +29,6 @@ export function isLinux() {
|
||||
return process.platform === "linux";
|
||||
}
|
||||
|
||||
export function isAppImage() {
|
||||
return isLinux() && "APPIMAGE" in process.env;
|
||||
}
|
||||
|
||||
export function isSnapStore() {
|
||||
return isLinux() && process.env.SNAP_USER_DATA != null;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user