Skip to content

Commit

Permalink
Merge pull request #1565 from MeilCli/update/action
Browse files Browse the repository at this point in the history
update actions
  • Loading branch information
MeilCli authored Sep 25, 2023
2 parents a7c7374 + 280bc2f commit 0099937
Show file tree
Hide file tree
Showing 3 changed files with 25 additions and 17 deletions.
10 changes: 5 additions & 5 deletions dist/graphql.js
Original file line number Diff line number Diff line change
Expand Up @@ -2001,17 +2001,17 @@ var RepositoryRuleType;
RepositoryRuleType["Creation"] = "CREATION";
/** Only allow users with bypass permissions to delete matching refs. */
RepositoryRuleType["Deletion"] = "DELETION";
/** Prevent users with push access from force pushing to branches. */
/** Prevent users with push access from force pushing to refs. */
RepositoryRuleType["NonFastForward"] = "NON_FAST_FORWARD";
/** Require all commits be made to a non-target branch and submitted via a pull request before they can be merged. */
RepositoryRuleType["PullRequest"] = "PULL_REQUEST";
/** Choose which environments must be successfully deployed to before branches can be merged into a branch that matches this rule. */
/** Choose which environments must be successfully deployed to before refs can be merged into a branch that matches this rule. */
RepositoryRuleType["RequiredDeployments"] = "REQUIRED_DEPLOYMENTS";
/** Prevent merge commits from being pushed to matching branches. */
/** Prevent merge commits from being pushed to matching refs. */
RepositoryRuleType["RequiredLinearHistory"] = "REQUIRED_LINEAR_HISTORY";
/** Commits pushed to matching branches must have verified signatures. */
/** Commits pushed to matching refs must have verified signatures. */
RepositoryRuleType["RequiredSignatures"] = "REQUIRED_SIGNATURES";
/** Choose which status checks must pass before branches can be merged into a branch that matches this rule. When enabled, commits must first be pushed to another branch, then merged or pushed directly to a branch that matches this rule after status checks have passed. */
/** Choose which status checks must pass before branches can be merged into a branch that matches this rule. When enabled, commits must first be pushed to another branch, then merged or pushed directly to a ref that matches this rule after status checks have passed. */
RepositoryRuleType["RequiredStatusChecks"] = "REQUIRED_STATUS_CHECKS";
/** Tag name pattern */
RepositoryRuleType["TagNamePattern"] = "TAG_NAME_PATTERN";
Expand Down
14 changes: 11 additions & 3 deletions dist/vendor.js
Original file line number Diff line number Diff line change
Expand Up @@ -7209,6 +7209,7 @@ Builder.prototype.j2x = function(jObj, level) {
let attrStr = '';
let val = '';
for (let key in jObj) {
if(!jObj.hasOwnProperty(key)) continue;
if (typeof jObj[key] === 'undefined') {
// supress undefined node only if it is not an attribute
if (this.isAttribute(key)) {
Expand Down Expand Up @@ -7427,6 +7428,8 @@ function arrToStr(arr, options, jPath, indentation) {
for (let i = 0; i < arr.length; i++) {
const tagObj = arr[i];
const tagName = propName(tagObj);
if(tagName === undefined) continue;

let newJPath = "";
if (jPath.length === 0) newJPath = tagName
else newJPath = `${jPath}.${tagName}`;
Expand Down Expand Up @@ -7496,6 +7499,7 @@ function propName(obj) {
const keys = Object.keys(obj);
for (let i = 0; i < keys.length; i++) {
const key = keys[i];
if(!obj.hasOwnProperty(key)) continue;
if (key !== ":@") return key;
}
}
Expand All @@ -7504,6 +7508,7 @@ function attr_to_str(attrMap, options) {
let attrStr = "";
if (attrMap && !options.ignoreAttributes) {
for (let attr in attrMap) {
if(!attrMap.hasOwnProperty(attr)) continue;
let attrVal = options.attributeValueProcessor(attr, attrMap[attr]);
attrVal = replaceEntitiesValue(attrVal, options);
if (attrVal === true && options.suppressBooleanAttributes) {
Expand Down Expand Up @@ -8038,6 +8043,7 @@ const parseXml = function(xmlData) {
}else {//Opening tag
let result = readTagExp(xmlData,i, this.options.removeNSPrefix);
let tagName= result.tagName;
const rawTagName = result.rawTagName;
let tagExp = result.tagExp;
let attrExpPresent = result.attrExpPresent;
let closeIndex = result.closeIndex;
Expand All @@ -8063,7 +8069,7 @@ const parseXml = function(xmlData) {
if(tagName !== xmlObj.tagname){
jPath += jPath ? "." + tagName : tagName;
}
if (this.isItStopNode(this.options.stopNodes, jPath, tagName)) { //TODO: namespace
if (this.isItStopNode(this.options.stopNodes, jPath, tagName)) {
let tagContent = "";
//self-closing tag
if(tagExp.length > 0 && tagExp.lastIndexOf("/") === tagExp.length - 1){
Expand All @@ -8076,8 +8082,8 @@ const parseXml = function(xmlData) {
//normal tag
else{
//read until closing tag is found
const result = this.readStopNodeData(xmlData, tagName, closeIndex + 1);
if(!result) throw new Error(`Unexpected end of ${tagName}`);
const result = this.readStopNodeData(xmlData, rawTagName, closeIndex + 1);
if(!result) throw new Error(`Unexpected end of ${rawTagName}`);
i = result.i;
tagContent = result.tagContent;
}
Expand Down Expand Up @@ -8262,6 +8268,7 @@ function readTagExp(xmlData,i, removeNSPrefix, closingChar = ">"){
tagExp = tagExp.substr(separatorIndex + 1);
}

const rawTagName = tagName;
if(removeNSPrefix){
const colonIndex = tagName.indexOf(":");
if(colonIndex !== -1){
Expand All @@ -8275,6 +8282,7 @@ function readTagExp(xmlData,i, removeNSPrefix, closingChar = ">"){
tagExp: tagExp,
closeIndex: closeIndex,
attrExpPresent: attrExpPresent,
rawTagName: rawTagName,
}
}
/**
Expand Down
18 changes: 9 additions & 9 deletions graphql/graphql.ts
Original file line number Diff line number Diff line change
Expand Up @@ -21678,17 +21678,17 @@ export enum RepositoryRuleType {
Creation = 'CREATION',
/** Only allow users with bypass permissions to delete matching refs. */
Deletion = 'DELETION',
/** Prevent users with push access from force pushing to branches. */
/** Prevent users with push access from force pushing to refs. */
NonFastForward = 'NON_FAST_FORWARD',
/** Require all commits be made to a non-target branch and submitted via a pull request before they can be merged. */
PullRequest = 'PULL_REQUEST',
/** Choose which environments must be successfully deployed to before branches can be merged into a branch that matches this rule. */
/** Choose which environments must be successfully deployed to before refs can be merged into a branch that matches this rule. */
RequiredDeployments = 'REQUIRED_DEPLOYMENTS',
/** Prevent merge commits from being pushed to matching branches. */
/** Prevent merge commits from being pushed to matching refs. */
RequiredLinearHistory = 'REQUIRED_LINEAR_HISTORY',
/** Commits pushed to matching branches must have verified signatures. */
/** Commits pushed to matching refs must have verified signatures. */
RequiredSignatures = 'REQUIRED_SIGNATURES',
/** Choose which status checks must pass before branches can be merged into a branch that matches this rule. When enabled, commits must first be pushed to another branch, then merged or pushed directly to a branch that matches this rule after status checks have passed. */
/** Choose which status checks must pass before branches can be merged into a branch that matches this rule. When enabled, commits must first be pushed to another branch, then merged or pushed directly to a ref that matches this rule after status checks have passed. */
RequiredStatusChecks = 'REQUIRED_STATUS_CHECKS',
/** Tag name pattern */
TagNamePattern = 'TAG_NAME_PATTERN',
Expand Down Expand Up @@ -22128,14 +22128,14 @@ export type RequirableByPullRequestIsRequiredArgs = {
pullRequestNumber?: InputMaybe<Scalars['Int']['input']>;
};

/** Choose which environments must be successfully deployed to before branches can be merged into a branch that matches this rule. */
/** Choose which environments must be successfully deployed to before refs can be merged into a branch that matches this rule. */
export type RequiredDeploymentsParameters = {
__typename?: 'RequiredDeploymentsParameters';
/** The environments that must be successfully deployed to before branches can be merged. */
requiredDeploymentEnvironments: Array<Scalars['String']['output']>;
};

/** Choose which environments must be successfully deployed to before branches can be merged into a branch that matches this rule. */
/** Choose which environments must be successfully deployed to before refs can be merged into a branch that matches this rule. */
export type RequiredDeploymentsParametersInput = {
/** The environments that must be successfully deployed to before branches can be merged. */
requiredDeploymentEnvironments: Array<Scalars['String']['input']>;
Expand All @@ -22158,7 +22158,7 @@ export type RequiredStatusCheckInput = {
context: Scalars['String']['input'];
};

/** Choose which status checks must pass before branches can be merged into a branch that matches this rule. When enabled, commits must first be pushed to another branch, then merged or pushed directly to a branch that matches this rule after status checks have passed. */
/** Choose which status checks must pass before branches can be merged into a branch that matches this rule. When enabled, commits must first be pushed to another branch, then merged or pushed directly to a ref that matches this rule after status checks have passed. */
export type RequiredStatusChecksParameters = {
__typename?: 'RequiredStatusChecksParameters';
/** Status checks that are required. */
Expand All @@ -22167,7 +22167,7 @@ export type RequiredStatusChecksParameters = {
strictRequiredStatusChecksPolicy: Scalars['Boolean']['output'];
};

/** Choose which status checks must pass before branches can be merged into a branch that matches this rule. When enabled, commits must first be pushed to another branch, then merged or pushed directly to a branch that matches this rule after status checks have passed. */
/** Choose which status checks must pass before branches can be merged into a branch that matches this rule. When enabled, commits must first be pushed to another branch, then merged or pushed directly to a ref that matches this rule after status checks have passed. */
export type RequiredStatusChecksParametersInput = {
/** Status checks that are required. */
requiredStatusChecks: Array<StatusCheckConfigurationInput>;
Expand Down

0 comments on commit 0099937

Please sign in to comment.