Run electron (dev) from build directory

This commit is contained in:
Jaco Greeff 2017-09-11 10:37:09 +02:00
parent ceb1dd8d83
commit 2bcdb07b62
4 changed files with 26 additions and 4 deletions

14
js/package.electron.json Normal file
View File

@ -0,0 +1,14 @@
{
"name": "Parity",
"version": "1.99.99",
"main": "electron.js",
"author": "Parity Team <admin@parity.io>",
"repository": {
"type": "git",
"url": "git+https://github.com/paritytech/parity.git"
},
"keywords": [
"Ethereum",
"Parity"
]
}

View File

@ -1,8 +1,8 @@
{ {
"name": "Parity", "name": "Parity",
"version": "1.8.19", "version": "1.8.19",
"main": "src/index.electron.js", "main": "src/index.parity.js",
"jsnext:main": "src/index.electron.js", "jsnext:main": "src/index.parity.js",
"author": "Parity Team <admin@parity.io>", "author": "Parity Team <admin@parity.io>",
"maintainers": [ "maintainers": [
"Jaco Greeff", "Jaco Greeff",
@ -46,7 +46,7 @@
"lint:js:fix": "eslint --fix --ignore-path .gitignore ./src/", "lint:js:fix": "eslint --fix --ignore-path .gitignore ./src/",
"start": "npm run clean && npm install && npm run build:lib && npm run start:app", "start": "npm run clean && npm install && npm run build:lib && npm run start:app",
"start:app": "node webpack/dev.server", "start:app": "node webpack/dev.server",
"start:electron": "npm run build:app && electron .", "start:electron": "npm run build:app && electron .build/",
"test": "NODE_ENV=test mocha --compilers ejs:ejsify 'src/**/*.spec.js' 'packages/**/*.spec.js'", "test": "NODE_ENV=test mocha --compilers ejs:ejsify 'src/**/*.spec.js' 'packages/**/*.spec.js'",
"test:coverage": "NODE_ENV=test istanbul cover _mocha -- --compilers ejs:ejsify 'src/**/*.spec.js' 'packages/**/*.spec.js'", "test:coverage": "NODE_ENV=test istanbul cover _mocha -- --compilers ejs:ejsify 'src/**/*.spec.js' 'packages/**/*.spec.js'",
"test:e2e": "NODE_ENV=test mocha 'src/**/*.e2e.js' 'packages/**/*.e2e.js'", "test:e2e": "NODE_ENV=test mocha 'src/**/*.e2e.js' 'packages/**/*.e2e.js'",

View File

@ -30,7 +30,7 @@ function createWindow () {
}); });
mainWindow.loadURL(url.format({ mainWindow.loadURL(url.format({
pathname: path.join(__dirname, '../.build', 'index.html'), pathname: path.join(__dirname, 'index.html'),
protocol: 'file:', protocol: 'file:',
slashes: true slashes: true
})); }));

View File

@ -187,6 +187,14 @@ module.exports = {
from: path.join(__dirname, '../src/error_pages.css'), from: path.join(__dirname, '../src/error_pages.css'),
to: 'styles.css' to: 'styles.css'
}, },
{
from: path.join(__dirname, '../src/index.electron.js'),
to: 'electron.js'
},
{
from: path.join(__dirname, '../package.electron.json'),
to: 'package.json'
},
flatten( flatten(
DAPPS_ALL DAPPS_ALL
.map((dapp) => { .map((dapp) => {