You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: .github/copilot-instructions.md
+31-27Lines changed: 31 additions & 27 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -11,6 +11,37 @@ This is a **VS Code extension** that serves as an **abstraction layer** over the
11
11
-**Service Layer**: Abstraction over CLI for Microsoft 365 commands
12
12
-**Authentication**: Microsoft 365 authentication via `AuthProvider`
13
13
14
+
## Key Considerations
15
+
16
+
### Contribution & Branching Rules
17
+
- Always read and follow contributing.md before starting work; use it as the primary source for workflow, coding standards, testing, and PR requirements.
18
+
- Start new work from the dev branch:
19
+
- Create feature/fix branches off dev.
20
+
- Open Pull Requests that target dev. Do not open PRs targeting main.
21
+
- PRs must include: summary, linked issue (if any), testing steps, and listed reviewers.
22
+
- Use descriptive commit messages and reference issue numbers when applicable.
23
+
- If uncertain about any change (dependency, behavior, or architecture), open an issue or ask a human reviewer instead of guessing.
24
+
25
+
### Extension Dependency Rules
26
+
- Do not introduce new npm packages to the repository without explicit human approval. Agents must not add dependencies to package.json.
27
+
- Do not update npm-shrinkwrap.json (or lockfiles) except when:
28
+
- A new dependency is intentionally added to package.json, AND
29
+
- A human reviewer has approved the addition in the PR. Mention dependency changes in the PR and request approver review.
30
+
- Do not modify npm-shrinkwrap.json or lockfiles locally to "fix" builds; report and request guidance.
31
+
32
+
### File Changes & Documentation
33
+
- Do not change existing file contents unless the change is required and documented in contributing.md, an open issue, or the PR description.
34
+
- When editing docs or config, preserve existing formatting and context; keep changes minimal and explain why in the PR.
35
+
36
+
### Testing & Validation
37
+
- Add or update unit tests when changing logic.
38
+
- Run `npm run test` or `npm run watch-tests` locally before opening a PR.
39
+
- Manual testing: verify refactored input prompts, error handling, and edge cases for user prompts.
40
+
41
+
### Security and privacy
42
+
- Never embed secrets, tokens, or credentials in code or docs.
43
+
- If work requires sensitive information, request a secure workflow from maintainers.
44
+
14
45
## Development Workflow
15
46
16
47
### Build System
@@ -30,15 +61,6 @@ npm run test # Run VS Code extension tests
30
61
-`npm: watch` - Background build task (default)
31
62
-`npm: watch-tests` - Background test watch task
32
63
33
-
### Contribution & Branching Rules
34
-
- Always read and follow contributing.md before starting work; use it as the primary source for workflow, coding standards, testing, and PR requirements.
35
-
- Start new work from the dev branch:
36
-
- Create feature/fix branches off dev.
37
-
- Open Pull Requests that target dev. Do not open PRs targeting main.
38
-
- PRs must include: summary, linked issue (if any), testing steps, and listed reviewers.
39
-
- Use descriptive commit messages and reference issue numbers when applicable.
40
-
- If uncertain about any change (dependency, behavior, or architecture), open an issue or ask a human reviewer instead of guessing.
41
-
42
64
## Project Structure Patterns
43
65
44
66
### Core Services (`src/services/`)
@@ -67,11 +89,6 @@ npm run test # Run VS Code extension tests
- Do not introduce new npm packages to the repository without explicit human approval. Agents must not add dependencies to package.json.
71
-
- Do not update npm-shrinkwrap.json (or lockfiles) except when:
72
-
- A new dependency is intentionally added to package.json, AND
73
-
- A human reviewer has approved the addition in the PR. Mention dependency changes in the PR and request approver review.
74
-
- Do not modify npm-shrinkwrap.json or lockfiles locally to "fix" builds; report and request guidance.
75
92
76
93
## Authentication & Microsoft 365 Integration
77
94
@@ -112,10 +129,6 @@ export class ServiceName {
112
129
- Centralized logging via `Logger` class in `src/services/dataType/Logger.ts`
113
130
- Terminal command execution wrapped in `TerminalCommandExecuter`
114
131
115
-
### File Changes & Documentation
116
-
- Do not change existing file contents unless the change is required and documented in contributing.md, an open issue, or the PR description.
117
-
- When editing docs or config, preserve existing formatting and context; keep changes minimal and explain why in the PR.
118
-
119
132
## SPFx-Specific Knowledge
120
133
121
134
### Project Detection
@@ -134,13 +147,4 @@ export class ServiceName {
134
147
- Provides filtering by author, SPFx version, component type
135
148
- Supports both web parts and extensions
136
149
137
-
## Testing & Validation
138
-
- Add or update unit tests when changing logic.
139
-
- Run `npm run test` or `npm run watch-tests` locally before opening a PR.
140
-
- Manual testing: verify refactored input prompts, error handling, and edge cases for user prompts.
141
-
142
-
## Security and privacy
143
-
- Never embed secrets, tokens, or credentials in code or docs.
144
-
- If work requires sensitive information, request a secure workflow from maintainers.
145
-
146
150
When working on this extension, prioritize understanding the service layer architecture and the dual nature of the extension (native VS Code UI + React webview). The chat participant and language model tools represent the AI-first approach to SPFx development assistance.
0 commit comments