builder-util-runtime
Advanced tools
Comparing version 2.0.0 to 2.0.1
@@ -16,1 +16,2 @@ export declare const BLOCK_MAP_FILE_NAME = "_blockMap.yml"; | ||
} | ||
export declare function readBlockMapDataFromAppImage(file: string): Promise<any>; |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { | ||
value: true | ||
value: true | ||
}); | ||
exports.readBlockMapDataFromAppImage = exports.SIGNATURE_HEADER_SIZE = exports.BLOCK_MAP_FILE_NAME = undefined; | ||
var _bluebirdLst; | ||
function _load_bluebirdLst() { | ||
return _bluebirdLst = require("bluebird-lst"); | ||
} | ||
var _bluebirdLst2; | ||
function _load_bluebirdLst2() { | ||
return _bluebirdLst2 = _interopRequireDefault(require("bluebird-lst")); | ||
} | ||
let readBlockMapDataFromAppImage = exports.readBlockMapDataFromAppImage = (() => { | ||
var _ref = (0, (_bluebirdLst || _load_bluebirdLst()).coroutine)(function* (file) { | ||
const fd = yield (0, (_fsExtraP || _load_fsExtraP()).open)(file, "r"); | ||
try { | ||
const fileSize = (yield (0, (_fsExtraP || _load_fsExtraP()).fstat)(fd)).size; | ||
const sizeBuffer = Buffer.allocUnsafe(4); | ||
yield (0, (_fsExtraP || _load_fsExtraP()).read)(fd, sizeBuffer, 0, sizeBuffer.length, fileSize - sizeBuffer.length); | ||
const dataBuffer = Buffer.allocUnsafe(sizeBuffer.readUInt32BE(0)); | ||
yield (0, (_fsExtraP || _load_fsExtraP()).read)(fd, dataBuffer, 0, dataBuffer.length, fileSize - sizeBuffer.length - dataBuffer.length); | ||
yield (0, (_fsExtraP || _load_fsExtraP()).close)(fd); | ||
const inflateRaw = (_bluebirdLst2 || _load_bluebirdLst2()).default.promisify(require("zlib").inflateRaw); | ||
return (yield inflateRaw(dataBuffer)).toString(); | ||
} catch (e) { | ||
yield (0, (_fsExtraP || _load_fsExtraP()).close)(fd); | ||
throw e; | ||
} | ||
}); | ||
return function readBlockMapDataFromAppImage(_x) { | ||
return _ref.apply(this, arguments); | ||
}; | ||
})(); | ||
//# sourceMappingURL=blockMapApi.js.map | ||
var _fsExtraP; | ||
function _load_fsExtraP() { | ||
return _fsExtraP = require("fs-extra-p"); | ||
} | ||
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } | ||
const BLOCK_MAP_FILE_NAME = exports.BLOCK_MAP_FILE_NAME = "_blockMap.yml"; | ||
const SIGNATURE_HEADER_SIZE = exports.SIGNATURE_HEADER_SIZE = 12 /* signature + 2 bytes version + 4 bytes CRC */ + 20; | ||
//# sourceMappingURL=blockMapApi.js.map | ||
const SIGNATURE_HEADER_SIZE = exports.SIGNATURE_HEADER_SIZE = 12 /* signature + 2 bytes version + 4 bytes CRC */ + 20; |
export { CancellationToken, CancellationError } from "./CancellationToken"; | ||
export { HttpError, HttpExecutor, DownloadOptions, DigestTransform, RequestHeaders, safeGetHeader, configureRequestOptions, configureRequestOptionsFromUrl, safeStringifyJson, parseJson } from "./httpExecutor"; | ||
export { BintrayOptions, GenericServerOptions, GithubOptions, PublishConfiguration, S3Options, SpacesOptions, BaseS3Options, getS3LikeProviderBaseUrl, Publish, githubUrl, PublishProvider, AllPublishOptions } from "./publishOptions"; | ||
export { UpdateInfo, VersionInfo, PackageFileInfo } from "./updateInfo"; | ||
export { UpdateInfo, WindowsUpdateInfo, AppImageUpdateInfo, BlockMapDataHolder, VersionInfo, PackageFileInfo } from "./updateInfo"; | ||
export { parseDn } from "./rfc2253Parser"; | ||
export { UUID } from "./uuid"; | ||
export { ProgressCallbackTransform, ProgressInfo } from "./ProgressCallbackTransform"; |
@@ -7,8 +7,10 @@ export interface VersionInfo { | ||
} | ||
export interface PackageFileInfo { | ||
file: string; | ||
export interface BlockMapDataHolder { | ||
size: number; | ||
sha512: string; | ||
blockMapSize: number; | ||
readonly sha512: string; | ||
} | ||
export interface PackageFileInfo extends BlockMapDataHolder { | ||
readonly path: string; | ||
headerSize?: number; | ||
blockMapSize?: number; | ||
blockMapData?: string; | ||
@@ -18,5 +20,3 @@ } | ||
readonly path: string; | ||
packages?: { | ||
[arch: string]: PackageFileInfo; | ||
} | null; | ||
readonly sha512: string; | ||
githubArtifactName?: string | null; | ||
@@ -36,8 +36,2 @@ /** | ||
/** | ||
* @deprecated | ||
* @private | ||
*/ | ||
readonly sha2?: string; | ||
readonly sha512?: string; | ||
/** | ||
* The [staged rollout](auto-update.md#staged-rollouts) percentage, 0-100. | ||
@@ -47,1 +41,13 @@ */ | ||
} | ||
export interface AppImageUpdateInfo extends UpdateInfo, BlockMapDataHolder { | ||
} | ||
export interface WindowsUpdateInfo extends UpdateInfo { | ||
packages?: { | ||
[arch: string]: PackageFileInfo; | ||
} | null; | ||
/** | ||
* @deprecated | ||
* @private | ||
*/ | ||
sha2?: string; | ||
} |
{ | ||
"name": "builder-util-runtime", | ||
"version": "2.0.0", | ||
"version": "2.0.1", | ||
"main": "out/index.js", | ||
@@ -18,3 +18,3 @@ "author": "Vladimir Krivosheev", | ||
"debug": "^3.1.0", | ||
"fs-extra-p": "^4.4.3", | ||
"fs-extra-p": "^4.4.4", | ||
"bluebird-lst": "^1.0.4" | ||
@@ -21,0 +21,0 @@ }, |
Sorry, the diff of this file is not supported yet
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
138845
1561
3
Updatedfs-extra-p@^4.4.4