Skip to content

Commit 99d140f

Browse files
committed
alpha v6 with more logging
1 parent 5952174 commit 99d140f

File tree

3 files changed

+110
-306
lines changed

3 files changed

+110
-306
lines changed

packages/selenium-ide/package.json

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@seleniumhq/selenium-ide",
3-
"version": "4.0.0-alpha.5",
3+
"version": "4.0.0-alpha.6",
44
"private": true,
55
"description": "Selenium IDE electron app",
66
"author": "Todd <[email protected]>",
@@ -108,9 +108,9 @@
108108
"@seleniumhq/side-model": "^4.0.0-alpha.1",
109109
"@seleniumhq/side-plugin-example": "^4.0.0-alpha.1",
110110
"@seleniumhq/side-runtime": "^4.0.0-alpha.5",
111-
"electron-chromedriver": "16.0.0",
112-
"electron-log": "4.4.6",
113-
"electron-store": "^8.0.0",
111+
"electron-chromedriver": "18.3.4",
112+
"electron-log": "^4.4.8",
113+
"electron-store": "^8.1.0",
114114
"electron-unhandled": "^4.0.1",
115115
"fs-extra": "^8.1.0",
116116
"lodash": "4.17.21",
@@ -125,18 +125,18 @@
125125
"@medv/finder": "^1.1.1",
126126
"@types/copy-webpack-plugin": "8.0.1",
127127
"@types/electron": "1.6.10",
128-
"@types/electron-devtools-installer": "2.2.2",
128+
"@types/electron-devtools-installer": "^2.2.2",
129129
"@types/fs-extra": "^8.0.0",
130-
"@types/lodash": "4.14.170",
130+
"@types/lodash": "^4.14.170",
131131
"@types/react": "^17.0.14",
132132
"@types/react-dom": "^17.0.9",
133133
"@types/ua-parser-js": "^0.7.36",
134-
"@types/webpack-env": "1.16.0",
134+
"@types/webpack-env": "^1.16.0",
135135
"copy-webpack-plugin": "^10.2.4",
136136
"css-loader": "^6.1.0",
137-
"electron": "^16.0.8",
138-
"electron-builder": "^23.0.3",
139-
"electron-devtools-installer": "3.2.0",
137+
"electron": "^18.3.14",
138+
"electron-builder": "^23.5.1",
139+
"electron-devtools-installer": "^3.2.0",
140140
"fork-ts-checker-webpack-plugin": "7.2.1",
141141
"html-webpack-plugin": "^5.3.2",
142142
"npm-run-all": "^4.1.5",

packages/selenium-ide/src/main/util.ts

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
import { app } from 'electron'
12
import { debuglog, inspect } from 'util'
23

34
export const COLOR_BLACK = '\x1b[30m'
@@ -10,9 +11,12 @@ export const COLOR_CYAN = '\x1b[36m'
1011
export const COLOR_WHITE = '\x1b[37m'
1112

1213
export const vdebuglog = (namespace: string, color: string) => {
13-
const log = debuglog(namespace)
14+
const isBin = app.isPackaged
15+
const prefix = isBin ? `${namespace}: ` : color
16+
const log = isBin ? console.log : debuglog(namespace)
17+
const suffix = isBin ? '' : '\x1b[0m'
1418
return (...args: any[]) => {
1519
const str = args.map((v) => inspect(v)).join(' ')
16-
log(`${color}${str}\x1b[0m`)
20+
log(`${prefix}${str}${suffix}`)
1721
}
1822
}

0 commit comments

Comments
 (0)