| name | working-with-github-cli |
| description | Use this skill when working with GitHub using the gh CLI in this project. Invoke for creating/managing pull requests, issues, viewing CI checks, releases, browsing the repo, or interacting with the GitHub API. Covers this project's branching conventions, PR workflow against the develop branch, and CI pipeline. |
Working with GitHub CLI in This Project
This Project's GitHub Setup
- Repo:
statikbe/craft (private, SSH: git@github.com:statikbe/craft.git)
- Default branch:
develop (not main)
- PR target: Always
develop unless explicitly stated otherwise
- CI: Runs on push to
develop and on all PRs — ECS linting via reusable workflow from statikbe/.github
- Deploy: SFTP —
develop deploys to staging, master deploys to production
- Branch naming:
feature/description, KarelJanVanHaute/issue559, or issue-number prefixed like 582-description
Critical Rules
- PRs always target
develop, not main or master
- Check CI status before merging — the ECS linting job must pass
- Never force-push to
develop or master
Pull Requests
Create a PR
gh pr create --base develop --title "Description" --body "Details"
gh pr create --base develop --draft --title "WIP: Description"
gh pr create --web
View & Manage PRs
gh pr list
gh pr view
gh pr view 123
gh pr view 123 --comments
gh pr view 123 --web
gh pr diff 123
gh pr checks 123
Review PRs
gh pr checkout 123
gh pr review 123 --approve
gh pr review 123 --request-changes --body "Please fix X"
gh pr comment 123 --body "Looks good, one question about..."
Merge PRs
gh pr merge 123 --merge --delete-branch
gh pr merge 123 --squash --delete-branch
gh pr merge 123 --auto --squash
Issues
gh issue list
gh issue view 582
gh issue create --title "Bug: description" --body "Details"
gh issue create --title "Title" --label bug --label "priority 1"
gh issue close 582
gh issue list --assignee "@me"
CI / GitHub Actions
gh run list
gh run view <run-id>
gh run view <run-id> --verbose
gh run watch <run-id>
gh run view <run-id> --log-failed
gh run rerun <run-id>
gh workflow run ci.yml
This Project's CI Pipeline
The CI runs on every PR and push to develop. It uses a reusable workflow from statikbe/.github that runs:
- ECS (Easy Coding Standard) — PHP code style linting
Check CI before merging:
gh pr checks
Releases & Tags
gh release list
gh release create v1.0.0 --title "v1.0.0" --notes "Release notes"
gh release create v1.0.0 --target develop --generate-notes
Repository & Browse
gh repo view
gh browse
gh browse path/to/file.php
gh browse --issues
gh browse --pulls
GitHub API (Advanced)
For anything not covered by dedicated commands:
gh api repos/statikbe/craft/pulls/123/comments
gh api repos/statikbe/craft/pulls/123/reviews
gh api repos/statikbe/craft/labels
gh api repos/statikbe/craft/branches/develop/protection
gh api repos/statikbe/craft/pulls --jq '.[].title'
gh api graphql -f query='{ repository(owner:"statikbe", name:"craft") { pullRequests(last:5) { nodes { title number } } } }'
Common Workflows
See ./github-workflows-for-this-project.md for detailed workflow patterns specific to this project.