Path: blob/main/build/azure-pipelines/common/computeBuiltInDepsCacheKey.js
3520 views
"use strict";1var __importDefault = (this && this.__importDefault) || function (mod) {2return (mod && mod.__esModule) ? mod : { "default": mod };3};4Object.defineProperty(exports, "__esModule", { value: true });5/*---------------------------------------------------------------------------------------------6* Copyright (c) Microsoft Corporation. All rights reserved.7* Licensed under the MIT License. See License.txt in the project root for license information.8*--------------------------------------------------------------------------------------------*/9const fs_1 = __importDefault(require("fs"));10const path_1 = __importDefault(require("path"));11const crypto_1 = __importDefault(require("crypto"));12const productjson = JSON.parse(fs_1.default.readFileSync(path_1.default.join(__dirname, '../../../product.json'), 'utf8'));13const shasum = crypto_1.default.createHash('sha256');14for (const ext of productjson.builtInExtensions) {15shasum.update(`${ext.name}@${ext.version}`);16}17process.stdout.write(shasum.digest('hex'));18//# sourceMappingURL=computeBuiltInDepsCacheKey.js.map1920