Skip to content

Commit 816aa04

Browse files
author
Tulga Tsogtgerel
committed
style: fix code formatting issues
- Run prettier to fix formatting in assistant files - Fixes format-check CI failure
1 parent cba3c5c commit 816aa04

File tree

6 files changed

+27
-43
lines changed

6 files changed

+27
-43
lines changed

assistant/INTEGRATION_GUIDE.md

Lines changed: 11 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ A new GitHub Action has been created in the `augment-agent` repository that can
2525
### Key Features
2626

2727
- ✅ React to PR review comments
28-
- ✅ React to issue comments
28+
- ✅ React to issue comments
2929
- ✅ Support for all 8 GitHub reaction types (+1, -1, laugh, confused, heart, hooray, rocket, eyes)
3030
- ✅ Configurable reaction type with sensible default (eyes)
3131
- ✅ Full TypeScript implementation with type safety
@@ -73,17 +73,17 @@ Replace the existing `actions/github-script@v7` step (lines 31-53) with:
7373

7474
## Inputs
7575

76-
| Input | Description | Required | Default |
77-
|-------|-------------|----------|---------|
78-
| `github_token` | GitHub token for API access | Yes | - |
79-
| `comment_id` | The ID of the comment to react to | Yes | - |
80-
| `event_name` | The GitHub event name | Yes | - |
81-
| `reaction` | The reaction type to add | No | `eyes` |
76+
| Input | Description | Required | Default |
77+
| -------------- | --------------------------------- | -------- | ------- |
78+
| `github_token` | GitHub token for API access | Yes | - |
79+
| `comment_id` | The ID of the comment to react to | Yes | - |
80+
| `event_name` | The GitHub event name | Yes | - |
81+
| `reaction` | The reaction type to add | No | `eyes` |
8282

8383
## Outputs
8484

85-
| Output | Description |
86-
|--------|-------------|
85+
| Output | Description |
86+
| --------- | --------------------------------------------------------------- |
8787
| `success` | Whether the reaction was successfully added (`true` or `false`) |
8888

8989
## Supported Reactions
@@ -135,19 +135,18 @@ jobs:
135135
repository: ${{ github.repository }}
136136
token: ${{ secrets.GITHUB_TOKEN }}
137137
ref: ${{ github.event.pull_request.head.ref }}
138-
138+
139139
- name: React to original comment with eyes
140140
uses: augmentcode/augment-agent/comment-reaction@feature/comment-reaction-action
141141
with:
142142
github_token: ${{ secrets.GITHUB_TOKEN }}
143143
comment_id: ${{ github.event.comment.id }}
144144
event_name: ${{ github.event_name }}
145145
reaction: eyes
146-
146+
147147
# ... rest of your workflow steps
148148
```
149149

150150
## Support
151151

152152
For issues or questions, please refer to the README.md in the comment-reaction directory or create an issue in the augment-agent repository.
153-

assistant/README.md

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -93,14 +93,14 @@ jobs:
9393

9494
## Inputs
9595

96-
| Input | Description | Required | Default |
97-
|-------|-------------|----------|---------|
98-
| `github_token` | GitHub token for API access and git operations | Yes | - |
99-
| `comment_id` | The ID of the comment that triggered the workflow | Yes | - |
100-
| `event_name` | The GitHub event name (`pull_request_review_comment` or `issue_comment`) | Yes | - |
101-
| `augment_api_token` | Augment API token for authentication | Yes | - |
102-
| `augment_api_url` | Augment API URL endpoint | Yes | - |
103-
| `reaction` | The reaction type to add (optional) | No | `eyes` |
96+
| Input | Description | Required | Default |
97+
| ------------------- | ------------------------------------------------------------------------ | -------- | ------- |
98+
| `github_token` | GitHub token for API access and git operations | Yes | - |
99+
| `comment_id` | The ID of the comment that triggered the workflow | Yes | - |
100+
| `event_name` | The GitHub event name (`pull_request_review_comment` or `issue_comment`) | Yes | - |
101+
| `augment_api_token` | Augment API token for authentication | Yes | - |
102+
| `augment_api_url` | Augment API URL endpoint | Yes | - |
103+
| `reaction` | The reaction type to add (optional) | No | `eyes` |
104104

105105
## Supported Reactions
106106

@@ -115,8 +115,8 @@ jobs:
115115

116116
## Outputs
117117

118-
| Output | Description |
119-
|--------|-------------|
118+
| Output | Description |
119+
| --------- | --------------------------------------------------------------- |
120120
| `success` | Whether the reaction was successfully added (`true` or `false`) |
121121

122122
## Permissions
@@ -125,9 +125,9 @@ The action requires the following permissions:
125125

126126
```yaml
127127
permissions:
128-
contents: read # To read repository content
129-
pull-requests: write # To add reactions and comments to PRs
130-
issues: write # To add reactions and comments to issues
128+
contents: read # To read repository content
129+
pull-requests: write # To add reactions and comments to PRs
130+
issues: write # To add reactions and comments to issues
131131
```
132132

133133
## Setup
@@ -152,6 +152,7 @@ Create a test PR and comment with `@augment <your instruction>`. For example:
152152
```
153153

154154
The assistant will:
155+
155156
- React with 👀 to acknowledge
156157
- Gather PR context
157158
- Implement the requested changes
@@ -187,4 +188,3 @@ The assistant will:
187188
## License
188189

189190
MIT
190-

assistant/action.yml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -90,4 +90,3 @@ runs:
9090
GITHUB_REPOSITORY: ${{ github.repository }}
9191
AUGMENT_API_TOKEN: ${{ inputs.augment_api_token }}
9292
AUGMENT_API_URL: ${{ inputs.augment_api_url }}
93-

assistant/package.json

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,4 +22,3 @@
2222
"typescript": "^5.8.3"
2323
}
2424
}
25-

assistant/src/index.ts

Lines changed: 2 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,6 @@ import * as exec from '@actions/exec';
1010
import { Octokit } from '@octokit/rest';
1111
import { Auggie } from '@augmentcode/auggie-sdk';
1212

13-
14-
1513
/**
1614
* PR Context gathered from GitHub
1715
*/
@@ -59,16 +57,12 @@ function parseRepository(): { owner: string; repo: string } {
5957
const [owner, repo] = repository.split('/');
6058

6159
if (!owner || !repo) {
62-
throw new Error(
63-
`Invalid GITHUB_REPOSITORY format: ${repository}. Expected format: owner/repo`
64-
);
60+
throw new Error(`Invalid GITHUB_REPOSITORY format: ${repository}. Expected format: owner/repo`);
6561
}
6662

6763
return { owner, repo };
6864
}
6965

70-
71-
7266
/**
7367
* Get PR number from comment
7468
*/
@@ -204,11 +198,7 @@ async function gatherPRContext(
204198
*/
205199
async function configureGit(): Promise<void> {
206200
await exec.exec('git', ['config', 'user.name', 'github-actions[bot]']);
207-
await exec.exec('git', [
208-
'config',
209-
'user.email',
210-
'github-actions[bot]@users.noreply.github.com',
211-
]);
201+
await exec.exec('git', ['config', 'user.email', 'github-actions[bot]@users.noreply.github.com']);
212202
}
213203

214204
/**
@@ -245,7 +235,6 @@ async function commitAndPush(
245235

246236
core.info(`📝 Changes detected:\n${statusOutput}`);
247237

248-
249238
// Commit changes
250239
const commitMessage = `feat: implement changes requested in comment #${commentId}
251240
@@ -503,4 +492,3 @@ main().catch(error => {
503492
const errorMessage = error instanceof Error ? error.message : String(error);
504493
core.setFailed(`Unexpected error: ${errorMessage}`);
505494
});
506-

assistant/tsconfig.json

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,4 +22,3 @@
2222
"include": ["src/**/*"],
2323
"exclude": ["node_modules", "dist"]
2424
}
25-

0 commit comments

Comments
 (0)