mirror of
https://github.com/actions/setup-java.git
synced 2026-08-25 10:03:13 +01:00
chore(deps): combine open Dependabot npm updates (#1252)
* Combine Dependabot npm updates Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> * Rebuild action bundles Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> Copilot-Session: a5d254ad-e29c-4477-ae66-cba6e36d7e03 * Update Licensed cache for XML dependencies Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> Copilot-Session: a5d254ad-e29c-4477-ae66-cba6e36d7e03 --------- Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> Copilot-Session: a5d254ad-e29c-4477-ae66-cba6e36d7e03
This commit is contained in:
61
dist/setup/824.index.js
vendored
61
dist/setup/824.index.js
vendored
@@ -741,12 +741,26 @@ class XmlNode {
|
||||
this.child.push({ [node.tagname]: node.child });
|
||||
}
|
||||
// if requested, add the startIndex
|
||||
this.addStartIndex(startIndex);
|
||||
}
|
||||
|
||||
addStartIndex(startIndex) {
|
||||
if (startIndex !== undefined) {
|
||||
// Note: for now we just overwrite the metadata. If we had more complex metadata,
|
||||
// we might need to do an object append here: metadata = { ...metadata, startIndex }
|
||||
this.child[this.child.length - 1][METADATA_SYMBOL] = { startIndex };
|
||||
}
|
||||
}
|
||||
|
||||
addEndIndex(endIndex) {
|
||||
const lastChild = this.child[this.child.length - 1];
|
||||
// endIndex is write-once: when updateTag drops a node, the last child is a
|
||||
// previously completed sibling whose endIndex must not be overwritten
|
||||
if (lastChild !== undefined && lastChild[METADATA_SYMBOL] !== undefined
|
||||
&& lastChild[METADATA_SYMBOL].endIndex === undefined) {
|
||||
lastChild[METADATA_SYMBOL].endIndex = endIndex;
|
||||
}
|
||||
}
|
||||
/** symbol used for metadata */
|
||||
static getMetaDataSymbol() {
|
||||
return METADATA_SYMBOL;
|
||||
@@ -781,8 +795,23 @@ class DocTypeReader {
|
||||
i = i + 9;
|
||||
let angleBracketsCount = 1;
|
||||
let hasBody = false, comment = false;
|
||||
let quoteChar = null; // tracks an open SYSTEM/PUBLIC literal before the '[' body
|
||||
let exp = "";
|
||||
for (; i < xmlData.length; i++) {
|
||||
// Inside a quoted external-identifier literal — XML allows '<'
|
||||
// and '>' as plain data here, so they must not be interpreted
|
||||
// as DOCTYPE structure until the matching quote closes.
|
||||
if (quoteChar !== null) {
|
||||
if (xmlData[i] === quoteChar) quoteChar = null;
|
||||
exp += xmlData[i];
|
||||
continue;
|
||||
}
|
||||
if (!hasBody && !comment && (xmlData[i] === '"' || xmlData[i] === "'")) {
|
||||
quoteChar = xmlData[i];
|
||||
exp += xmlData[i];
|
||||
continue;
|
||||
}
|
||||
|
||||
if (xmlData[i] === '<' && !comment) { //Determine the tag type
|
||||
if (hasBody && hasSeq(xmlData, "!ENTITY", i)) {
|
||||
i += 7;
|
||||
@@ -837,7 +866,7 @@ class DocTypeReader {
|
||||
exp += xmlData[i];
|
||||
}
|
||||
}
|
||||
if (angleBracketsCount !== 0) {
|
||||
if (quoteChar !== null || angleBracketsCount !== 0) {
|
||||
throw new Error(`Unclosed DOCTYPE`);
|
||||
}
|
||||
} else {
|
||||
@@ -1552,7 +1581,11 @@ function resolveEnotation(str, trimmedStr, options) {
|
||||
*/
|
||||
function trimZeros(numStr) {
|
||||
if (numStr && numStr.indexOf(".") !== -1) {//float
|
||||
numStr = numStr.replace(/0+$/, ""); //remove ending zeros
|
||||
//remove ending zeros without the O(n^2) backtracking that /0+$/ hits
|
||||
//when the string doesn't end in 0 but has a long internal zero-run
|
||||
let end = numStr.length;
|
||||
while (end > 0 && numStr.charCodeAt(end - 1) === 48 /* '0' */) end--;
|
||||
numStr = numStr.slice(0, end);
|
||||
if (numStr === ".") numStr = "0";
|
||||
else if (numStr[0] === ".") numStr = "0" + numStr;
|
||||
else if (numStr[numStr.length - 1] === ".") numStr = numStr.substring(0, numStr.length - 1);
|
||||
@@ -5032,7 +5065,12 @@ const parseXml = function (xmlData) {
|
||||
this.matcher.pop();
|
||||
this.isCurrentNodeStopNode = false; // Reset flag when closing tag
|
||||
|
||||
currentNode = this.tagsNodeStack.pop();//avoid recursion, set the parent tag scope
|
||||
//a closing tag with no matching opening tag leaves the stack empty
|
||||
currentNode = this.tagsNodeStack.pop() || xmlObj;//avoid recursion, set the parent tag scope
|
||||
|
||||
if (options.captureMetaData && currentNode) {
|
||||
currentNode.addEndIndex(closeIndex + 1);
|
||||
}
|
||||
textData = "";
|
||||
i = closeIndex;
|
||||
} else if (c1 === 63) { //'?'
|
||||
@@ -5058,6 +5096,11 @@ const parseXml = function (xmlData) {
|
||||
childNode[":@"] = attsMap
|
||||
}
|
||||
this.addChild(currentNode, childNode, this.readonlyMatcher, i);
|
||||
|
||||
if (options.captureMetaData) {
|
||||
// closeIndex points at '?' of the closing '?>'
|
||||
currentNode.addEndIndex(tagData.closeIndex + 2);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -5222,6 +5265,10 @@ const parseXml = function (xmlData) {
|
||||
this.isCurrentNodeStopNode = false; // Reset flag
|
||||
|
||||
this.addChild(currentNode, childNode, this.readonlyMatcher, startIndex);
|
||||
|
||||
if (options.captureMetaData) {
|
||||
currentNode.addEndIndex(i + 1);
|
||||
}
|
||||
} else {
|
||||
//selfClosing tag
|
||||
if (isSelfClosing) {
|
||||
@@ -5232,6 +5279,10 @@ const parseXml = function (xmlData) {
|
||||
childNode[":@"] = prefixedAttrs;
|
||||
}
|
||||
this.addChild(currentNode, childNode, this.readonlyMatcher, startIndex);
|
||||
|
||||
if (options.captureMetaData) {
|
||||
currentNode.addEndIndex(closeIndex + 1);
|
||||
}
|
||||
this.matcher.pop(); // Pop self-closing tag
|
||||
this.isCurrentNodeStopNode = false; // Reset flag
|
||||
}
|
||||
@@ -5241,6 +5292,10 @@ const parseXml = function (xmlData) {
|
||||
childNode[":@"] = prefixedAttrs;
|
||||
}
|
||||
this.addChild(currentNode, childNode, this.readonlyMatcher, startIndex);
|
||||
|
||||
if (options.captureMetaData) {
|
||||
currentNode.addEndIndex(result.closeIndex + 1);
|
||||
}
|
||||
this.matcher.pop(); // Pop unpaired tag
|
||||
this.isCurrentNodeStopNode = false; // Reset flag
|
||||
i = result.closeIndex;
|
||||
|
||||
7
dist/setup/index.js
vendored
7
dist/setup/index.js
vendored
@@ -36065,6 +36065,9 @@ function _unique(values) {
|
||||
/******/ __nccwpck_require__.m = __webpack_modules__;
|
||||
/******/
|
||||
/************************************************************************/
|
||||
/******/ /* webpack/runtime/asset-relocator-loader */
|
||||
/******/ if (typeof __nccwpck_require__ !== 'undefined') __nccwpck_require__.ab = decodeURIComponent(new URL('.', import.meta.url).pathname).slice(import.meta.url.match(/^file:\/\/\/\w:/) ? 1 : 0, -1) + "/";
|
||||
/******/
|
||||
/******/ /* webpack/runtime/compat get default export */
|
||||
/******/ (() => {
|
||||
/******/ // getDefaultExport function for compatibility with non-harmony modules
|
||||
@@ -36157,10 +36160,6 @@ function _unique(values) {
|
||||
/******/ };
|
||||
/******/ })();
|
||||
/******/
|
||||
/******/ /* webpack/runtime/compat */
|
||||
/******/
|
||||
/******/ if (typeof __nccwpck_require__ !== 'undefined') __nccwpck_require__.ab = new URL('.', import.meta.url).pathname.slice(import.meta.url.match(/^file:\/\/\/\w:/) ? 1 : 0, -1) + "/";
|
||||
/******/
|
||||
/******/ /* webpack/runtime/import chunk loading */
|
||||
/******/ (() => {
|
||||
/******/ // no baseURI
|
||||
|
||||
Reference in New Issue
Block a user