mirror of
https://github.com/Llewellynvdm/nativefier.git
synced 2024-11-11 07:41:04 +00:00
Update eslint to v2.0.0
This commit is contained in:
parent
f262252ade
commit
960f3362c9
@ -34,7 +34,8 @@ module.exports = {
|
|||||||
'valid-jsdoc': 0,
|
'valid-jsdoc': 0,
|
||||||
'no-path-concat': 1,
|
'no-path-concat': 1,
|
||||||
'quote-props': [2, 'as-needed'],
|
'quote-props': [2, 'as-needed'],
|
||||||
'no-warning-comments': 1
|
'no-warning-comments': 1,
|
||||||
|
'no-control-regex': 0
|
||||||
},
|
},
|
||||||
env: {
|
env: {
|
||||||
es6: true,
|
es6: true,
|
||||||
|
@ -69,10 +69,10 @@
|
|||||||
"babel-register": "^6.6.0",
|
"babel-register": "^6.6.0",
|
||||||
"chai": "^3.4.1",
|
"chai": "^3.4.1",
|
||||||
"del": "^2.2.0",
|
"del": "^2.2.0",
|
||||||
"eslint-config-google": "^0.3.0",
|
"eslint-config-google": "^0.5.0",
|
||||||
"gulp": "^3.9.0",
|
"gulp": "^3.9.0",
|
||||||
"gulp-babel": "^6.1.1",
|
"gulp-babel": "^6.1.1",
|
||||||
"gulp-eslint": "^1.1.1",
|
"gulp-eslint": "^2.0.0",
|
||||||
"gulp-istanbul": "^0.10.3",
|
"gulp-istanbul": "^0.10.3",
|
||||||
"gulp-mocha": "^2.2.0",
|
"gulp-mocha": "^2.2.0",
|
||||||
"gulp-sourcemaps": "^1.6.0",
|
"gulp-sourcemaps": "^1.6.0",
|
||||||
|
@ -16,7 +16,7 @@ function getChromeVersionForElectronVersion(electronVersion, url = ELECTRON_VERS
|
|||||||
const electronVersionToChromeVersion = _.zipObject(data.map(d => d.version), data.map(d => d.chrome));
|
const electronVersionToChromeVersion = _.zipObject(data.map(d => d.version), data.map(d => d.chrome));
|
||||||
|
|
||||||
if (!(electronVersion in electronVersionToChromeVersion)) {
|
if (!(electronVersion in electronVersionToChromeVersion)) {
|
||||||
throw `Electron version '${ electronVersion }' not found in retrieved version list!`;
|
throw `Electron version '${electronVersion}' not found in retrieved version list!`;
|
||||||
}
|
}
|
||||||
|
|
||||||
return electronVersionToChromeVersion[electronVersion];
|
return electronVersionToChromeVersion[electronVersion];
|
||||||
@ -27,13 +27,13 @@ export function getUserAgentString(chromeVersion, platform) {
|
|||||||
let userAgent;
|
let userAgent;
|
||||||
switch (platform) {
|
switch (platform) {
|
||||||
case 'darwin':
|
case 'darwin':
|
||||||
userAgent = `Mozilla/5.0 (Macintosh; Intel Mac OS X 10_10_1) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/${ chromeVersion } Safari/537.36`;
|
userAgent = `Mozilla/5.0 (Macintosh; Intel Mac OS X 10_10_1) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/${chromeVersion} Safari/537.36`;
|
||||||
break;
|
break;
|
||||||
case 'win32':
|
case 'win32':
|
||||||
userAgent = `Mozilla/5.0 (Windows NT 6.1) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/${ chromeVersion } Safari/537.36`;
|
userAgent = `Mozilla/5.0 (Windows NT 6.1) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/${chromeVersion} Safari/537.36`;
|
||||||
break;
|
break;
|
||||||
case 'linux':
|
case 'linux':
|
||||||
userAgent = `Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/${ chromeVersion } Safari/537.36`;
|
userAgent = `Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/${chromeVersion} Safari/537.36`;
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
throw 'Error invalid platform specified to getUserAgentString()';
|
throw 'Error invalid platform specified to getUserAgentString()';
|
||||||
|
Loading…
Reference in New Issue
Block a user