@zeldrisho/pi-coderabbit-skills 0.0.0 → 0.1.1

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/CHANGELOG.md CHANGED
@@ -7,11 +7,22 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
7
7
 
8
8
  ## [Unreleased]
9
9
 
10
+ ## [0.1.1] - 2026-09-28
11
+
12
+ ### Changed
13
+
14
+ - Removed redundant repository-instructions loading from the `autofix` workflow.
15
+
10
16
  ## [0.1.0] - 2026-09-28
11
17
 
12
18
  ### Added
13
19
 
14
20
  - CodeRabbit `autofix` and `code-review` skills adapted for explicit invocation in Pi.
15
21
 
16
- [Unreleased]: https://github.com/zeldrisho/pi-packages/compare/pi-coderabbit-skills-v0.1.0...HEAD
22
+ ### Changed
23
+
24
+ - Hardened autofix review-thread error handling and clarified manual invocation and authentication guidance for CodeRabbit reviews.
25
+
26
+ [Unreleased]: https://github.com/zeldrisho/pi-packages/compare/pi-coderabbit-skills-v0.1.1...HEAD
27
+ [0.1.1]: https://github.com/zeldrisho/pi-packages/compare/pi-coderabbit-skills-v0.1.0...pi-coderabbit-skills-v0.1.1
17
28
  [0.1.0]: https://github.com/zeldrisho/pi-packages/releases/tag/pi-coderabbit-skills-v0.1.0
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@zeldrisho/pi-coderabbit-skills",
3
- "version": "0.0.0",
3
+ "version": "0.1.1",
4
4
  "description": "CodeRabbit skills packaged for Pi",
5
5
  "keywords": [
6
6
  "code-review",
@@ -22,26 +22,16 @@
22
22
  },
23
23
  "files": [
24
24
  "skills",
25
- "CHANGELOG.md",
26
- "LICENSE"
25
+ "CHANGELOG.md"
27
26
  ],
28
27
  "type": "module",
29
28
  "publishConfig": {
30
29
  "access": "public"
31
30
  },
32
- "scripts": {
33
- "check": "vp check",
34
- "test": "vp test",
35
- "test:watch": "vp test --watch",
36
- "lint": "vp lint",
37
- "lint:fix": "vp lint --fix",
38
- "format": "vp fmt --write",
39
- "typecheck": "vp check --no-fmt --no-lint"
40
- },
41
31
  "devDependencies": {
42
- "typescript": "catalog:",
43
- "vite": "catalog:",
44
- "vite-plus": "catalog:"
32
+ "typescript": "^7.0.2",
33
+ "vite": "npm:@voidzero-dev/vite-plus-core@0.3.3",
34
+ "vite-plus": "0.3.3"
45
35
  },
46
36
  "engines": {
47
37
  "node": ">=24"
@@ -50,5 +40,14 @@
50
40
  "skills": [
51
41
  "./skills"
52
42
  ]
43
+ },
44
+ "scripts": {
45
+ "check": "vp check",
46
+ "test": "vp test",
47
+ "test:watch": "vp test --watch",
48
+ "lint": "vp lint",
49
+ "lint:fix": "vp lint --fix",
50
+ "format": "vp fmt --write",
51
+ "typecheck": "vp check --no-fmt --no-lint"
53
52
  }
54
- }
53
+ }
@@ -29,13 +29,6 @@ Reusable GitHub command primitives are also mirrored in [github.md](./github.md)
29
29
 
30
30
  ## Workflow
31
31
 
32
- ### Step 0: Load Repository Instructions (`AGENTS.md`)
33
-
34
- Before any autofix actions, search for `AGENTS.md` in the current repository and load applicable instructions.
35
-
36
- - If found, follow its build/lint/test/commit guidance throughout the run.
37
- - If not found, continue with default workflow.
38
-
39
32
  ### Step 1: Check Code Push Status
40
33
 
41
34
  Check: `git status` + check for unpushed commits
@@ -97,7 +90,7 @@ while :; do
97
90
  args+=(-F cursor="$cursor")
98
91
  fi
99
92
 
100
- response=$(gh api graphql "${args[@]}" -f query='query($owner:String!, $repo:String!, $pr:Int!, $cursor:String) {
93
+ if ! response=$(gh api graphql "${args[@]}" -f query='query($owner:String!, $repo:String!, $pr:Int!, $cursor:String) {
101
94
  repository(owner:$owner, name:$repo) {
102
95
  pullRequest(number:$pr) {
103
96
  title
@@ -124,7 +117,15 @@ while :; do
124
117
  }
125
118
  }
126
119
  }
127
- }')
120
+ }'); then
121
+ echo "GitHub GraphQL request failed" >&2
122
+ exit 1
123
+ fi
124
+
125
+ if ! jq -e '(.errors == null or (.errors | length == 0)) and (.data.repository.pullRequest.reviewThreads.nodes | type == "array")' <<<"$response" >/dev/null; then
126
+ echo "GitHub GraphQL response contained errors or no review-thread data" >&2
127
+ exit 1
128
+ fi
128
129
 
129
130
  all_threads=$(jq -c --argjson response "$response" '
130
131
  . + $response.data.repository.pullRequest.reviewThreads.nodes
@@ -277,7 +278,6 @@ Use one commit for all applied fixes in this run.
277
278
  If a consolidated commit was created:
278
279
 
279
280
  - Prompt user interactively to run validation before push (recommended, not required).
280
- - Remind the user of the `AGENTS.md` instructions already loaded in Step 0 (if present).
281
281
  - If user agrees, run the requested checks and report results.
282
282
 
283
283
  ### Step 9: Push Changes
@@ -50,7 +50,7 @@ while :; do
50
50
  args+=(-F cursor="$cursor")
51
51
  fi
52
52
 
53
- response=$(gh api graphql "${args[@]}" -f query='query($owner:String!, $repo:String!, $pr:Int!, $cursor:String) {
53
+ if ! response=$(gh api graphql "${args[@]}" -f query='query($owner:String!, $repo:String!, $pr:Int!, $cursor:String) {
54
54
  repository(owner:$owner, name:$repo) {
55
55
  pullRequest(number:$pr) {
56
56
  title
@@ -77,7 +77,15 @@ while :; do
77
77
  }
78
78
  }
79
79
  }
80
- }')
80
+ }'); then
81
+ echo "GitHub GraphQL request failed" >&2
82
+ exit 1
83
+ fi
84
+
85
+ if ! jq -e '(.errors == null or (.errors | length == 0)) and (.data.repository.pullRequest.reviewThreads.nodes | type == "array")' <<<"$response" >/dev/null; then
86
+ echo "GitHub GraphQL response contained errors or no review-thread data" >&2
87
+ exit 1
88
+ fi
81
89
 
82
90
  all_threads=$(jq -c --argjson response "$response" '
83
91
  . + $response.data.repository.pullRequest.reviewThreads.nodes
@@ -1,6 +1,6 @@
1
1
  ---
2
2
  name: code-review
3
- description: "Run CodeRabbit CLI reviews, retrieve saved local or GitHub PR fix prompts, and interpret CodeRabbit authentication and review output. Use for CodeRabbit review commands, committed/uncommitted or directory scopes, and CodeRabbit runbooks. Default code-review skill: also trigger for explicit code/PR/quality/security review requests or when a review is needed."
3
+ description: "Run CodeRabbit CLI reviews, retrieve saved local or GitHub PR fix prompts, and interpret CodeRabbit authentication and review output. Use for CodeRabbit review commands, committed/uncommitted or directory scopes, and CodeRabbit runbooks."
4
4
  disable-model-invocation: true
5
5
  ---
6
6
 
@@ -60,7 +60,7 @@ Use `--agent` for output optimized for AI agents:
60
60
  coderabbit review --agent
61
61
  ```
62
62
 
63
- Run the review directly; the CLI starts browser authentication when needed, including a local callback flow in agent mode. Honor explicit no-login restrictions. If the execution environment hides host credentials or cannot open the callback, use the supported host execution path or hand off `coderabbit auth login`; do not read credential files or request pasted tokens. A sandbox authentication failure alone does not prove the user is logged out on the host.
63
+ Before running the review, ensure that the CLI is authenticated. If authentication is missing, use the supported host execution path or hand off `coderabbit auth login --agent`; do not read credential files or request pasted tokens. A sandbox authentication failure alone does not prove the user is logged out on the host.
64
64
 
65
65
  If the user asks to review a specific directory, append `--dir <path>`. The directory must be inside an initialized Git working tree.
66
66