creating-pds-pull-requestslisted
Install: claude install-skill NASA-PDS/pds-agent-skills
# Creating PDS Pull Requests Skill
This skill creates GitHub pull requests in NASA-PDS repositories with intelligent defaults, automatic issue linking, and consistent formatting following PDS conventions.
## Prerequisites
- GitHub CLI (`gh`) must be installed and authenticated
- User must have write access to the target NASA-PDS repository
- Must be in a git repository with uncommitted changes or a branch ready to push
## Workflow
### 1. Detect Current Context
**Auto-detect Repository and Branch:**
```bash
# Get current repository
git remote get-url origin 2>/dev/null || git remote get-url upstream 2>/dev/null
# Get current branch
git branch --show-current
# Check if branch has commits ahead of base
git rev-list --count origin/main..HEAD 2>/dev/null || git rev-list --count upstream/main..HEAD 2>/dev/null
```
**Edge Cases:**
- **Forks**: If `origin` is a fork (personal namespace), use `upstream` for the base repository
- **Non-NASA-PDS repos**: If no NASA-PDS remote found, ask user for target repository
- **No commits**: If current branch has no commits ahead, ask user if they want to commit changes first
- **Uncommitted changes**: If there are uncommitted changes, offer to commit them before creating PR
- **Main/master branch**: Warn if user is on main/master and suggest creating a feature branch
**Determine Base Branch:**
```bash
# Check common base branch names
git branch -r | grep -E 'origin/(main|master|develop)' | head -1
```
Default to `main`, but ask user