mirror of https://github.com/keeweb/keeweb
parent
b944e36d5c
commit
dc6afb765a
|
@ -5,6 +5,9 @@ const path = require('path');
|
|||
|
||||
const webpackConfig = require('./build/webpack.config');
|
||||
const pkg = require('./package.json');
|
||||
const hookRcedit = require('./build/util/hook-rcedit');
|
||||
|
||||
hookRcedit.setup();
|
||||
|
||||
module.exports = function(grunt) {
|
||||
require('time-grunt')(grunt);
|
||||
|
|
|
@ -0,0 +1,21 @@
|
|||
const childProcess = require('child_process');
|
||||
|
||||
// remove this once wine can be run on macOS
|
||||
|
||||
const childProcessSpawn = childProcess.spawn;
|
||||
|
||||
function hookedSpawn(command, options) {
|
||||
if (command === 'wine') {
|
||||
options = options.map(option => {
|
||||
if (option.includes(' ')) {
|
||||
option = `"${option.replace('"', '\\"')}"`;
|
||||
}
|
||||
return option;
|
||||
});
|
||||
}
|
||||
return childProcessSpawn.call(childProcess, command, options);
|
||||
}
|
||||
|
||||
module.exports.setup = function() {
|
||||
childProcess.spawn = hookedSpawn;
|
||||
};
|
Loading…
Reference in New Issue