Skip to content

Commit 69623b8

Browse files
committed
Move action.yml to repo root, remove local .github/actions/copilot, update workflows to use austenstone/copilot-cli-actions@main, and update README
1 parent 35dbe1f commit 69623b8

7 files changed

Lines changed: 5 additions & 5 deletions

File tree

.github/workflows/copilot-ci-fix.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ jobs:
88
runs-on: ubuntu-latest
99
if: ${{ github.event.workflow_run.conclusion == 'failure' }}
1010
steps:
11-
- uses: austenstone/copilot-cli-actions/.github/actions/copilot@main
11+
- uses: austenstone/copilot-cli-actions@main
1212
with:
1313
github-token: ${{ secrets.PAT }}
1414
prompt: |

.github/workflows/copilot-comment.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ jobs:
1111
modified_comment=$(echo "${{ github.event.comment.body }}" | sed 's/\/copilot//')
1212
echo "prompt=${modified_comment}" >> "$GITHUB_OUTPUT"
1313
- name: Run Copilot
14-
uses: austenstone/copilot-cli-actions/.github/actions/copilot@main
14+
uses: austenstone/copilot-cli-actions@main
1515
with:
1616
github-token: ${{ secrets.PAT }}
1717
prompt: |

.github/workflows/copilot-dependabot-update.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ jobs:
1818
github-token: ${{ secrets.GITHUB_TOKEN }}
1919

2020
- name: Generate dependency analysis with Copilot
21-
uses: austenstone/copilot-cli-actions/.github/actions/copilot@main
21+
uses: austenstone/copilot-cli-actions@main
2222
env:
2323
CONTEXT7_API_KEY: ${{ secrets.CONTEXT7_API_KEY }}
2424
with:

.github/workflows/copilot-triage.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ jobs:
4040
core.setOutput('available_labels', labelNames.join(','));
4141
core.info(`Found ${labelNames.length} labels: ${labelNames.join(', ')}`);
4242
return labelNames;
43-
- uses: austenstone/copilot-cli-actions/.github/actions/copilot@main
43+
- uses: austenstone/copilot-cli-actions@main
4444
if: steps.get_labels.outputs.available_labels != ''
4545
env:
4646
GITHUB_TOKEN: '' # Do NOT pass any auth tokens here since this runs on untrusted inputs

.github/workflows/test-copilot.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ jobs:
66
copilot:
77
runs-on: ubuntu-latest
88
steps:
9-
- uses: austenstone/copilot-cli-actions/.github/actions/copilot@main
9+
- uses: austenstone/copilot-cli-actions@main
1010
with:
1111
github-token: ${{ secrets.PAT2 }}
1212
mcp-config: |

README.md

-240 Bytes

Basic Setup

Add the following workflow to your .github/workflows folder:

name: 'Copilot Automation'
on:
  pull_request:

jobs:
  copilot-task:
    runs-on: ubuntu-latest
    steps:
      - name: 'Checkout Repository'
        uses: actions/checkout@v4
      - name: 'Run Copilot CLI'
        uses: austenstone/copilot-cli-actions@main
        uses: austenstone/copilot-cli-actions/.github/actions/copilot@main
        with:
          github-token: ${{ secrets.GITHUB_TOKEN }}
          prompt: 'Analyze this pull request and provide feedback on code quality'

Advanced Setup with MCP Servers

name: 'Advanced Copilot Automation'
on: [issues, pull_request]

jobs:
  copilot-advanced:
    runs-on: ubuntu-latest
    steps:
      - name: 'Checkout Repository'
        uses: actions/checkout@v4
      - name: 'Run Copilot with Custom Config'
        uses: austenstone/copilot-cli-actions@main
        uses: austenstone/copilot-cli-actions/.github/actions/copilot@main
        with:
          github-token: ${{ secrets.COPILOT_TOKEN }}
          prompt: |
            Review this pull request for:
            1. Code quality and best practices
            2. Security vulnerabilities
            3. Performance implications
            4. Documentation completeness
          model: 'claude-sonnet-4.5'
          allow-all-tools: true
          mcp-config: |
            {
              "mcpServers": {
                "time": {
                  "command": "uvx",
                  "args": [
                    "mcp-server-time",
                    "--local-timezone",
                    "America/New_York"
                  ],
                  "tools": ["*"]
                }
              }
            }

Configuration

Input Parameters

MCP Server Configuration

The action supports Model Context Protocol (MCP) servers for extending Copilot's capabilities:

Code Review Automation

name: 'AI Code Review'
on:
  pull_request:
    types: [opened, synchronize]

jobs:
  ai-review:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v4
      - uses: austenstone/copilot-cli-actions@main
      - uses: austenstone/copilot-cli-actions/.github/actions/copilot@main
        with:
          github-token: ${{ secrets.GITHUB_TOKEN }}
          prompt: |
            Please review this pull request and:
            1. Check for potential bugs or security issues
            2. Suggest improvements for code quality
            3. Verify that tests cover the new functionality
            4. Comment on the PR with your findings
          model: 'claude-sonnet-4.5'

Issue Triage and Labeling

name: 'AI Issue Triage'
on:
  issues:
    types: [opened]

jobs:
  triage:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v4
      - uses: austenstone/copilot-cli-actions@main
      - uses: austenstone/copilot-cli-actions/.github/actions/copilot@main
        with:
          github-token: ${{ secrets.GITHUB_TOKEN }}
          prompt: |
            Analyze this new issue and:
            1. Categorize it (bug, feature, documentation, etc.)
            2. Estimate complexity/priority
            3. Add appropriate labels
            4. Suggest potential assignees based on the codebase

Documentation Generation

name: 'Generate Documentation'
on:
  push:
    branches: [main]
    paths: ['src/**/*.ts', 'src/**/*.js']

jobs:
  docs:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v4
      - uses: austenstone/copilot-cli-actions@main
      - uses: austenstone/copilot-cli-actions/.github/actions/copilot@main
        with:
          github-token: ${{ secrets.GITHUB_TOKEN }}
          prompt: |
            Update the README.md file to reflect any API changes in the recent commits.
            Focus on:
            1. New functions and classes
            2. Changed method signatures
            3. Updated usage examples
            4. Breaking changes

Troubleshooting

Common Issues

  1. Permission Denied Errors

    • Ensure your GitHub token has the required permissions
    • Check that the token hasn't expired
  2. Tool Access Denied

    • Review your denied-tools configuration
    • Consider setting allow-all-tools: false for better security
  3. MCP Server Connection Issues

    • Verify MCP server URLs are accessible
    • Check authentication headers and tokens
  4. Large Output Truncation

    • Use no-color: true to reduce output size
    • Consider breaking complex prompts into smaller tasks

0 commit comments

Comments
 (0)