Skip to content

Commit 25ef14d

Browse files
docs: update code review guide to use /install-gh-app (#529)
* docs: update code review guide to use /install-gh-app - Rewrote code-review.mdx to focus on GitHub App installation - Added customization section for workflow modifications - Updated install-github-app.mdx with generated workflow example - Added info box to github-actions.mdx pointing to simpler setup Co-authored-by: factory-droid[bot] <138933559+factory-droid[bot]@users.noreply.github.com> * docs: update code review screenshots Co-authored-by: factory-droid[bot] <138933559+factory-droid[bot]@users.noreply.github.com> --------- Co-authored-by: factory-droid[bot] <138933559+factory-droid[bot]@users.noreply.github.com>
1 parent bed6937 commit 25ef14d

File tree

5 files changed

+139
-374
lines changed

5 files changed

+139
-374
lines changed

docs/cli/features/install-github-app.mdx

Lines changed: 54 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -207,31 +207,71 @@ The Factory Droid GitHub App requires these permissions:
207207
</Accordion>
208208
</AccordionGroup>
209209

210-
## Example workflow
210+
## Example usage
211211

212212
```bash
213-
# Start droid in your repository
214213
cd my-project
215214
droid
216215

217-
# Run the installation command
218216
> /install-gh-app
217+
```
219218

220-
# Preflight checks pass automatically if gh is configured
221-
# Select: Use current repository (my-org/my-project)
222-
# Browser opens to install the GitHub App
223-
# Select both workflows: @Droid and Droid Review
224-
# PR is created with workflow files
225-
226-
# After the flow completes:
227-
# 1. Add FACTORY_API_KEY secret to repository
228-
# 2. Merge the PR
229-
# 3. Tag @droid in an issue to test!
219+
After completing the guided flow, Droid creates a PR with workflow files. Here's what the generated Droid Review workflow looks like:
220+
221+
<Accordion title="Generated Droid Review Workflow">
222+
```yaml
223+
name: Droid Code Review
224+
225+
on:
226+
pull_request:
227+
types: [opened, synchronize, reopened, ready_for_review]
228+
229+
concurrency:
230+
group: droid-review-${{ github.event.pull_request.number }}
231+
cancel-in-progress: true
232+
233+
permissions:
234+
pull-requests: write
235+
contents: read
236+
issues: write
237+
238+
jobs:
239+
code-review:
240+
runs-on: ubuntu-latest
241+
timeout-minutes: 15
242+
if: github.event.pull_request.draft == false
243+
244+
steps:
245+
- name: Checkout repository
246+
uses: actions/checkout@v4
247+
with:
248+
fetch-depth: 0
249+
ref: ${{ github.event.pull_request.head.sha }}
250+
251+
- name: Install Droid CLI
252+
run: |
253+
curl -fsSL https://app.factory.ai/cli | sh
254+
echo "$HOME/.local/bin" >> $GITHUB_PATH
255+
256+
- name: Configure git identity
257+
run: |
258+
git config user.name "Droid Agent"
259+
git config user.email "droidagent@factory.ai"
260+
261+
- name: Perform automated code review
262+
env:
263+
FACTORY_API_KEY: ${{ secrets.FACTORY_API_KEY }}
264+
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
265+
run: |
266+
droid exec --auto high --model claude-sonnet-4-5-20250929 -f prompt.txt
230267
```
268+
</Accordion>
269+
270+
To customize the workflow after installation, see the [Automated Code Review guide](/guides/droid-exec/code-review#customizing-the-workflow).
231271
232272
## See also
233273
234-
- [GitHub Actions setup guide](https://github.com/Factory-AI/droid-action/blob/main/docs/setup.md) - Manual setup instructions
274+
- [Automated Code Review](/guides/droid-exec/code-review) - Customizing the code review workflow
235275
- [Factory GitHub App](https://github.com/apps/factory-droid) - Direct link to install the app
236276
- [API keys](https://app.factory.ai/settings/api-keys) - Generate your Factory API key
237277
- [Code Review](/cli/features/code-review) - Local code review with `/review` command
-124 KB
Loading
42 KB
Loading

0 commit comments

Comments
 (0)