Add version number to settings dialog.

For the web app we also display the git hash.
This commit is contained in:
Jonatan Heyman
2024-01-12 15:08:53 +01:00
parent 37b62d416e
commit 295e55552b
6 changed files with 41 additions and 10 deletions

12
electron/main/version.js Normal file
View File

@ -0,0 +1,12 @@
import { app, ipcMain } from "electron"
import CONFIG from "../config"
export function getVersionString() {
let versionString = app.getVersion()
if (CONFIG.get("settings.allowBetaVersions")) {
versionString += " (beta channel)"
}
return versionString
}
ipcMain.handle("getVersion", () => getVersionString())