mirror of
https://github.com/status-im/embark-area-51.git
synced 2025-01-11 22:44:45 +00:00
fix build process on windows
This commit is contained in:
parent
5a91b2d44a
commit
f37b09a371
@ -289,6 +289,7 @@ class CodeGenerator {
|
|||||||
});
|
});
|
||||||
},
|
},
|
||||||
function getImports(web3Location, next) {
|
function getImports(web3Location, next) {
|
||||||
|
web3Location = web3Location.replace(/\\/g, '/'); // Import paths must always have forward slashes
|
||||||
code += "\nimport Web3 from '" + web3Location + "';\n";
|
code += "\nimport Web3 from '" + web3Location + "';\n";
|
||||||
code += "\nimport web3 from 'Embark/web3';\n";
|
code += "\nimport web3 from 'Embark/web3';\n";
|
||||||
next();
|
next();
|
||||||
|
@ -3,6 +3,15 @@ let async = require('async');
|
|||||||
|
|
||||||
require('colors');
|
require('colors');
|
||||||
|
|
||||||
|
// Override process.chdir so that we have a partial-implementation PWD for Windows
|
||||||
|
const realChdir = process.chdir;
|
||||||
|
process.chdir = (...args) => {
|
||||||
|
if (!process.env.PWD) {
|
||||||
|
process.env.PWD = process.cwd();
|
||||||
|
}
|
||||||
|
realChdir(...args);
|
||||||
|
};
|
||||||
|
|
||||||
let Engine = require('./core/engine.js');
|
let Engine = require('./core/engine.js');
|
||||||
|
|
||||||
let version = require('../package.json').version;
|
let version = require('../package.json').version;
|
||||||
|
@ -288,6 +288,7 @@ class Pipeline {
|
|||||||
});
|
});
|
||||||
},
|
},
|
||||||
function getImports(web3Location, next) {
|
function getImports(web3Location, next) {
|
||||||
|
web3Location = web3Location.replace(/\\/g, '/'); // Import paths must always have forward slashes
|
||||||
code += "\nimport Web3 from '" + web3Location + "';\n";
|
code += "\nimport Web3 from '" + web3Location + "';\n";
|
||||||
|
|
||||||
code += "\n if (typeof web3 !== 'undefined') {";
|
code += "\n if (typeof web3 !== 'undefined') {";
|
||||||
|
Loading…
x
Reference in New Issue
Block a user