PostSharp/Metalama engineering workflows. Use for git operations (commit, branch, PR, merge, release), TeamCity CI/CD, build diagnostics, and development utilities.
/plugin marketplace add postsharp/PostSharp.Engineering.AISkills/plugin install eng@postsharp-engineeringThis skill inherits all available tools. When active, it can use any tool Claude has access to.
Git workflow conventions and commands for PostSharp/Metalama repositories.
To make permanent changes, edit the source files under X:\src\PostSharp.Engineering.AISkills\plugins\, then run /eng:update-cache to update the local cache.
metalama (GitHub) / postsharp (legacy)release/YYYY.N (e.g., release/2025.1)develop/YYYY.N (e.g., develop/2026.0)PVT_kwDOC7gkgc4A030bPVTSSF_lADOC7gkgc4A030bzgqb1vQf75ad846), Planned (08afe404), In progress (47fc9ee4), In review (4cc61d42), Merged (9d4ab054), Done (98236657)Use the following commands or read their instructions on demand:
/eng:create-pr: create (prepare) a pull request/eng:fix-binlog-warnings: analyze warnings from binlog output of Build.ps1 build/eng:prepare-release: on demand, when user asks to prepare release, github release, release notes. typically done after deployment/eng:reflect: self-improvement after a difficult task. you should do it automatically after a problem has been solved and you did mistakes before/eng:tc-build: schedule a teamcity (TC, CI) build/eng:tc-check-build: check the status of the last TC build/eng:update-cache: update the local plugin cache from sourceEach major version has two long-lived branches:
release/YYYY.N - Updated only during deployment (GitHub default branch per version line)develop/YYYY.N - Continuous CI/CD development branchWorkflow:
topic/YYYY.N/XXX-description → develop/YYYY.N (PR)develop/YYYY.N → release/YYYY.N (after successful deployment)Pattern: topic/YYYY.N/XXXX-short-description
YYYY.N - Version/milestone (e.g., 2026.0)XXXX - Issue number (required). If no issue, use date: YY-MM-DDshort-description - Brief, hyphenated description-2For topic/YYYY.N/*, merge target is ALWAYS develop/YYYY.N. Never use the release branch directly.
(#XXXX)Examples:
Fix cache invalidation on timeout (#1234)Add retry logic for API calls (#5678)IMPORTANT RULE: Unless the user explicitly asks you to commit, you MUST:
This ensures the user maintains control over what gets committed to the repository.
Always use YYYY.N.B-suffix format (e.g., 2026.0.8-rc), never YYYY.N alone.
Suffix conventions:
-preview - Early preview releases-rc - Release candidatesNever assign anything to a closed milestone. Never reopen a closed milestone. Propose the user to create a new milestone with incremented version number.
PostSharp.Engineering is the build orchestration SDK. Each repo is a product made of multiple solutions.
eng/src/Program.csMetalama.Framework, Metalama.Patterns)eng/src, self-generated via Build.ps1 generate-scripts| Scope | Reference Type | Notes |
|---|---|---|
| Within solution | ProjectReference | Standard .NET references |
| Between solutions | PackageReference | Requires Build.ps1 build to update packages |
| Cross-repo | PackageReference | Uses TeamCity artifacts by default |
# Full build - creates unique package versions, slow (~10-30 min)
Build.ps1 build
# Kill locked processes after failed build
Build.ps1 tools kill
# List cross-repo dependencies
Build.ps1 dependencies list
# Use local repo instead of TeamCity artifacts
Build.ps1 dependencies set local <product>
# Revert to TeamCity artifacts
Build.ps1 dependencies reset --all
IMPORTANT: Build.ps1 build is slow. Always ask the user before running it. For single-solution changes, prefer dotnet build / dotnet test.
| Scenario | Command |
|---|---|
| Single solution changes | dotnet build / dotnet test |
| Cross-solution changes | Ask user to run Build.ps1 build |
| Kill locked processes | Build.ps1 tools kill |
PackageVersion to Directory.Packages.propsBuild.ps1 build runs cannot run in parallelBuild.ps1 build, MSBuild binlogs are under artifacts/logsBy default, cross-repo PackageReference dependencies resolve from TeamCity (last successful build). To use local changes:
# In consuming repo, point to local dependency
Build.ps1 dependencies set local Metalama.Premium
# Now PackageReference resolves from local repo's Build.ps1 build output
# Requires Build.ps1 build in the dependency repo first
# PR node ID
gh api graphql -f query='{ repository(owner: "metalama", name: "Metalama") { pullRequest(number: 1228) { id } } }' --jq '.data.repository.pullRequest.id'
# Issue node ID
gh api graphql -f query='{ repository(owner: "metalama", name: "Metalama") { issue(number: 1226) { id } } }' --jq '.data.repository.issue.id'
breaking label[InternalImplement] (including inherited) is NOT a breaking changeWhen starting work on a GitHub issue:
topic/YYYY.N/XXXX-short-descriptionYYYY.N.B-maturity)<issue-number>-TODO.md file (don't commit it)Build.ps1 build yourself - ask the user to run it (timeout too low, causes retries)Build.ps1 prepare - it deletes all built artifacts and requires a subsequent Build.ps1 buildpwsh (PowerShell 7), never use old cmd<see> tags for type/member references<seealso href="@..."/> tags<see> tags with <c> to fix XML doc errors - fix the reference or add using insteadUse the /reflect command after difficult tasks where you made many unsuccessful attempts. This captures learnings for future sessions:
Learnings are added to CLAUDE.md or to the current plug-in files for future Claude instances to benefit from.
When running Claude Code inside Docker containers (environment variable RUNNING_IN_DOCKER set ), certain operations require host-level access (git push, GitHub CLI, etc.). The MCP Approval Server provides a secure, human-in-the-loop workflow for these operations.
┌─────────────────────────────────────────┐
│ Docker Container │
│ ┌─────────────┐ │
│ │ Claude Code │──▶ MCP Client │
│ └─────────────┘ (execute_command) │
└──────────────────────┬──────────────────┘
│ HTTP/SSE
▼
┌─────────────────────────────────────────┐
│ Host: MCP Approval Server │
│ 1. Receive request │
│ 2. AI risk analysis (Claude CLI) │
│ 3. Auto-approve/reject or prompt user │
│ 4. Execute if approved │
│ 5. Return result │
└─────────────────────────────────────────┘
The MCP server starts automatically with DockerBuild.ps1 -Claude. To disable:
.\DockerBuild.ps1 -Claude -NoMcp
Inside the container, privileged commands are routed through the MCP server automatically via the host-approval MCP configuration.
Any powershell command is allowed.