Mercurial > obsidian-remember-file-state
comparison esbuild.config.mjs @ 24:61fd7dde51d3
Fix build script
author | Ludovic Chabant <ludovic@chabant.com> |
---|---|
date | Fri, 18 Mar 2022 19:30:10 -0700 |
parents | 2a9e941c96ee |
children | 141f0a7d1986 |
comparison
equal
deleted
inserted
replaced
23:ba74a7d3709c | 24:61fd7dde51d3 |
---|---|
8 if you want to view the source, please visit the github repository of this plugin | 8 if you want to view the source, please visit the github repository of this plugin |
9 */ | 9 */ |
10 `; | 10 `; |
11 | 11 |
12 const prod = (process.argv[2] === 'production'); | 12 const prod = (process.argv[2] === 'production'); |
13 const outdir = (process.argv[2] === 'dogfood' ? process.argv[3] : ''); | |
14 | 13 |
15 const dirsep = (outdir.slice(-1) == '/' || outdir.slice(-1) == "\\") ? '' : '/'; | 14 var outdir = (process.argv[2] === 'dogfood' ? process.argv[3] : ''); |
16 const outfile = outdir + dirsep + 'main.js'; | 15 if (outdir != '') { |
16 if (outdir.slice(-1) != '/' && outdir.slice(-1) != "\\") { | |
17 outdir += '/'; | |
18 } | |
19 } | |
20 | |
21 const outfile = outdir + 'main.js'; | |
17 | 22 |
18 esbuild.build({ | 23 esbuild.build({ |
19 banner: { | 24 banner: { |
20 js: banner, | 25 js: banner, |
21 }, | 26 }, |