Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
B
Breeze
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
3
Issues
3
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
DeStream-public
Breeze
Commits
a44ca0f1
Commit
a44ca0f1
authored
Jun 28, 2017
by
dev0tion
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Spawn API when in production mode
parent
2eb621a1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
11 additions
and
6 deletions
+11
-6
main.ts
Breeze.UI/main.ts
+11
-6
No files found.
Breeze.UI/main.ts
View file @
a44ca0f1
...
@@ -51,7 +51,12 @@ function createWindow() {
...
@@ -51,7 +51,12 @@ function createWindow() {
// initialization and is ready to create browser windows.
// initialization and is ready to create browser windows.
// Some APIs can only be used after this event occurs.
// Some APIs can only be used after this event occurs.
app
.
on
(
'ready'
,
function
()
{
app
.
on
(
'ready'
,
function
()
{
//startApi();
if
(
serve
)
{
console
.
log
(
"Breeze UI was started in development mode. This requires the user to be running the Breeze Daemon himself."
)
}
else
{
startApi
();
}
createTray
();
createTray
();
createWindow
();
createWindow
();
})
})
...
@@ -74,16 +79,16 @@ app.on('activate', function () {
...
@@ -74,16 +79,16 @@ app.on('activate', function () {
});
});
function
startApi
()
{
function
startApi
()
{
let
apiProcess
;
var
apiProcess
;
var
spawn
=
require
(
'child_process'
).
spawn
;
const
spawn
=
require
(
'child_process'
).
spawn
;
//Start Breeze Daemon
//Start Breeze Daemon
apipath
=
path
.
join
(
__dirname
,
'
'
);
let
apipath
=
path
.
join
(
__dirname
,
'..//..//daemon//Breeze.Daemon
'
);
if
(
os
.
platform
()
===
'win32'
)
{
if
(
os
.
platform
()
===
'win32'
)
{
var
apipath
=
path
.
join
(
__dirname
,
'
'
);
apipath
=
path
.
join
(
__dirname
,
'.
\\
assets
\\
daemon
\\
Breeze.Daemon.exe
'
);
}
}
apiProcess
=
spawn
(
apipath
,
{
apiProcess
=
spawn
(
apipath
+
' light -testnet'
,
{
detached
:
true
detached
:
true
});
});
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment