Updater debug utility
This commit is contained in:
parent
e7e9021e3f
commit
759ced3417
14 changed files with 409 additions and 15 deletions
|
@ -40,8 +40,13 @@ const { platform } = process;
|
|||
|
||||
export const ACK_RENDER_TIMEOUT = 10000;
|
||||
|
||||
export type UpdaterInterface = {
|
||||
force(): Promise<void>;
|
||||
};
|
||||
|
||||
export async function checkForUpdates(
|
||||
logger: LoggerType
|
||||
logger: LoggerType,
|
||||
forceUpdate = false
|
||||
): Promise<{
|
||||
fileName: string;
|
||||
version: string;
|
||||
|
@ -55,8 +60,11 @@ export async function checkForUpdates(
|
|||
return null;
|
||||
}
|
||||
|
||||
if (isVersionNewer(version)) {
|
||||
logger.info(`checkForUpdates: found newer version ${version}`);
|
||||
if (forceUpdate || isVersionNewer(version)) {
|
||||
logger.info(
|
||||
`checkForUpdates: found newer version ${version} ` +
|
||||
`forceUpdate=${forceUpdate}`
|
||||
);
|
||||
|
||||
return {
|
||||
fileName: getUpdateFileName(yaml),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue