add MAC variant for build
This commit is contained in:
@@ -138,6 +138,14 @@ const config = {
|
||||
jsonContent.short_name = "SimpleLogin Without SL icon";
|
||||
}
|
||||
|
||||
if (process.env.MAC) {
|
||||
jsonContent.permissions.push("nativeMessaging");
|
||||
|
||||
// Change metadata
|
||||
jsonContent.name = "SimpleLogin Mac App";
|
||||
jsonContent.short_name = "SimpleLogin Mac App";
|
||||
}
|
||||
|
||||
return JSON.stringify(jsonContent, null, 2);
|
||||
},
|
||||
},
|
||||
@@ -155,6 +163,14 @@ if (config.mode === 'development') {
|
||||
]);
|
||||
}
|
||||
|
||||
if (process.env.MAC){
|
||||
config.plugins = (config.plugins || []).concat([
|
||||
new webpack.DefinePlugin({
|
||||
'process.env.MAC': JSON.stringify(!!process.env.MAC),
|
||||
}),
|
||||
]);
|
||||
}
|
||||
|
||||
if (config.mode === 'production') {
|
||||
config.plugins = (config.plugins || []).concat([
|
||||
new webpack.DefinePlugin({
|
||||
|
||||
Reference in New Issue
Block a user