azure-sdk-tools
Copilot instructions134 starsChanged 3 months agoMITView on GitHub
This repository contains tools and libraries used by the Azure SDK team's engineering system. Tools are written in multiple languages including C#, Python, JavaScript/TypeScript, PowerShell, and Go. Follow guidelines in /doc/development/powershell.md: DO: - Write scripts that can be run locally - Write unit tests using Pester - Handle exit codes from external programs - Use Set-StrictMode -Version 4 - Use [CmdletBinding()] at the top of scripts - Set $ErrorActionPreference = 'Stop' - Support the -WhatIf parameter for destructive operations -…
In this repository42 other files it gives its agents.
- packages/python-packages/apiview-copilot/AGENTS.mdAGENTS.md
- azsdk-common-apiview-feedback-resolutionSkill
- azsdk-common-generate-sdk-locallySkill
- azsdk-common-generate-sdk-pipelineSkill
- azsdk-common-pipeline-analysisSkill
- azsdk-common-pipeline-fixerSkill
- azsdk-common-prepare-release-planSkill
- azsdk-common-sdk-breaking-changeSkill
- azsdk-common-sdk-releaseSkill
- azure-typespec-assessmentSkill
- azure-typespec-authorSkill
- code-reviewSkill
- eval-authoring-skillSkill
- eval-authoring-toolSkill
- eval-authoring-workflowSkill
- markdown-token-optimizerSkill
- sdk-ai-bot-eval-datasetSkill
- sdk-ai-bot-run-evaluationSkill
- skill-authoringSkill
- add-endpointSkill
- audit-filtersSkill
- dev-setupSkill
- kb-searchSkill
- report-active-reviewsSkill
- report-apiview-metricsSkill
- report-architect-commentsSkill
- report-feedbackSkill
- report-memorySkill
- report-revisionsSkill
- run-evalsSkill
- run-metricsSkill
- update-guidelinesSkill
- apiview-feedback-resolutionSkill
- azure-typespec-authorSkill
- generate-sdk-locallySkill
- azsdk-common-live-and-recorded-testsSkill
- markdown-token-optimizerSkill
- pipeline-troubleshootingSkill
- azsdk-common-prepare-release-planSkill
- azsdk-common-sdk-releaseSkill
- skill-authoringSkill
- pr-review-helpSkill
The file
Show its rules and text
We split this copilot-instructions.md into the rules it gives an agent
37 rules. About 0 are common, 20 are distinctive, and 17 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈20
Distinctive · estimate
This author's own choices. Worth a look.
17
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 12
Follow existing patterns and conventions found in the codebase
- Very specific: line 27
Create a new folder under /tools/ with a descriptive name
- Distinctive: line 28
Add a comprehensive README.md explaining:
- Very specific: line 33
Add code owners to .github/CODEOWNERS:
- Distinctive: line 37
Update the index table in the root README.md
- Very specific: line 50
Follow guidelines in /doc/development/powershell.md:
- Distinctive: line 53
Write scripts that can be run locally
- Distinctive: line 54
Write unit tests using Pester
- Very specific: line 57
Use [CmdletBinding()] at the top of scripts
- Distinctive: line 60
Use full CmdLet names (avoid aliases in scripts)
- Very specific: line 62
Use explicit return statements
- Very specific: line 63
Import common modules from eng/common/scripts/common.ps1
- Distinctive: line 66
Write scripts inline in Azure Pipelines YAML (extract to script files)
- Very specific: line 67
Call functions with parentheses syntax like myFunc(1, 2, 3) - use myFunc 1 2 3
- Distinctive: line 68
Use global state where avoidable
- Distinctive: line 69
Use complex pipeline statements with side effects
- Very specific: line 72
Write Pester tests in a tests/ directory alongside scripts
- Very specific: line 73
Run tests with Invoke-Pester
- Very specific: line 78
Follow conventions in .editorconfig:
- Distinctive: line 79
Use 4 spaces for indentation in C# files
- Distinctive: line 81
Use language keywords over BCL types
- Distinctive: line 83
Use PascalCase for constant fields
- Distinctive: line 90
Follow standard Python conventions
- Very specific: line 91
Use packages under /packages/python-packages/
- Distinctive: line 95
Use 4 spaces for indentation in TypeScript files
- Very specific: line 101
Use dotnet build for building
- Very specific: line 102
Use dotnet test for running tests
- Very specific: line 107
Use Invoke-Pester for unit tests
- Very specific: line 112
Always update .github/CODEOWNERS when adding new tools
- Distinctive: line 117
Every tool must have a README.md with clear documentation
- Distinctive: line 118
Update the root README.md index when adding tools
- Distinctive: line 119
Follow the format shown in existing tool READMEs
- Very specific: line 123
Use pipeline templates from eng/pipelines/templates
- Very specific: line 124
Create ci.yml in tool directory for build/test/release
- Distinctive: line 125
Use internal builds for release steps with appropriate conditions
- Distinctive: line 132
Follow the Microsoft Open Source Code of Conduct
- Distinctive: line 133
Do not add third-party tools directly - use as dependencies
≈ “Common” is an estimate: at least 1 in 5 of the 1,644 Copilot instructions files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Copilot Instructions for Azure SDK Tools Repository
Overview
This repository contains tools and libraries used by the Azure SDK team's engineering system. Tools are written in multiple languages including C#, Python, JavaScript/TypeScript, PowerShell, and Go.
General Guidelines
- @azure Rule - Use Azure Best Practices: When generating code for Azure, running terminal commands for Azure, or performing operations related to Azure, invoke your
azure_development-get_best_practicestool if available. - Base all assumptions and conclusions on data from authoritative sources. Do research as needed to gather data. If you lack sufficient data for validation, stop and tell me what you don't know.
- Make minimal, surgical changes focused on the specific task at hand
- Follow existing patterns and conventions found in the codebase
- Each tool should be self-contained with its own README, tests, and CI configuration
Repository Structure
/tools/- Individual tools organized by name, each in its own directory/packages/- Shared packages (Java and Python)/eng/- Engineering system files including common scripts and pipeline templates/doc/- Documentation including development guidelines.github/- GitHub configuration, workflows, and custom agents
Tool Development
Creating a New Tool
- Create a new folder under
/tools/with a descriptive name - Add a comprehensive README.md explaining:
- Purpose of the tool
- Prerequisites
- How to build, test, and use locally and remotely
- Where the tool is used
- Add code owners to
.github/CODEOWNERS:/tools/<tool-name>/ @owner1 @owner2 - Update the index table in the root README.md
- Provide test cases covering important workflows
- For tools publishing to public repositories, provide a
ci.ymlusing templates fromeng/pipelines/templates
Naming Convention for Pipelines
- Public builds:
tools - <tool-name> - ci - Internal builds:
tools - <tool-name>
Language-Specific Guidelines
PowerShell
Follow guidelines in /doc/development/powershell.md:
DO:
- Write scripts that can be run locally
- Write unit tests using Pester
- Handle exit codes from external programs
- Use
Set-StrictMode -Version 4 - Use
[CmdletBinding()]at the top of scripts - Set
$ErrorActionPreference = 'Stop' - Support the
-WhatIfparameter for destructive operations - Use full CmdLet names (avoid aliases in scripts)
- Declare types for function parameters
- Use explicit
returnstatements - Import common modules from
eng/common/scripts/common.ps1
DON'T:
- Write scripts inline in Azure Pipelines YAML (extract to script files)
- Call functions with parentheses syntax like
myFunc(1, 2, 3)- usemyFunc 1 2 3 - Use global state where avoidable
- Use complex pipeline statements with side effects
Testing:
- Write Pester tests in a
tests/directory alongside scripts - Run tests with
Invoke-Pester - See examples in
eng/common/scripts/job-matrix/tests
C# / .NET
Follow conventions in .editorconfig:
- Use 4 spaces for indentation in C# files
- Sort
usingdirectives with system directives first - Use language keywords over BCL types
- Open braces on new lines (Allman style)
- Use PascalCase for constant fields
- Prefix private fields with underscore
- One class per file
- Organize code with explicit accessibility modifiers
Python
- Follow standard Python conventions
- Use packages under
/packages/python-packages/
JavaScript/TypeScript
- Use 4 spaces for indentation in TypeScript files
Building and Testing
.NET Projects
- Use
dotnet buildfor building - Use
dotnet testfor running tests - Common templates available in
eng/pipelines/templates/stages/archetype-sdk-tool-dotnet.yml
PowerShell Projects
- Use
Invoke-Pesterfor unit tests - Common templates available in
eng/common/pipelines/templates/stages/archetype-sdk-tool-pwsh.yml
Code Owners
- Always update
.github/CODEOWNERSwhen adding new tools - Format:
/tools/<tool-name>/ @owner1 @owner2
Documentation
- Every tool must have a README.md with clear documentation
- Update the root README.md index when adding tools
- Follow the format shown in existing tool READMEs
CI/CD
- Use pipeline templates from
eng/pipelines/templates - Create
ci.ymlin tool directory for build/test/release - Use internal builds for release steps with appropriate conditions
- See examples:
tools/pipeline-witness/ci.yml,tools/http-fault-injector/ci.yml
Contributing
- Follow guidelines in
CONTRIBUTING.md - Agree to Microsoft CLA
- Follow the Microsoft Open Source Code of Conduct
- Do not add third-party tools directly - use as dependencies
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

