Communitygithub.com

cdcoonce/Portfolio_Website

GitHub CLI (gh) integration for managing issues, pull requests, branches,

Qu'est-ce que Portfolio_Website ?

Portfolio_Website is a Claude Code agent skill that gitHub CLI (gh) integration for managing issues, pull requests, branches,.

Compatible avec✓Claude Code~Codex CLI~Cursor
npx skills add https://github.com/cdcoonce/Portfolio_Website/tree/HEAD/.claude/skills/github-cli

Demander à votre IA préférée

Ouvre une nouvelle conversation avec cette compétence d'agent déjà préchargée.

Documentation

---
name: github-cli
description: >
  GitHub CLI (gh) integration for managing issues, pull requests, branches,
  commits, and code reviews directly from the terminal. Use when Claude needs to
  create, list, view, or update GitHub issues; create draft branches and
  pull requests; make commits and push changes; review pull request diffs and
  changes; approve or merge PRs; manage GitHub Actions workflows; or work with
  GitHub repositories without switching to a browser. Requires gh CLI installed
  and authenticated.
---

GitHub CLI (gh) Skill

Use the gh CLI to interact with GitHub repositories, issues, pull requests, and GitHub Actions workflows from the terminal.

Prerequisites

Verify gh is installed and authenticated:

gh --version
gh auth status

If not authenticated, run gh auth login and follow prompts.

Core Workflows

Issue Management

# List issues
gh issue list                             # Open issues in current repo
gh issue list --state all                 # All issues including closed
gh issue list --assignee @me              # Issues assigned to you
gh issue list --label "bug"               # Filter by label

# Create issue
gh issue create -t "Title" -b "Description"
gh issue create -t "Title" --label "bug,priority:high" --milestone "milestone-1"
gh issue create                           # Interactive mode

# View/update issue
gh issue view 123                         # View issue details
gh issue view 123 --web                   # Open in browser
gh issue edit 123 --add-label "in-progress"
gh issue close 123
gh issue reopen 123

# Add comments
gh issue comment 123 -b "Working on this now"

Branch & Commit Workflow

# Create feature/fix branch
git checkout -b feature/my-feature
git checkout -b fix/issue-123
git checkout -b draft/wip-experiment

# Stage and commit changes
git add .
git commit -m "feat: add new feature"
git commit -m "fix: resolve issue #123"

# Push branch to remote
git push -u origin feature/my-feature

Pull Request Management

# Create PR (multiple methods)
gh pr create                              # Interactive mode
gh pr create --fill                       # Auto-fill from commits
gh pr create --draft                      # Create as draft
gh pr create --draft --fill               # Draft with auto-fill
gh pr create -t "Title" -b "Description" -B main
gh pr create --label "review-needed" --assignee @me

# List PRs
gh pr list                                # Open PRs
gh pr list --assignee @me                 # Your PRs
gh pr list --search "review-requested:@me"  # PRs requesting your review
gh pr list --draft                        # Draft PRs only

# View PR details
gh pr view 45                             # View PR in terminal
gh pr view 45 --web                       # Open in browser

Code Review Workflow

# Checkout PR locally for testing
gh pr checkout 45                         # Checkout PR branch locally

# Review changes
gh pr diff 45                             # View PR diff
gh pr diff                                # Diff for current branch's PR

# Add review comments
gh pr comment 45 -b "LGTM, minor suggestion on line 42"
gh pr comment -b "Please add tests"       # Comment on current branch's PR

# Submit a formal review
gh pr review 45 --approve
gh pr review 45 --request-changes -b "Please fix the error handling"
gh pr review 45 --comment -b "Looks good overall, a few suggestions"

# Merge
gh pr merge 45                            # Interactive merge
gh pr merge 45 --squash                   # Squash merge
gh pr merge 45 --rebase                   # Rebase merge
gh pr merge 45 --merge                    # Standard merge commit
gh pr merge 45 --auto                     # Auto-merge when checks pass

Update Existing PR

gh pr edit 45 --title "New title"
gh pr edit 45 --body "Updated description"
gh pr edit 45 --base develop
gh pr edit 45 --add-label "ready-for-review"
gh pr ready 45                            # Mark ready (remove draft)

GitHub Actions Workflow Management

# List workflow runs
gh run list                               # Recent workflow runs
gh run list --workflow=ci.yml             # Specific workflow
gh run list --status=failure              # Failed runs only

# View workflow run details
gh run view                               # Interactive run selector
gh run view 12345                         # Specific run
gh run view 12345 --web                   # Open in browser

# Trigger workflow
gh workflow run ci.yml                    # Run on default branch
gh workflow run ci.yml --ref feature/x    # Run on specific branch
gh workflow run ci.yml -f key=value       # With input parameters

# Re-run failed jobs
gh run rerun 12345                        # Re-run all jobs
gh run rerun 12345 --failed               # Re-run only failed jobs

# View job logs
gh run view 12345 --log                   # Full log output
gh run view 12345 --log-failed            # Only failed job logs

# Watch a run in progress
gh run watch                              # Watch current run
gh run watch 12345                        # Watch specific run

Common Flag Reference

FlagDescription
-R, --repo OWNER/REPOTarget different repository
-B, --baseBase branch for PR
-H, --headHead branch for PR
-t, --titleTitle for issue/PR
-b, --bodyBody/description for issue/PR
-l, --labelLabels (comma-separated)
-a, --assigneeAssignee username
-m, --milestoneMilestone name
--draftCreate as draft PR
--fillAuto-fill from commit messages
--webOpen in browser
-y, --yesSkip confirmation prompts

Environment Variables

export GH_TOKEN="ghp_xxxx"               # Personal access token
export GH_HOST="github.example.com"      # GitHub Enterprise instance
export GH_REPO="owner/repo"              # Default repository

Tips & Gotchas

Multi-line Descriptions with Markdown

When creating issues or PRs with long descriptions containing markdown (code blocks, backticks), avoid heredocs which can fail due to shell interpretation. Instead:

# Step 1: Write description to a temp file (outside bash)
# Step 2: Create from the temp file
gh issue create -t "Title" -b "$(cat temp_description.txt)"
# Step 3: Clean up
rm temp_description.txt

This avoids issues with:

  • Backticks in code blocks conflicting with command substitution
  • Special characters being interpreted by the shell
  • Heredoc delimiter conflicts

Sourcing Description from Existing Files

To create an issue or PR from a markdown plan file:

# Use body-file flag for clean file-based descriptions
gh issue create -t "Title" --body-file docs/plans/my-plan.md
gh pr create -t "Title" --body-file docs/plans/my-plan.md

Detailed Reference

For comprehensive command options and examples, see references/commands.md.

Individual skills in this repo

This repo contains 20 individual skills — each has its own dedicated page.

cdcoonce/Portfolio_Website

Git commit workflow with enforced conventional commit style. Use when Claude needs to stage and commit changes, craft commit messages, or the user asks to commit, make a commit, or save their work. Ensures consistent commit message format, proper scoping, and atomic commits across the project.

cdcoonce/Portfolio_Website

AI-powered code quality analysis for Python, Markdown, and Mermaid diagrams. Use this skill when: (1) reviewing code for quality issues, (2) checking Python files for PEP8 violations, unused code, missing type hints, docstring problems, complexity issues, or potential runtime errors, (3) validating Markdown documentation for broken links, heading structure, or formatting issues, (4) validating Mermaid diagram syntax, (5) the user asks for a "code review" or "quality check", (6) analyzing code snippets pasted in conversation, or (7) suggesting and applying fixes for code quality issues.

cdcoonce/Portfolio_Website

Deploy the portfolio chat agent Lambda function to AWS. Use when the user asks to deploy, redeploy, push to Lambda, update the chat agent, or after updating context files or lambda_function.py. Rebuilds the knowledge base, packages dependencies, and deploys to AWS Lambda.

cdcoonce/Portfolio_Website

Generate multiple radically different interface designs for a module using parallel sub-agents. Use when user wants to design an API, explore interface options, compare module shapes, or mentions "design it twice".

cdcoonce/Portfolio_Website

Orchestrate the full GitHub-issues-driven development lifecycle. 7-phase pipeline from brainstorm through PR with state tracking and cross-conversation resume. Use when user says "dev cycle", "development workflow", "full development pipeline", or invokes /dev-cycle.

cdcoonce/Portfolio_Website

Production Python coding standards with automatic version detection (3.10-3.13). Use when writing, reviewing, or refactoring Python to ensure adherence to modern type syntax, LBYL exception handling, pathlib operations, ABC-based interfaces, and production-tested patterns. Not Dagster-specific - applies to any Python project.

cdcoonce/Portfolio_Website

Set up Claude Code hooks to block dangerous git commands (push, reset --hard, clean, branch -D, etc.) before they execute. Use when user wants to prevent destructive git operations, add git safety hooks, or block git push/reset in Claude Code.

cdcoonce/Portfolio_Website

Interview the user relentlessly about a plan or design until reaching shared understanding, resolving each branch of the decision tree. Use when user wants to stress-test a plan, get grilled on their design, or mentions "grill me".

cdcoonce/Portfolio_Website

Explore a codebase to find opportunities for architectural improvement, focusing on making the codebase more testable by deepening shallow modules. Use when user wants to improve architecture, find refactoring opportunities, consolidate tightly-coupled modules, or make a codebase more AI-navigable.

cdcoonce/Portfolio_Website

CEO/founder-mode plan review. Rethink the problem, find the 10-star product, challenge premises, expand scope when it creates a better product. Three modes: SCOPE EXPANSION (dream big), HOLD SCOPE (maximum rigor), SCOPE REDUCTION (strip to essentials). Use when the user asks for a plan review, CEO review, mega review, or wants a plan challenged/stress-tested before implementation.

cdcoonce/Portfolio_Website

Break a PRD into independently-grabbable GitHub issues using tracer-bullet vertical slices. Use when user wants to convert a PRD to issues, create implementation tickets, or break down a PRD into work items.

cdcoonce/Portfolio_Website

Turn a PRD into a multi-phase implementation plan using tracer-bullet vertical slices, saved as a local Markdown file in docs/plans/. Use when user wants to break down a PRD, create an implementation plan, plan phases from a PRD, or mentions "tracer bullets".

cdcoonce/Portfolio_Website

Generate or update the `.claude/docs/project.md` file that gives Claude project-specific context. Use this skill when the user asks to create, update, regenerate, or refresh project context, or says things like "update project.md", "generate project context", "this repo needs a project.md", or "Claude doesn't know about this project". Also trigger when onboarding Claude to a new repository for the first time.

cdcoonce/Portfolio_Website

Generate comprehensive, high-quality README.md files for code repositories. Use this skill whenever the user asks to create, write, generate, update, or improve a README for any project or repository. Also trigger when the user says things like "document this project", "write docs for this repo", "this repo needs a README", "help me onboard developers to this codebase", or asks for project documentation in markdown. Even if the user just says "README" or "readme" in the context of a codebase, use this skill.

cdcoonce/Portfolio_Website

Create a detailed refactor plan with tiny commits via user interview, then file it as a GitHub issue. Use when user wants to plan a refactor, create a refactoring RFC, or break a refactor into safe incremental steps.

cdcoonce/Portfolio_Website

Set up pre-commit hooks for the current repo. Use when user wants to add pre-commit hooks, configure commit-time linting, formatting, type checking, or testing. Triggers on "pre-commit", "git hooks", "linting hooks", or /setup-pre-commit.

cdcoonce/Portfolio_Website

Test-driven development with red-green-refactor loop. Use when user wants to build features or fix bugs using TDD, mentions "red-green-refactor", wants integration tests, or asks for test-first development.

cdcoonce/Portfolio_Website

Triage a bug or issue by exploring the codebase to find root cause, then create a GitHub issue with a TDD-based fix plan. Use when user reports a bug, wants to file an issue, mentions "triage", or wants to investigate and plan a fix for a problem.

cdcoonce/Portfolio_Website

Rewrites the prose sections of wiki pages in-place. Reads source files to understand current context, then updates only the content inside <!-- claude:prose --> ... <!-- claude:prose:end --> markers. Never touches <!-- generated:start --> ... <!-- generated:end --> blocks. Supports targeting a single page with /update-wiki {PageName}.

cdcoonce/Portfolio_Website

Create a PRD through user interview, codebase exploration, and module design, then submit as a GitHub issue. Use when user wants to write a PRD, create a product requirements document, or plan a new feature.

Skills associés