pull version from Tauri build info

This commit is contained in:
Skyler Lehmkuhl 2024-12-05 14:05:34 -05:00
parent edb5020ebf
commit 55c17f5760
1 changed files with 4 additions and 2 deletions

View File

@ -14,6 +14,7 @@ const {
const { documentDir, join } = window.__TAURI__.path; const { documentDir, join } = window.__TAURI__.path;
const { Menu, MenuItem, Submenu } = window.__TAURI__.menu ; const { Menu, MenuItem, Submenu } = window.__TAURI__.menu ;
const { getCurrentWindow } = window.__TAURI__.window; const { getCurrentWindow } = window.__TAURI__.window;
const { getVersion } = window.__TAURI__.app;
const macOS = navigator.userAgent.includes('Macintosh') const macOS = navigator.userAgent.includes('Macintosh')
@ -3024,14 +3025,15 @@ async function updateMenu() {
}, },
] ]
}); });
console.log(Submenu)
const helpSubmenu = await Submenu.new({ const helpSubmenu = await Submenu.new({
text: "Help", text: "Help",
items: [ items: [
{ {
text: "About...", text: "About...",
enabled: true, enabled: true,
action: () => { action: async () => {
messageDialog(`Lightningbeam version ${appVersion}\nDeveloped by Skyler Lehmkuhl`, messageDialog(`Lightningbeam version ${await getVersion()}\nDeveloped by Skyler Lehmkuhl`,
{title: 'About', kind: "info"} {title: 'About', kind: "info"}
) )
} }