bump linked artifact toolkit pkg

This commit is contained in:
Rob Herley 2023-10-16 14:40:44 -04:00
parent 8c323b340c
commit 57685c7c71
No known key found for this signature in database
GPG key ID: D1602042C3543B06

18
dist/index.js vendored
View file

@ -6994,7 +6994,7 @@ var ArtifactServiceMethod;
(function (ArtifactServiceMethod) { (function (ArtifactServiceMethod) {
ArtifactServiceMethod["CreateArtifact"] = "CreateArtifact"; ArtifactServiceMethod["CreateArtifact"] = "CreateArtifact";
ArtifactServiceMethod["FinalizeArtifact"] = "FinalizeArtifact"; ArtifactServiceMethod["FinalizeArtifact"] = "FinalizeArtifact";
})(ArtifactServiceMethod = exports.ArtifactServiceMethod || (exports.ArtifactServiceMethod = {})); })(ArtifactServiceMethod || (exports.ArtifactServiceMethod = ArtifactServiceMethod = {}));
exports.ArtifactServiceMethodList = [ exports.ArtifactServiceMethodList = [
ArtifactServiceMethod.CreateArtifact, ArtifactServiceMethod.CreateArtifact,
ArtifactServiceMethod.FinalizeArtifact ArtifactServiceMethod.FinalizeArtifact
@ -8009,9 +8009,9 @@ function uploadZipToBlobStorage(authenticatedUploadURL, zipUploadStream) {
blobHTTPHeaders: { blobContentType: 'zip' }, blobHTTPHeaders: { blobContentType: 'zip' },
onProgress: uploadCallback onProgress: uploadCallback
}; };
let md5Hash = undefined; let sha256Hash = undefined;
const uploadStream = new stream.PassThrough(); const uploadStream = new stream.PassThrough();
const hashStream = crypto.createHash('md5'); const hashStream = crypto.createHash('sha256');
zipUploadStream.pipe(uploadStream); // This stream is used for the upload zipUploadStream.pipe(uploadStream); // This stream is used for the upload
zipUploadStream.pipe(hashStream).setEncoding('hex'); // This stream is used to compute a hash of the zip content that gets used. Integrity check zipUploadStream.pipe(hashStream).setEncoding('hex'); // This stream is used to compute a hash of the zip content that gets used. Integrity check
try { try {
@ -8019,8 +8019,8 @@ function uploadZipToBlobStorage(authenticatedUploadURL, zipUploadStream) {
yield blockBlobClient.uploadStream(uploadStream, bufferSize, maxBuffers, options); yield blockBlobClient.uploadStream(uploadStream, bufferSize, maxBuffers, options);
core.info('Finished uploading artifact content to blob storage!'); core.info('Finished uploading artifact content to blob storage!');
hashStream.end(); hashStream.end();
md5Hash = hashStream.read(); sha256Hash = hashStream.read();
core.info(`MD5 hash of uploaded artifact zip is ${md5Hash}`); core.info(`SHA256 hash of uploaded artifact zip is ${sha256Hash}`);
} }
catch (error) { catch (error) {
core.warning(`Failed to upload artifact zip to blob storage, error: ${error}`); core.warning(`Failed to upload artifact zip to blob storage, error: ${error}`);
@ -8037,7 +8037,7 @@ function uploadZipToBlobStorage(authenticatedUploadURL, zipUploadStream) {
return { return {
isSuccess: true, isSuccess: true,
uploadSize: uploadByteCount, uploadSize: uploadByteCount,
md5Hash sha256Hash
}; };
}); });
} }
@ -8286,9 +8286,9 @@ function uploadArtifact(name, files, rootDirectory, options) {
name, name,
size: uploadResult.uploadSize ? uploadResult.uploadSize.toString() : '0' size: uploadResult.uploadSize ? uploadResult.uploadSize.toString() : '0'
}; };
if (uploadResult.md5Hash) { if (uploadResult.sha256Hash) {
finalizeArtifactReq.hash = generated_1.StringValue.create({ finalizeArtifactReq.hash = generated_1.StringValue.create({
value: `md5:${uploadResult.md5Hash}` value: `sha256:${uploadResult.sha256Hash}`
}); });
} }
core.info(`Finalizing artifact upload`); core.info(`Finalizing artifact upload`);
@ -118999,7 +118999,7 @@ module.exports = JSON.parse('[[[0,44],"disallowed_STD3_valid"],[[45,46],"valid"]
/***/ ((module) => { /***/ ((module) => {
"use strict"; "use strict";
module.exports = JSON.parse('{"name":"@actions/artifact","version":"2.0.0","preview":true,"description":"Actions artifact lib","keywords":["github","actions","artifact"],"homepage":"https://github.com/actions/toolkit/tree/main/packages/artifact","license":"MIT","main":"lib/artifact.js","types":"lib/artifact.d.ts","directories":{"lib":"lib","test":"__tests__"},"files":["lib","!.DS_Store"],"publishConfig":{"access":"public"},"repository":{"type":"git","url":"git+https://github.com/actions/toolkit.git","directory":"packages/artifact"},"scripts":{"audit-moderate":"npm install && npm audit --json --audit-level=moderate > audit.json","test":"echo \\"Error: run tests from root\\" && exit 1","bootstrap":"cd ../../ && npm run bootstrap","tsc-run":"tsc","tsc":"npm run bootstrap && npm run tsc-run"},"bugs":{"url":"https://github.com/actions/toolkit/issues"},"dependencies":{"@actions/core":"^1.10.0","@actions/github":"^5.1.1","@actions/http-client":"^2.1.0","@azure/storage-blob":"^12.15.0","@octokit/core":"^3.5.1","@octokit/plugin-request-log":"^1.0.4","@octokit/plugin-retry":"^3.0.9","@octokit/request-error":"^5.0.0","@protobuf-ts/plugin":"^2.2.3-alpha.1","@types/unzipper":"^0.10.6","archiver":"^5.3.1","crypto":"^1.0.1","jwt-decode":"^3.1.2","twirp-ts":"^2.5.0","unzipper":"^0.10.14"},"devDependencies":{"@types/archiver":"^5.3.2","typescript":"^4.3.0"}}'); module.exports = JSON.parse('{"name":"@actions/artifact","version":"2.0.0","preview":true,"description":"Actions artifact lib","keywords":["github","actions","artifact"],"homepage":"https://github.com/actions/toolkit/tree/main/packages/artifact","license":"MIT","main":"lib/artifact.js","types":"lib/artifact.d.ts","directories":{"lib":"lib","test":"__tests__"},"files":["lib","!.DS_Store"],"publishConfig":{"access":"public"},"repository":{"type":"git","url":"git+https://github.com/actions/toolkit.git","directory":"packages/artifact"},"scripts":{"audit-moderate":"npm install && npm audit --json --audit-level=moderate > audit.json","test":"echo \\"Error: run tests from root\\" && exit 1","bootstrap":"cd ../../ && npm run bootstrap","tsc-run":"tsc","tsc":"npm run bootstrap && npm run tsc-run"},"bugs":{"url":"https://github.com/actions/toolkit/issues"},"dependencies":{"@actions/core":"^1.10.0","@actions/github":"^5.1.1","@actions/http-client":"^2.1.0","@azure/storage-blob":"^12.15.0","@octokit/core":"^3.5.1","@octokit/plugin-request-log":"^1.0.4","@octokit/plugin-retry":"^3.0.9","@octokit/request-error":"^5.0.0","@protobuf-ts/plugin":"^2.2.3-alpha.1","@types/unzipper":"^0.10.6","archiver":"^5.3.1","crypto":"^1.0.1","jwt-decode":"^3.1.2","twirp-ts":"^2.5.0","unzipper":"^0.10.14"},"devDependencies":{"@types/archiver":"^5.3.2","typescript":"^5.2.2"}}');
/***/ }) /***/ })