Skip to content

feat(refs): bare-worktree layout + signed-commit discipline#26

Merged
CybotTM merged 1 commit into
mainfrom
feat/worktree-convention-signed-commits
Apr 21, 2026
Merged

feat(refs): bare-worktree layout + signed-commit discipline#26
CybotTM merged 1 commit into
mainfrom
feat/worktree-convention-signed-commits

Conversation

@CybotTM

@CybotTM CybotTM commented Apr 21, 2026

Copy link
Copy Markdown
Member

Summary

Move two recurring netresearch team practices out of per-user CLAUDE.md files into the shared skill where they belong.

Bare-worktree project layout (advanced-git.md)

Netresearch clones every repo as /projects/<repo>/.bare + one subdirectory per branch. Codifies:

  • The directory convention (.bare/ + main/ + <feature-branch>/)
  • Why (IDE indexing drops dead on in-place branch switches, parallel feature work, clean-main discipline)
  • Full setup sequence for a new project (git clone --bare + remote.origin.fetch config + first worktree add)
  • Per-branch worktree lifecycle: add / list / remove / prune
  • Batch cleanup pattern for post-session teardown (for wt in …; do worktree remove + branch -D; done + fetch --prune origin)

Signed-commit + DCO-signoff discipline (commit-conventions.md)

Promote Sign commits (optional) from the Best Practices summary to a full required-practice section:

  • git commit -S --signoff always. Explicit -S surfaces signing failures instead of silently shipping unsigned commits.
  • --signoff required for DCO compliance (enabled on most netresearch repos).
  • Sign-off identity must match git config user.{name,email} — mismatched identities fail DCO with an unhelpful "signoff required" message.
  • Never --no-verify / --no-gpg-sign as a shortcut. Never git commit --amend after a pre-commit hook failure (the commit didn't happen; --amend rewrites the PREVIOUS commit).
  • Atomic commits: one logical change per commit, squash WIP before PR.
  • git push -u on first push of a new branch.

Test plan

Capture two recurring team practices that weren't codified in the
existing references:

## Bare-worktree project layout (advanced-git.md)

Netresearch clones every repo as '/projects/<repo>/.bare' + one
subdirectory per branch. Rationale (IDE indexing, parallel feature
work, clean main checkout), full setup command sequence, batch
cleanup pattern for post-session teardown. Based on CLAUDE.md
convention 'Git Worktree Convention'.

## Signed-commit + DCO-signoff discipline (commit-conventions.md)

Promote 'Sign commits (optional)' to a required-practice section:

- 'git commit -S --signoff' always — explicit -S surfaces
  signing failures instead of silently shipping unsigned commits
  when SSH agent isn't available in subprocess environments.
- --signoff required for DCO compliance on most netresearch repos.
- Signoff identity must match git config user.{name,email}; the
  DCO check fails with 'signoff required' (unhelpful) when they
  diverge.
- Never --no-verify / --no-gpg-sign as a shortcut around hook
  failures. Never 'git commit --amend' after a pre-commit hook
  failed — the commit didn't happen, so --amend rewrites the
  PREVIOUS commit.
- Atomic commits: one logical change per commit, squash WIP
  before PR.
- 'git push -u' on first push of a new branch.

Both sections are cross-referenced from the Best Practices Summary.

Signed-off-by: Sebastian Mendel <info@sebastianmendel.de>
Copilot AI review requested due to automatic review settings April 21, 2026 06:12
@gemini-code-assist

Copy link
Copy Markdown

Warning

You have reached your daily quota limit. Please wait up to 24 hours and I will start processing your requests again!

@CybotTM CybotTM merged commit 95ec86b into main Apr 21, 2026
@CybotTM CybotTM deleted the feat/worktree-convention-signed-commits branch April 21, 2026 06:12
@github-actions

Copy link
Copy Markdown
Contributor

Dependency Review

✅ No vulnerabilities or license issues or OpenSSF Scorecard issues found.

Scanned Files

None

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR updates the shared git-workflow skill references to codify two netresearch Git practices: a bare-repo + multi-worktree project layout and stricter signed-commit + DCO sign-off discipline.

Changes:

  • Expand commit guidance to require git commit -S --signoff, add DCO/signing rationale, and add sections on atomic commits and first-push upstream setup.
  • Add a “Bare-Worktree Project Layout” section describing a .bare/ + per-branch folder layout, setup steps, and cleanup workflows.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 5 comments.

File Description
skills/git-workflow/references/commit-conventions.md Promotes signing + signoff from optional to required and adds supporting workflow guidance.
skills/git-workflow/references/advanced-git.md Documents the bare repo + per-branch worktree directory convention and lifecycle commands.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread skills/git-workflow/references/advanced-git.md
Comment thread skills/git-workflow/references/commit-conventions.md
Comment thread skills/git-workflow/references/commit-conventions.md
Comment thread skills/git-workflow/references/advanced-git.md
Comment thread skills/git-workflow/references/advanced-git.md
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants