GitHub Copilot
GitHub Copilot integrates with Friday Dev for familiar code completion workflows.
Overview
GitHub Copilot provides:
- Code completion - Inline suggestions
- Familiar interface - Works like normal Copilot
- VS Code integration - Native experience
- Training on GitHub - Understands common patterns
When to Use Copilot
Ideal For
- ✅ VS Code users
- ✅ Code completion
- ✅ Boilerplate generation
- ✅ Pattern matching
- ✅ Familiar workflows
Less Ideal For
- ⚠️ Complex autonomous tasks
- ⚠️ Multi-file refactoring
- ⚠️ Architecture decisions
Setup
Requirements
- GitHub Copilot subscription
- VS Code with Copilot extension
- Friday Dev extension
Configuration
{
"agents": {
"copilot": {
"enabled": true,
"autoComplete": true
}
}
}
Usage
Inline Completion
Type code and Copilot suggests:
// Type this:
function validateEmail(
// Copilot suggests:
function validateEmail(email: string): boolean {
const emailRegex = /^[^\s@]+@[^\s@]+\.[^\s@]+$/;
return emailRegex.test(email);
}
Comment-Driven
Write comments, get code:
// Create a function that sorts an array of objects by a key
function sortByKey<T>(arr: T[], key: keyof T): T[] {
return [...arr].sort((a, b) => {
if (a[key] < b[key]) return -1;
if (a[key] > b[key]) return 1;
return 0;
});
}
Copilot Chat
Use chat for explanations:
Q: What does this regex do?
A: This regex validates email addresses...
Integration with Friday Dev
Task Context
When working on a Friday Dev task:
- Task description provides context
- Copilot suggestions are more relevant
- Changes tracked in task
Workflow
Friday Dev Task
↓
Open in VS Code
↓
Copilot assists coding
↓
Changes sync to task
↓
Create PR
Best Practices
Write Good Comments
// Bad - too vague
// Handle user
// Good - specific
// Validate user input and return sanitized data
Use Descriptive Names
// Copilot understands intent better
function calculateShippingCost(weight: number, distance: number)
// vs
function calc(w: number, d: number)
Accept Selectively
- Tab to accept full suggestion
- Ctrl+→ to accept word by word
- Reject if suggestion is wrong
Comparison
| Feature | Copilot | Cursor | Friday Agent |
|---|---|---|---|
| Completion | ⭐⭐⭐⭐⭐ | ⭐⭐⭐⭐ | ⭐⭐ |
| Autonomy | ⭐⭐ | ⭐⭐⭐ | ⭐⭐⭐⭐⭐ |
| Multi-file | ⭐⭐ | ⭐⭐⭐⭐ | ⭐⭐⭐⭐⭐ |
| Cost | $$$/mo | $$$/mo | Per-use |
Pricing
- GitHub Copilot Individual: $10/month
- GitHub Copilot Business: $19/user/month
- See github.com/features/copilot
Troubleshooting
Suggestions Not Appearing
- Check Copilot subscription
- Verify VS Code extension
- Check file type is supported
- Restart VS Code
Poor Suggestions
- Add more context/comments
- Use descriptive names
- Check relevant files are open
- Try rephrasing the comment
Sync Issues
- Verify Friday Dev extension
- Check task is open
- Refresh connection
- Restart VS Code
Next Steps
- Cursor - Alternative IDE agent
- Friday Agent - Autonomous option
- AI Agents Overview - Compare all agents