electron-info
Advanced tools
Comparing version 1.1.0 to 1.2.0
@@ -0,1 +1,7 @@ | ||
# [1.2.0](https://github.com/ffflorian/electron-info/compare/v1.1.0...v1.2.0) (2019-07-25) | ||
### Features | ||
- Display all releases with Chrome version ([c0d8fdb](https://github.com/ffflorian/electron-info/commit/c0d8fdb)) | ||
# [1.1.0](https://github.com/ffflorian/electron-info/compare/v1.0.0...v1.1.0) (2019-07-25) | ||
@@ -2,0 +8,0 @@ |
@@ -35,3 +35,7 @@ #!/usr/bin/env node | ||
const releases = yield new ElectronInfo_1.ElectronInfo().getChromeVersion(version, !parent.raw); | ||
console.log(releases); | ||
if (releases) { | ||
for (const release of releases) { | ||
console.log(release); | ||
} | ||
} | ||
} | ||
@@ -38,0 +42,0 @@ catch (error) { |
@@ -33,5 +33,5 @@ export interface RawDeps { | ||
getAll(formatted: true): Promise<string>; | ||
getChromeVersion(version: string, formatted?: false): Promise<RawReleaseInfo | void>; | ||
getChromeVersion(version: string, formatted?: boolean): Promise<RawReleaseInfo | string | void>; | ||
getChromeVersion(version: string, formatted: true): Promise<string | void>; | ||
getChromeVersion(version: string, formatted?: false): Promise<RawReleaseInfo[] | void>; | ||
getChromeVersion(version: string, formatted?: boolean): Promise<RawReleaseInfo[] | string[] | void>; | ||
getChromeVersion(version: string, formatted: true): Promise<string[] | void>; | ||
getElectronVersion(version: string, formatted?: false): Promise<RawReleaseInfo | void>; | ||
@@ -38,0 +38,0 @@ getElectronVersion(version: string, formatted?: boolean): Promise<RawReleaseInfo | string | void>; |
@@ -46,8 +46,8 @@ "use strict"; | ||
const releases = yield this.getAll(false); | ||
const release = releases.find(release => release.deps && release.deps.chrome === parsedVersion); | ||
if (release) { | ||
const chromeReleases = releases.filter(release => release.deps && release.deps.chrome === parsedVersion); | ||
if (chromeReleases) { | ||
if (formatted) { | ||
return this.formatChromeRelease(release); | ||
return chromeReleases.map(release => this.formatChromeRelease(release)); | ||
} | ||
return release; | ||
return chromeReleases; | ||
} | ||
@@ -54,0 +54,0 @@ }); |
@@ -79,3 +79,3 @@ { | ||
}, | ||
"version": "1.1.0" | ||
"version": "1.2.0" | ||
} |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
22213
274