flightdeck 0.2.23 → 0.2.25
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/flightdeck.x.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import { FlightDeckLogger, FlightDeck } from './chunk-
|
|
2
|
+
import { FlightDeckLogger, FlightDeck } from './chunk-FIIAJE2K.js';
|
|
3
3
|
import './chunk-PZ5AY32C.js';
|
|
4
4
|
import * as path from 'node:path';
|
|
5
5
|
import { cli, parseBooleanOption, parseNumberOption, optional } from 'comline';
|
package/dist/lib.d.ts
CHANGED
|
@@ -844,7 +844,7 @@ declare class FlightDeck<S extends string = string> {
|
|
|
844
844
|
dead: Future<unknown>;
|
|
845
845
|
protected restartTimes: number[];
|
|
846
846
|
constructor(options: FlightDeckOptions<S>);
|
|
847
|
-
protected seekUpdate(version: string): void
|
|
847
|
+
protected seekUpdate(version: string): Promise<void>;
|
|
848
848
|
protected announceUpdate(): void;
|
|
849
849
|
protected tryUpdate(): void;
|
|
850
850
|
protected startAllServices(): Future<unknown>;
|
package/dist/lib.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { FLIGHTDECK_ERROR, FLIGHTDECK_INFO, FLIGHTDECK_LNAV_FORMAT, FLIGHTDECK_SETUP_PHASES, FLIGHTDECK_UPDATE_PHASES, FLIGHTDECK_WARN, FlightDeck, FlightDeckLogger, flightDeckLogSchema, isVersionNumber } from './chunk-
|
|
1
|
+
export { FLIGHTDECK_ERROR, FLIGHTDECK_INFO, FLIGHTDECK_LNAV_FORMAT, FLIGHTDECK_SETUP_PHASES, FLIGHTDECK_UPDATE_PHASES, FLIGHTDECK_WARN, FlightDeck, FlightDeckLogger, flightDeckLogSchema, isVersionNumber } from './chunk-FIIAJE2K.js';
|
|
2
2
|
export { klaxon_lib_exports as Klaxon } from './chunk-ZID4FJKY.js';
|
|
3
3
|
import './chunk-PZ5AY32C.js';
|
|
4
4
|
//# sourceMappingURL=lib.js.map
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "flightdeck",
|
|
3
|
-
"version": "0.2.
|
|
3
|
+
"version": "0.2.25",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"author": {
|
|
6
6
|
"name": "Jeremy Banka",
|
|
@@ -28,21 +28,21 @@
|
|
|
28
28
|
},
|
|
29
29
|
"dependencies": {
|
|
30
30
|
"@t3-oss/env-core": "0.12.0",
|
|
31
|
-
"cron": "4.
|
|
31
|
+
"cron": "4.2.0",
|
|
32
32
|
"zod": "3.24.2",
|
|
33
|
-
"atom.io": "0.32.
|
|
33
|
+
"atom.io": "0.32.4",
|
|
34
34
|
"comline": "0.2.2",
|
|
35
35
|
"safedeposit": "0.1.0"
|
|
36
36
|
},
|
|
37
37
|
"devDependencies": {
|
|
38
38
|
"@biomejs/js-api": "0.7.1",
|
|
39
39
|
"@biomejs/wasm-nodejs": "1.9.4",
|
|
40
|
-
"@types/node": "22.
|
|
40
|
+
"@types/node": "22.14.1",
|
|
41
41
|
"@types/tmp": "0.2.6",
|
|
42
|
-
"bun-types": "1.2.
|
|
42
|
+
"bun-types": "1.2.9",
|
|
43
43
|
"concurrently": "9.1.2",
|
|
44
|
-
"eslint": "9.
|
|
45
|
-
"json-schema-to-zod": "2.6.
|
|
44
|
+
"eslint": "9.24.0",
|
|
45
|
+
"json-schema-to-zod": "2.6.1",
|
|
46
46
|
"rimraf": "6.0.1",
|
|
47
47
|
"tmp": "0.2.3",
|
|
48
48
|
"tsup": "8.4.0",
|
package/src/flightdeck.lib.ts
CHANGED
|
@@ -139,7 +139,7 @@ export class FlightDeck<S extends string = string> {
|
|
|
139
139
|
.on(`data`, (chunk) => {
|
|
140
140
|
data.push(chunk instanceof Buffer ? chunk : Buffer.from(chunk))
|
|
141
141
|
})
|
|
142
|
-
.on(`end`, () => {
|
|
142
|
+
.on(`end`, async () => {
|
|
143
143
|
const authHeader = req.headers.authorization
|
|
144
144
|
try {
|
|
145
145
|
if (typeof req.url === `undefined`) throw 400
|
|
@@ -165,15 +165,15 @@ export class FlightDeck<S extends string = string> {
|
|
|
165
165
|
this.storage.setItem(`updateAwaitedVersion`, versionForeignInput)
|
|
166
166
|
const { checkAvailability } = options.scripts
|
|
167
167
|
if (checkAvailability) {
|
|
168
|
-
this.updateAvailabilityChecker?.stop()
|
|
169
|
-
this.seekUpdate(versionForeignInput)
|
|
168
|
+
await this.updateAvailabilityChecker?.stop()
|
|
169
|
+
await this.seekUpdate(versionForeignInput)
|
|
170
170
|
const updatePhase = this.storage.getItem(`updatePhase`)
|
|
171
171
|
this.logger.info(`> storage("updatePhase") >`, updatePhase)
|
|
172
172
|
if (updatePhase === `notified`) {
|
|
173
173
|
this.updateAvailabilityChecker = new CronJob(
|
|
174
174
|
`30 * * * * *`,
|
|
175
|
-
() => {
|
|
176
|
-
this.seekUpdate(versionForeignInput)
|
|
175
|
+
async () => {
|
|
176
|
+
await this.seekUpdate(versionForeignInput)
|
|
177
177
|
},
|
|
178
178
|
)
|
|
179
179
|
this.updateAvailabilityChecker.start()
|
|
@@ -207,7 +207,7 @@ export class FlightDeck<S extends string = string> {
|
|
|
207
207
|
})
|
|
208
208
|
}
|
|
209
209
|
|
|
210
|
-
protected seekUpdate(version: string): void {
|
|
210
|
+
protected async seekUpdate(version: string): Promise<void> {
|
|
211
211
|
this.logger.info(`Checking for updates...`)
|
|
212
212
|
const { checkAvailability } = this.options.scripts
|
|
213
213
|
if (!checkAvailability) {
|
|
@@ -217,7 +217,7 @@ export class FlightDeck<S extends string = string> {
|
|
|
217
217
|
try {
|
|
218
218
|
const out = execSync(`${checkAvailability} ${version}`)
|
|
219
219
|
this.logger.info(`Check stdout:`, out.toString())
|
|
220
|
-
this.updateAvailabilityChecker?.stop()
|
|
220
|
+
await this.updateAvailabilityChecker?.stop()
|
|
221
221
|
this.storage.setItem(`updatePhase`, `confirmed`)
|
|
222
222
|
this.downloadPackage()
|
|
223
223
|
this.announceUpdate()
|