mirror of
https://github.com/kopia/kopia.git
synced 2026-01-02 19:47:51 -05:00
* build(deps): bump the kopia-ui-npm-dependencies group across 1 directory with 9 updates Bumps the kopia-ui-npm-dependencies group with 7 updates in the /app directory: | Package | From | To | | --- | --- | --- | | [electron-log](https://github.com/megahertz/electron-log) | `5.1.2` | `5.1.5` | | [electron-store](https://github.com/sindresorhus/electron-store) | `8.2.0` | `10.0.0` | | [electron-updater](https://github.com/electron-userland/electron-builder/tree/HEAD/packages/electron-updater) | `6.3.0-alpha.6` | `6.3.0-alpha.7` | | [uuid](https://github.com/uuidjs/uuid) | `9.0.1` | `10.0.0` | | [@electron/notarize](https://github.com/electron/notarize) | `2.3.0` | `2.3.2` | | [@playwright/test](https://github.com/microsoft/playwright) | `1.42.1` | `1.45.1` | | [electron](https://github.com/electron/electron) | `29.1.6` | `31.2.0` | Updates `electron-log` from 5.1.2 to 5.1.5 - [Changelog](https://github.com/megahertz/electron-log/blob/master/CHANGELOG.md) - [Commits](https://github.com/megahertz/electron-log/compare/v5.1.2...v5.1.5) Updates `electron-store` from 8.2.0 to 10.0.0 - [Release notes](https://github.com/sindresorhus/electron-store/releases) - [Commits](https://github.com/sindresorhus/electron-store/compare/v8.2.0...v10.0.0) Updates `electron-updater` from 6.3.0-alpha.6 to 6.3.0-alpha.7 - [Release notes](https://github.com/electron-userland/electron-builder/releases) - [Changelog](https://github.com/electron-userland/electron-builder/blob/master/packages/electron-updater/CHANGELOG.md) - [Commits](https://github.com/electron-userland/electron-builder/commits/electron-updater@6.3.0-alpha.7/packages/electron-updater) Updates `uuid` from 9.0.1 to 10.0.0 - [Changelog](https://github.com/uuidjs/uuid/blob/main/CHANGELOG.md) - [Commits](https://github.com/uuidjs/uuid/compare/v9.0.1...v10.0.0) Updates `@electron/notarize` from 2.3.0 to 2.3.2 - [Release notes](https://github.com/electron/notarize/releases) - [Changelog](https://github.com/electron/notarize/blob/main/.releaserc.json) - [Commits](https://github.com/electron/notarize/compare/v2.3.0...v2.3.2) Updates `@playwright/test` from 1.42.1 to 1.45.1 - [Release notes](https://github.com/microsoft/playwright/releases) - [Commits](https://github.com/microsoft/playwright/compare/v1.42.1...v1.45.1) Updates `electron` from 29.1.6 to 31.2.0 - [Release notes](https://github.com/electron/electron/releases) - [Changelog](https://github.com/electron/electron/blob/main/docs/breaking-changes.md) - [Commits](https://github.com/electron/electron/compare/v29.1.6...v31.2.0) Updates `playwright` from 1.42.1 to 1.45.1 - [Release notes](https://github.com/microsoft/playwright/releases) - [Commits](https://github.com/microsoft/playwright/compare/v1.42.1...v1.45.1) Updates `playwright-core` from 1.42.1 to 1.45.1 - [Release notes](https://github.com/microsoft/playwright/releases) - [Commits](https://github.com/microsoft/playwright/compare/v1.42.1...v1.45.1) --- updated-dependencies: - dependency-name: electron-log dependency-type: direct:production update-type: version-update:semver-patch dependency-group: kopia-ui-npm-dependencies - dependency-name: electron-store dependency-type: direct:production update-type: version-update:semver-major dependency-group: kopia-ui-npm-dependencies - dependency-name: electron-updater dependency-type: direct:production update-type: version-update:semver-patch dependency-group: kopia-ui-npm-dependencies - dependency-name: uuid dependency-type: direct:production update-type: version-update:semver-major dependency-group: kopia-ui-npm-dependencies - dependency-name: "@electron/notarize" dependency-type: direct:development update-type: version-update:semver-patch dependency-group: kopia-ui-npm-dependencies - dependency-name: "@playwright/test" dependency-type: direct:development update-type: version-update:semver-minor dependency-group: kopia-ui-npm-dependencies - dependency-name: electron dependency-type: direct:development update-type: version-update:semver-major dependency-group: kopia-ui-npm-dependencies - dependency-name: playwright dependency-type: direct:development update-type: version-update:semver-minor dependency-group: kopia-ui-npm-dependencies - dependency-name: playwright-core dependency-type: direct:development update-type: version-update:semver-minor dependency-group: kopia-ui-npm-dependencies ... Signed-off-by: dependabot[bot] <support@github.com> * upgraded app to ES modules * renamed notarize.js and sign.js to CommonJS --------- Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Jarek Kowalski <jaak@jkowalski.net>
52 lines
1.4 KiB
JavaScript
52 lines
1.4 KiB
JavaScript
import { app } from 'electron';
|
|
import path from 'path';
|
|
const __dirname = import.meta.dirname;
|
|
|
|
const osShortName = function () {
|
|
switch (process.platform) {
|
|
case "win32":
|
|
return "win"
|
|
case "darwin":
|
|
return "mac"
|
|
case "linux":
|
|
return "linux"
|
|
default:
|
|
return null
|
|
}
|
|
}();
|
|
|
|
export function iconsPath() {
|
|
if (!app.isPackaged) {
|
|
return path.join(__dirname, "..", "resources", osShortName, "icons");
|
|
}
|
|
|
|
return path.join(process.resourcesPath, "icons");
|
|
}
|
|
|
|
export function publicPath() {
|
|
if (!app.isPackaged) {
|
|
return path.join(__dirname, "..", "public");
|
|
}
|
|
|
|
return process.resourcesPath;
|
|
}
|
|
|
|
export function defaultServerBinary() {
|
|
if (!app.isPackaged) {
|
|
return {
|
|
"mac": path.join(__dirname, "..", "..", "dist", "kopia_darwin_amd64", "kopia"),
|
|
"win": path.join(__dirname, "..", "..", "dist", "kopia_windows_amd64", "kopia.exe"),
|
|
"linux": path.join(__dirname, "..", "..", "dist", "kopia_linux_amd64", "kopia"),
|
|
}[osShortName]
|
|
}
|
|
|
|
return {
|
|
"mac": path.join(process.resourcesPath, "server", "kopia"),
|
|
"win": path.join(process.resourcesPath, "server", "kopia.exe"),
|
|
"linux": path.join(process.resourcesPath, "server", "kopia"),
|
|
}[osShortName]
|
|
}
|
|
export function selectByOS(x) {
|
|
return x[osShortName]
|
|
}
|