-
-
Notifications
You must be signed in to change notification settings - Fork 1.8k
Closed
qcif/data-curator
#563Labels
Description
I'm using electron-builder 5.1.0 to generate an installer for my app. I hoped the build command can help me a way to run some logging or checking code only in test version but it looks not support this yet.
My idea is like to add an option "--add-pakcage-json-field" to build command. It only put the given field and string to the application package.json.
So I use command:
build --win --x64 --add-package-json-field "env" "test"
My app get a modified package.json:
{
// other fields like name, version
// and a new item appended
"env": "test"
}
That way I can check the 'env' field in code and package my app in 2 commands, rather than modifying code manually.
Look forward to this feature if possible.