New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@todesktop/runtime

Package Overview
Dependencies
Maintainers
3
Versions
121
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@todesktop/runtime - npm Package Compare versions

Comparing version 2.1.0 to 2.1.1-0

5

dist/autoUpdater/AutoUpdater.d.ts

@@ -15,3 +15,3 @@ import type { AllPublishOptions, PublishConfiguration } from "builder-util-runtime";

private readonly _autoCheckInterval;
private readonly _buildId?;
private _buildId?;
private readonly _createdAt;

@@ -31,2 +31,5 @@ private _hasUpdateReadyToInstall;

setFeedURL(options: PublishConfiguration | AllPublishOptions | string): void;
setBuildId(buildId: string): void;
private get buildId();
private set buildId(value);
private _actuallyPerformCheck;

@@ -33,0 +36,0 @@ private _autoCheckOnInterval;

22

dist/autoUpdater/AutoUpdater.js

@@ -37,3 +37,3 @@ "use strict";

if (buildId) {
this._buildId = buildId;
this.buildId = buildId;
}

@@ -59,3 +59,3 @@ this._whenInitialized = new Promise((resolve) => {

yield (0, alwaysResolve_1.default)(this._appFinishedLaunchingPromise, { logger });
if (inactiveReason === "" && !this._buildId) {
if (inactiveReason === "" && !this.buildId) {
// Check if the current build is released before updating _unless_ we're targeting a specific build

@@ -124,2 +124,16 @@ const { isReleased } = yield (0, alwaysResolve_1.default)(getReleaseStatusFn(logger), {

}
setBuildId(buildId) {
this._log("info", ".setBuildId called with buildId:", buildId);
this.buildId = buildId;
}
get buildId() {
return this._buildId;
}
set buildId(value) {
this._buildId = value;
if (value) {
electronUpdater.autoUpdater.channel = `latest-build-${value}`;
this._log("debug", "Updater channel set to latest-build-" + value);
}
}
_actuallyPerformCheck() {

@@ -273,6 +287,2 @@ return __awaiter(this, arguments, void 0, function* ({ disableUpdateReadyAction, } = {}) {

}
if (this._buildId) {
this._log("debug", "Setting up UpdaterAgent with buildId", this._buildId);
electronUpdater.autoUpdater.channel = `latest-build-${this._buildId}`;
}
this._log("debug", "Setting up UpdaterAgent");

@@ -279,0 +289,0 @@ this._updaterAgent = new updaterAgents_1.UpdaterAgent({

@@ -1,1 +0,1 @@

export declare const CLIENT_VERSION = "2.1.0";
export declare const CLIENT_VERSION = "2.1.1-0";
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.CLIENT_VERSION = void 0;
exports.CLIENT_VERSION = "2.1.0";
exports.CLIENT_VERSION = "2.1.1-0";

@@ -7,3 +7,3 @@ {

"name": "@todesktop/runtime",
"version": "2.1.0",
"version": "2.1.1-0",
"license": "MIT",

@@ -10,0 +10,0 @@ "author": "ToDesktop <hi@todesktop.com> (https://www.todesktop.com/)",

@@ -136,10 +136,2 @@ # @todesktop/runtime

##### `options.shouldAutoCheckOnLaunch` (Optional)
Type: `boolean`
Default: `true`
Whether the app should check for auto-updates on launch.
##### `options.customLogger` (Optional)

@@ -163,2 +155,30 @@

##### `options.buildId` (Optional)
Type: `string`
Default: `undefined`
Specifies a build ID to check for updates against a specific `buildId`. When set, the auto-updater will only update to the specific build ID.
**NOTE:** The version number of the build to update to must be different than the currently running version. If the version number is the same then no update will take place. For example, if both builds are version `1.2.3` then no updater will take place.
Example:
```javascript
const todesktop = require("@todesktop/runtime");
todesktop.init({
buildId: "250829if4bj8kqq", // Will update to build 250829if4bj8kqq if it is not the currently running build and the version number is different
});
```
##### `options.shouldAutoCheckOnLaunch` (Optional)
Type: `boolean`
Default: `true`
Whether the app should check for auto-updates on launch.
##### `options.updateReadyAction` (Optional)

@@ -316,22 +336,2 @@

##### `options.buildId` (Optional)
Type: `string`
Default: `undefined`
Specifies a build ID to check for updates against a specific `buildId`. When set, the auto-updater will only update to the specific build ID.
**NOTE:** The version number of the build to update to must be different thant the currently running version. If the version number is the same then no updater will take place. For example, if both builds are version `1.2.3` then no updater will take place.
Example:
```javascript
const todesktop = require("@todesktop/runtime");
todesktop.init({
buildId: "250829if4bj8kqq", // Will update to build 240829if4bj8kqq if it is not the currently running build and the version number is different
});
```
### `.autoUpdater.checkForUpdates(options)`

@@ -394,2 +394,8 @@

### `.autoUpdater.setBuildId(buildId)`
This sets the build ID to check for updates against a specific `buildId`. When set, the auto-updater will only update to the specific build ID.
**NOTE:** The version number of the build to update to must be different than the currently running version. If the version number is the same then no update will take place. For example, if both builds are version `1.2.3` then no updater will take place.
### `.autoUpdater.on(eventName, callback)`

@@ -678,2 +684,6 @@

### v2.1.1
- Add `.autoUpdater.setBuildId(buildId)` method to dynamicallytarget updates to specific builds.
### v2.1.0

@@ -680,0 +690,0 @@

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc