show version & bump

This commit is contained in:
Will Chen
2025-04-15 00:22:19 -07:00
parent caa9a1566e
commit 6b0df21a05
5 changed files with 40 additions and 1 deletions

View File

@@ -1071,4 +1071,11 @@ export function registerAppHandlers() {
return { success: true, message: "Successfully reset everything" };
});
ipcMain.handle("get-app-version", async () => {
// Read version from package.json at project root
const packageJsonPath = path.resolve(__dirname, "..", "..", "package.json");
const packageJson = JSON.parse(fs.readFileSync(packageJsonPath, "utf-8"));
return { version: packageJson.version };
});
}