Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .copilot/skills/pre-push-test-gate/SKILL.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ The pre-push hook (`.github/hooks/pre-push`) enforces **5 gates** that mirror CI

| Gate | Name | What It Does | Blocks If |
|------|------|-------------|-----------|
| **0** | Branch protection | Checks current branch | Push is to `main` |
| **0** | Branch protection | Checks current branch | Push is to `main` or `dev` |
| **1** | Untracked source files | Scans for untracked `.razor`/`.cs` files | Untracked source files found (prompts y/N) |
| **2** | Release build | `dotnet build IssueTrackerApp.slnx --configuration Release` | Build fails (3 retries) |
| **3** | Unit/Arch/bUnit tests | Runs 6 test projects in Release mode | Any test project fails (3 retries) |
Expand Down
35 changes: 18 additions & 17 deletions .github/workflows/squad-promote.yml
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ jobs:
uses: gittools/actions/gitversion/execute@v4.5.0
with:
useConfigFile: true
configFilePath: GitVersion.yml

- name: Show current state
run: |
Expand Down Expand Up @@ -70,39 +71,39 @@ jobs:
run: |
VERSION="${{ steps.gitversion.outputs.semVer }}"

# Check if a promote PR already exists
EXISTING=$(gh pr list --base main --head dev --state open --json number --jq '.[0].number' || true)
if [ -n "$EXISTING" ]; then
echo "ℹ️ Promote PR #$EXISTING already exists — updating description"
gh pr edit "$EXISTING" \
--title "chore: promote dev → main (v${VERSION})" \
--body "## Release Promotion
# Build PR body in a temp file to avoid shell-escaping issues
BODY_FILE="$(mktemp)"
cat > "$BODY_FILE" <<EOF
## Release Promotion

Merging \`dev\` into \`main\` for release **v${VERSION}**.

### Commits included
$(git log origin/main..origin/dev --oneline | head -50)

---
_After merging, run **squad-milestone-release** to tag and publish the GitHub Release._"
_After merging, run **squad-milestone-release** to tag and publish the GitHub Release._
EOF

# Check if a promote PR already exists
EXISTING=$(gh pr list --base main --head dev --state open --json number --jq '.[0].number // empty' || true)
if [ -n "$EXISTING" ]; then
echo "ℹ️ Promote PR #$EXISTING already exists — updating description"
gh pr edit "$EXISTING" \
--title "chore: promote dev → main (v${VERSION})" \
--body-file "$BODY_FILE"
Comment thread
mpaulosky marked this conversation as resolved.
echo "✅ Updated existing PR #$EXISTING"
else
gh pr create \
--base main \
--head dev \
--title "chore: promote dev → main (v${VERSION})" \
--body "## Release Promotion

Merging \`dev\` into \`main\` for release **v${VERSION}**.

### Commits included
$(git log origin/main..origin/dev --oneline | head -50)

---
_After merging, run **squad-milestone-release** to tag and publish the GitHub Release._"
--body-file "$BODY_FILE"
echo "✅ Created promote PR dev → main"
fi

rm -f "$BODY_FILE"

- name: Dry run complete
if: ${{ inputs.dry_run == 'true' }}
run: |
Expand Down
22 changes: 11 additions & 11 deletions .squad/ceremonies.md
Original file line number Diff line number Diff line change
Expand Up @@ -204,7 +204,7 @@ Fix agent: please push corrections to `{branch}` and comment when ready for re-r
### Merge Conflict Resolution Ceremony

- **Trigger:** Ralph detects `mergeable: CONFLICTED` on an open PR
- **When:** as soon as conflict is detected (typically after `main` advances)
- **When:** as soon as conflict is detected (typically after `dev` advances)
- **Facilitator:** Aragorn (decides resolver and strategy)
- **Purpose:** Unblock PRs with merge conflicts without violating review integrity

Expand All @@ -227,10 +227,10 @@ Fix agent: please push corrections to `{branch}` and comment when ready for re-r
```bash
git checkout {branch}
git fetch origin
git merge origin/main
git merge origin/dev
# resolve conflicts
git add .
git commit -m "chore: resolve merge conflicts with main\n\nCo-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>"
git commit -m "chore: resolve merge conflicts with dev\n\nCo-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>"
Comment thread
mpaulosky marked this conversation as resolved.
git push
```

Expand Down Expand Up @@ -261,8 +261,8 @@ Fix agent: please push corrections to `{branch}` and comment when ready for re-r
#### **Step 1 — Sync and prune remote tracking refs**

```bash
git checkout main
git pull origin main
git checkout dev
git pull origin dev
git fetch --prune
```
Comment thread
mpaulosky marked this conversation as resolved.

Expand All @@ -273,7 +273,7 @@ git fetch --prune
Catches any `squad/*` branches not removed by `--delete-branch` at merge time:

```bash
git branch -r --merged origin/main \
git branch -r --merged origin/dev \
| grep 'origin/squad/' \
| sed 's|origin/||' \
| xargs -r -I{} git push origin --delete {}
Expand All @@ -282,7 +282,7 @@ git branch -r --merged origin/main \
#### **Step 3 — Delete merged local branches**

```bash
git branch --merged main \
git branch --merged dev \
| grep -E '^\s+squad/' \
| xargs -r git branch -d
```
Expand All @@ -307,7 +307,7 @@ Print surviving branches for visibility:

```bash
echo "--- Remaining local branches ---"
git branch -vv | grep -v "^\* main"
git branch -vv | grep -v "^\* dev"

echo "--- Remaining remote squad/ branches ---"
git branch -r | grep 'origin/squad/' || echo "(none)"
Expand All @@ -316,9 +316,9 @@ git branch -r | grep 'origin/squad/' || echo "(none)"
#### Full one-liner (for convenience)

```bash
git checkout main && git pull origin main && git fetch --prune && \
git branch -r --merged origin/main | grep 'origin/squad/' | sed 's|origin/||' | xargs -r -I{} git push origin --delete {} && \
git branch --merged main | grep -E '^\s+squad/' | xargs -r git branch -d && \
git checkout dev && git pull origin dev && git fetch --prune && \
git branch -r --merged origin/dev | grep 'origin/squad/' | sed 's|origin/||' | xargs -r -I{} git push origin --delete {} && \
git branch --merged dev | grep -E '^\s+squad/' | xargs -r git branch -d && \
git branch -vv | grep ': gone]' | grep 'squad/' | awk '{print $1}' | xargs -r git branch -D && \
echo "✅ Orphan branch cleanup complete."
```
Expand Down
8 changes: 4 additions & 4 deletions .squad/playbooks/pr-merge-process.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

**Owner:** Aragorn (Lead) + Ralph (Work Monitor)
**Ref:** `.squad/ceremonies.md` (PR Review Gate, Standard Task Workflow)
**Last Updated:** 2025-07-17
**Last Updated:** 2026-04-13

---

Expand Down Expand Up @@ -155,16 +155,16 @@ Ralph triggers the Post-Merge Orphan Branch Cleanup ceremony:

```bash
# Sync local
git checkout main && git pull origin main && git fetch --prune
git checkout dev && git pull origin dev && git fetch --prune

# Remove merged remote squad/ branches
git branch -r --merged origin/main \
git branch -r --merged origin/dev \
| grep 'origin/squad/' \
| sed 's|origin/||' \
| xargs -r -I{} git push origin --delete {}

# Remove merged local squad/ branches
git branch --merged main \
git branch --merged dev \
| grep -E '^\s+squad/' \
| xargs -r git branch -d

Expand Down
4 changes: 2 additions & 2 deletions .squad/playbooks/pre-push-process.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

**Owner:** Boromir (DevOps) + Aragorn (Lead)
**Ref:** `.github/hooks/pre-push`, `CONTRIBUTING.md`
**Last Updated:** 2025-07-17
**Last Updated:** 2026-04-13

---

Expand Down Expand Up @@ -60,7 +60,7 @@ When you execute `git push`, the hook runs automatically:

| Gate | What | Blocks Push If |
| ----- | ---------------------- | ------------------------------------------------------------------------ |
| **0** | Branch protection | Current branch is `main` |
| **0** | Branch protection | Current branch is `main` or `dev` |
| **1** | Untracked source files | `.razor`/`.cs` files not staged (prompts y/N) |
| **2** | Release build | `dotnet build --configuration Release` fails (3 attempts) |
| **3** | Unit/Arch/bUnit tests | Any of 6 test projects fail (3 attempts) |
Expand Down
24 changes: 3 additions & 21 deletions .squad/playbooks/release-issuetracker.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Release Process — IssueTrackerApp Project Playbook

**Last Updated:** 2025-07-17
**Last Updated:** 2026-04-13
**Ref:** `GitVersion.yml`, `.github/workflows/squad-release.yml`, `.github/workflows/squad-promote.yml`
**Project:** IssueTrackerApp
**Owner:** Boromir (DevOps) + Aragorn (Release Approval)
Expand All @@ -27,29 +27,11 @@
| ------------------ | --------------------------------- | ------------------------------------------------------- |
| **Version System** | GitVersion | Configured in `GitVersion.yml` |
| **Version File** | `GitVersion.yml` | At repo root |
| **Tag Prefix** | `v` / `V` | e.g., `v1.0.0` (both cases accepted per GitVersion.yml) |
| **Tag Prefix** | `v` (lowercase only) | e.g., `v1.0.0` — GitVersion accepts `[vV]` but release workflow triggers only on `v*.*.*` |
| **Package ID** | IssueTrackerApp | From `.csproj` |
| **Merge Strategy** | squash (to dev), merge (dev→main) | Squash for feature work, merge commit for promotion |

**GitVersion.yml reference** (actual repo config):

```yaml
mode: ContinuousDeployment
tag-prefix: '[vV]?'
branches:
main:
regex: ^main$
tag: ''
increment: Minor
develop:
regex: ^dev$
tag: preview
increment: Minor
feature:
regex: ^(feature|squad)[/-]
tag: alpha.{BranchName}
increment: Inherit
```
**GitVersion.yml reference:** See [`GitVersion.yml`](../../GitVersion.yml) at repo root for the full, authoritative config. Key settings: `mode: ContinuousDelivery`, `tag-prefix: '[vV]'`, branches: `main` (Patch), `dev` (alpha, Minor), `feature/squad` (Inherit).

### Artifacts & Deployments

Expand Down
Loading