Add version to the ui

This commit is contained in:
Jaret Burkett committed 2026-05-26 07:30:09 -06:00
1 parent 266956068a
commit 76c99da4e4
2 files changed
+12

No files matched your search

+9
View File
@@ -1,6 +1,15 @@
import type { NextConfig } from 'next';
import { readFileSync } from 'fs';
import { join } from 'path';
const versionFile = readFileSync(join(__dirname, '..', 'version.py'), 'utf8');
const versionMatch = versionFile.match(/VERSION\s*=\s*["']([^"']+)["']/);
const appVersion = versionMatch ? versionMatch[1] : 'unknown';
const nextConfig: NextConfig = {
env: {
NEXT_PUBLIC_APP_VERSION: appVersion,
},
serverExternalPackages: ['macstats', 'osx-temperature-sensor'],
webpack: (config, { isServer }) => {
if (isServer) {