electron判断当前操作系统是windows还是mac,可以用node.js中的process.platform来判断
if(process
.platform
== 'darwin'){
console
.log('这是mac系统');
}
if(process
.platform
== 'win32'){
console
.log('这是windows系统');
}
if(process
.platform
== 'linux'){
console
.log('这是linux系统');
}