mirror of
https://github.com/dawidd6/action-ansible-playbook.git
synced 2025-12-09 22:30:41 -07:00
node_modules: upgrade
This commit is contained in:
20
node_modules/yaml/dist/stringify/stringifyCollection.js
generated
vendored
20
node_modules/yaml/dist/stringify/stringifyCollection.js
generated
vendored
@@ -1,6 +1,5 @@
|
||||
'use strict';
|
||||
|
||||
var Collection = require('../nodes/Collection.js');
|
||||
var identity = require('../nodes/identity.js');
|
||||
var stringify = require('./stringify.js');
|
||||
var stringifyComment = require('./stringifyComment.js');
|
||||
@@ -61,7 +60,7 @@ function stringifyBlockCollection({ comment, items }, ctx, { blockItemPrefix, fl
|
||||
onChompKeep();
|
||||
return str;
|
||||
}
|
||||
function stringifyFlowCollection({ comment, items }, ctx, { flowChars, itemIndent, onComment }) {
|
||||
function stringifyFlowCollection({ items }, ctx, { flowChars, itemIndent }) {
|
||||
const { indent, indentStep, flowCollectionPadding: fcPadding, options: { commentString } } = ctx;
|
||||
itemIndent += indentStep;
|
||||
const itemCtx = Object.assign({}, ctx, {
|
||||
@@ -114,32 +113,25 @@ function stringifyFlowCollection({ comment, items }, ctx, { flowChars, itemInden
|
||||
lines.push(str);
|
||||
linesAtValue = lines.length;
|
||||
}
|
||||
let str;
|
||||
const { start, end } = flowChars;
|
||||
if (lines.length === 0) {
|
||||
str = start + end;
|
||||
return start + end;
|
||||
}
|
||||
else {
|
||||
if (!reqNewline) {
|
||||
const len = lines.reduce((sum, line) => sum + line.length + 2, 2);
|
||||
reqNewline = len > Collection.Collection.maxFlowStringSingleLineLength;
|
||||
reqNewline = ctx.options.lineWidth > 0 && len > ctx.options.lineWidth;
|
||||
}
|
||||
if (reqNewline) {
|
||||
str = start;
|
||||
let str = start;
|
||||
for (const line of lines)
|
||||
str += line ? `\n${indentStep}${indent}${line}` : '\n';
|
||||
str += `\n${indent}${end}`;
|
||||
return `${str}\n${indent}${end}`;
|
||||
}
|
||||
else {
|
||||
str = `${start}${fcPadding}${lines.join(' ')}${fcPadding}${end}`;
|
||||
return `${start}${fcPadding}${lines.join(' ')}${fcPadding}${end}`;
|
||||
}
|
||||
}
|
||||
if (comment) {
|
||||
str += stringifyComment.lineComment(str, indent, commentString(comment));
|
||||
if (onComment)
|
||||
onComment();
|
||||
}
|
||||
return str;
|
||||
}
|
||||
function addCommentBefore({ indent, options: { commentString } }, lines, comment, chompKeep) {
|
||||
if (comment && chompKeep)
|
||||
|
||||
Reference in New Issue
Block a user