ci: added automatic versioning

Signed-off-by: Varun Raj <varun@skcript.com>
This commit is contained in:
Varun Raj
2024-11-21 19:49:31 +05:30
parent 9488f8dd83
commit bd511ce5b8
4 changed files with 5 additions and 11 deletions
+1 -7
View File
@@ -1,11 +1,5 @@
/** @type {import('next').NextConfig} */
import { readFileSync } from 'fs';
const { version } = JSON.parse(readFileSync('./package.json', 'utf-8'));
console.log(`Version: ${version}`);
const nextConfig = {
reactStrictMode: false,
output: 'standalone',
@@ -13,7 +7,7 @@ const nextConfig = {
unoptimized: true,
},
env: {
VERSION: process.env.BUILD_VERSION || version,
VERSION: process.env.VERSION,
},
};