Merge pull request #7869 from electron/less-browserify-build-time
Only run browserify when sandbox files change
This commit is contained in:
commit
8e834e9047
4 changed files with 9 additions and 5 deletions
|
@ -436,10 +436,6 @@
|
||||||
'action_name': 'atom_browserify',
|
'action_name': 'atom_browserify',
|
||||||
'inputs': [
|
'inputs': [
|
||||||
'<@(browserify_entries)',
|
'<@(browserify_entries)',
|
||||||
# Any js file under `lib/` can be included in the preload bundle.
|
|
||||||
# Add all js sources as dependencies so any change to a js file will
|
|
||||||
# trigger a rebuild of the bundle(and consequently of js2c).
|
|
||||||
'<@(js_sources)',
|
|
||||||
],
|
],
|
||||||
'outputs': [
|
'outputs': [
|
||||||
'<(js2c_input_dir)/preload_bundle.js',
|
'<(js2c_input_dir)/preload_bundle.js',
|
||||||
|
@ -447,9 +443,10 @@
|
||||||
'action': [
|
'action': [
|
||||||
'npm',
|
'npm',
|
||||||
'run',
|
'run',
|
||||||
|
'--silent',
|
||||||
'browserify',
|
'browserify',
|
||||||
'--',
|
'--',
|
||||||
'<@(browserify_entries)',
|
'lib/sandboxed_renderer/init.js',
|
||||||
'-o',
|
'-o',
|
||||||
'<@(_outputs)',
|
'<@(_outputs)',
|
||||||
],
|
],
|
||||||
|
|
|
@ -73,6 +73,7 @@
|
||||||
'lib/renderer/extensions/web-navigation.js',
|
'lib/renderer/extensions/web-navigation.js',
|
||||||
],
|
],
|
||||||
'browserify_entries': [
|
'browserify_entries': [
|
||||||
|
'lib/renderer/api/ipc-renderer-setup.js',
|
||||||
'lib/sandboxed_renderer/init.js',
|
'lib/sandboxed_renderer/init.js',
|
||||||
],
|
],
|
||||||
'js2c_sources': [
|
'js2c_sources': [
|
||||||
|
|
|
@ -1,3 +1,6 @@
|
||||||
|
// Any requires added here need to be added to the browserify_entries array
|
||||||
|
// in filenames.gypi so they get built into the preload_bundle.js bundle
|
||||||
|
|
||||||
module.exports = function (ipcRenderer, binding) {
|
module.exports = function (ipcRenderer, binding) {
|
||||||
ipcRenderer.send = function (...args) {
|
ipcRenderer.send = function (...args) {
|
||||||
return binding.send('ipc-message', args)
|
return binding.send('ipc-message', args)
|
||||||
|
|
|
@ -1,3 +1,6 @@
|
||||||
|
// Any requires added here need to be added to the browserify_entries array
|
||||||
|
// in filenames.gypi so they get built into the preload_bundle.js bundle
|
||||||
|
|
||||||
/* eslint no-eval: "off" */
|
/* eslint no-eval: "off" */
|
||||||
/* global binding, preloadPath, process, Buffer */
|
/* global binding, preloadPath, process, Buffer */
|
||||||
const events = require('events')
|
const events = require('events')
|
||||||
|
|
Loading…
Reference in a new issue