fix: CI and unit tests

This commit is contained in:
Ralph Khreish
2025-09-23 19:26:02 +02:00
parent 6438f6c7c8
commit b2ff06e8c5
4 changed files with 33 additions and 70 deletions

View File

@@ -18,7 +18,8 @@ export * as ui from './utils/ui.js';
export {
checkForUpdate,
performAutoUpdate,
displayUpgradeNotification
displayUpgradeNotification,
compareVersions,
} from './utils/auto-update.js';
// Re-export commonly used types from tm-core

View File

@@ -35,7 +35,7 @@ function getCurrentVersion(): string {
* @param v2 - Second version
* @returns -1 if v1 < v2, 0 if v1 = v2, 1 if v1 > v2
*/
function compareVersions(v1: string, v2: string): number {
export function compareVersions(v1: string, v2: string): number {
const toParts = (v: string) => {
const [core, pre = ''] = v.split('-', 2);
const nums = core.split('.').map((n) => Number.parseInt(n, 10) || 0);