aboutsummaryrefslogtreecommitdiffstats
path: root/packages/main/esbuild.config.js
diff options
context:
space:
mode:
Diffstat (limited to 'packages/main/esbuild.config.js')
-rw-r--r--packages/main/esbuild.config.js6
1 files changed, 6 insertions, 0 deletions
diff --git a/packages/main/esbuild.config.js b/packages/main/esbuild.config.js
index af52f27..500590f 100644
--- a/packages/main/esbuild.config.js
+++ b/packages/main/esbuild.config.js
@@ -1,3 +1,4 @@
1import getRepoInfo from 'git-repo-info';
1import { node } from '../../config/buildConstants.js'; 2import { node } from '../../config/buildConstants.js';
2import { getConfig } from '../../config/esbuildConfig.js'; 3import { getConfig } from '../../config/esbuildConfig.js';
3import { fileURLToDirname } from '../../config/utils.js'; 4import { fileURLToDirname } from '../../config/utils.js';
@@ -8,6 +9,8 @@ if (process.env.MODE !== 'development') {
8 externalPackages.push('electron-devtools-installer'); 9 externalPackages.push('electron-devtools-installer');
9} 10}
10 11
12const gitInfo = getRepoInfo();
13
11export default getConfig({ 14export default getConfig({
12 absWorkingDir: fileURLToDirname(import.meta.url), 15 absWorkingDir: fileURLToDirname(import.meta.url),
13 entryPoints: [ 16 entryPoints: [
@@ -20,4 +23,7 @@ export default getConfig({
20 external: externalPackages, 23 external: externalPackages,
21}, { 24}, {
22 VITE_DEV_SERVER_URL: process.env.VITE_DEV_SERVER_URL || null, 25 VITE_DEV_SERVER_URL: process.env.VITE_DEV_SERVER_URL || null,
26 GIT_SHA: gitInfo.abbreviatedSha,
27 GIT_BRANCH: gitInfo.branch,
28 BUILD_DATE: new Date().getTime(),
23}); 29});