@theholocron/holocron-plugin-github 5.0.0-alpha.521 → 5.0.0-alpha.522
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.mjs +6 -2
- package/package.json +8 -8
package/dist/index.mjs
CHANGED
|
@@ -2503,15 +2503,19 @@ async function readRepoInfo(client, repo) {
|
|
|
2503
2503
|
settings
|
|
2504
2504
|
};
|
|
2505
2505
|
}
|
|
2506
|
-
/** A ruleset reduced to what `setup` writes: its enforcement, rule types
|
|
2506
|
+
/** A ruleset reduced to what `setup` writes: its enforcement, rule types, required status checks and the app a check is pinned to. */
|
|
2507
2507
|
function toRulesetDetail(data) {
|
|
2508
2508
|
const rules = data.rules ?? [];
|
|
2509
2509
|
const checks = rules.find((r) => r.type === "required_status_checks")?.parameters?.required_status_checks;
|
|
2510
|
+
const entries = Array.isArray(checks) ? checks : [];
|
|
2511
|
+
const sources = {};
|
|
2512
|
+
for (const entry of entries) if (typeof entry.integration_id === "number") sources[String(entry.context)] = entry.integration_id;
|
|
2510
2513
|
return {
|
|
2511
2514
|
name: data.name,
|
|
2512
2515
|
enforcement: data.enforcement,
|
|
2513
2516
|
ruleTypes: rules.map((r) => r.type),
|
|
2514
|
-
requiredChecks:
|
|
2517
|
+
requiredChecks: entries.map((c) => String(c.context)),
|
|
2518
|
+
...Object.keys(sources).length > 0 ? { requiredCheckSources: sources } : {}
|
|
2515
2519
|
};
|
|
2516
2520
|
}
|
|
2517
2521
|
/** The value, or `undefined` when GitHub refuses the read (permission, plan, feature absent). Other errors still throw. */
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@theholocron/holocron-plugin-github",
|
|
3
|
-
"version": "5.0.0-alpha.
|
|
3
|
+
"version": "5.0.0-alpha.522",
|
|
4
4
|
"description": "Holocron plugin for GitHub. Implements source, ci, secrets, environments, and issues capabilities against the GitHub REST API.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"ci",
|
|
@@ -44,21 +44,21 @@
|
|
|
44
44
|
"tsx": "4.23.15",
|
|
45
45
|
"typescript": "^6.0.3",
|
|
46
46
|
"vitest": "^5.1.0",
|
|
47
|
-
"@theholocron/cli": "5.0.0-alpha.
|
|
48
|
-
"@theholocron/eslint-config": "^8.9.0-alpha.22",
|
|
47
|
+
"@theholocron/cli": "5.0.0-alpha.522",
|
|
49
48
|
"@theholocron/fs-utils": "^1.17.0-alpha.5",
|
|
50
|
-
"@theholocron/
|
|
51
|
-
"@theholocron/tsconfig": "^8.9.0-alpha.22",
|
|
52
|
-
"@theholocron/github-client": "^1.58.0-alpha.53",
|
|
49
|
+
"@theholocron/misc-utils": "^1.17.0-alpha.5",
|
|
53
50
|
"@theholocron/tsdown-config": "^8.9.0-alpha.22",
|
|
51
|
+
"@theholocron/tsconfig": "^8.9.0-alpha.22",
|
|
52
|
+
"@theholocron/eslint-config": "^8.9.0-alpha.22",
|
|
54
53
|
"@theholocron/vitest-config": "^8.9.0-alpha.22",
|
|
55
|
-
"@theholocron/
|
|
54
|
+
"@theholocron/github-client": "^1.58.0-alpha.53",
|
|
55
|
+
"@theholocron/http-client": "^1.58.0-alpha.53"
|
|
56
56
|
},
|
|
57
57
|
"peerDependencies": {
|
|
58
58
|
"@theholocron/fs-utils": "^1.16.0",
|
|
59
59
|
"@theholocron/github-client": "^1.58.0",
|
|
60
60
|
"@theholocron/misc-utils": "^1.16.0",
|
|
61
|
-
"@theholocron/cli": "5.0.0-alpha.
|
|
61
|
+
"@theholocron/cli": "5.0.0-alpha.522"
|
|
62
62
|
},
|
|
63
63
|
"engines": {
|
|
64
64
|
"node": ">=22"
|