mirror of
https://github.com/kccleoc/seedpgp-web.git
synced 2026-03-07 01:47:52 +08:00
feat(v1.3.0): add ephemeral session-key encryption for sensitive state
This commit is contained in:
@@ -1,5 +1,14 @@
|
||||
import { defineConfig } from 'vite'
|
||||
import react from '@vitejs/plugin-react'
|
||||
import { execSync } from 'child_process'
|
||||
import fs from 'fs'
|
||||
|
||||
// Read version from package.json
|
||||
const packageJson = JSON.parse(fs.readFileSync('./package.json', 'utf-8'))
|
||||
const appVersion = packageJson.version
|
||||
|
||||
// Get git commit hash
|
||||
const gitHash = execSync('git rev-parse --short HEAD').toString().trim()
|
||||
|
||||
export default defineConfig({
|
||||
plugins: [react()],
|
||||
@@ -7,5 +16,9 @@ export default defineConfig({
|
||||
build: {
|
||||
outDir: 'dist',
|
||||
emptyOutDir: false,
|
||||
},
|
||||
define: {
|
||||
'__APP_VERSION__': JSON.stringify(appVersion),
|
||||
'__BUILD_HASH__': JSON.stringify(gitHash),
|
||||
}
|
||||
})
|
||||
|
||||
Reference in New Issue
Block a user