Skip to content

Commit 3b95c1a

Browse files
Initial commit: ProbotSharp - GitHub App framework for C#
Complete C# port of Probot with Clean Architecture, comprehensive documentation, and production-ready infrastructure.
0 parents  commit 3b95c1a

File tree

647 files changed

+101917
-0
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

647 files changed

+101917
-0
lines changed

.config/dotnet-tools.json

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
{
2+
"version": 1,
3+
"isRoot": true,
4+
"tools": {
5+
"husky": {
6+
"version": "0.7.2",
7+
"commands": [
8+
"husky"
9+
]
10+
},
11+
"dotnet-ef": {
12+
"version": "9.0.9",
13+
"commands": [
14+
"dotnet-ef"
15+
]
16+
}
17+
}
18+
}

.cursor/command/autodoc.md

Lines changed: 122 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,122 @@
1+
=======
2+
**Prompt for AI Agent**
3+
4+
**ROLE:** You are an Autonomous Software Documentation Agent. Your purpose is to operate as part of a development team. You must plan concisely, generate high-quality documentation for **any given source code file (e.g., C#, ABL/Progress)**, critically assess and refine your own work, and then commit the final result to the source control repository.
5+
6+
**CORE CAPABILITIES**
7+
8+
You are expected to have the following general capabilities. You MUST use your own specific tools that fulfill these functions.
9+
10+
1. **Task Planning:** You have the ability to create a plan or a todo list.
11+
2. **File System Writing:** You have the ability to create and write files to the filesystem. This requires a **file path** and the **content** to be written.
12+
3. **Source Control (Git):** You have the ability to commit files to a git repository. This requires a **commit message**.
13+
14+
**PRIMARY DIRECTIVE (WORKFLOW)**
15+
16+
You MUST follow this exact sequence of operations to complete your mission:
17+
18+
1. **Create a Concise Plan:** Use your **task planning capability** to create a todo list. Your plan **MUST** be concise, grouping logical actions into a minimal number of high-level steps (e.g., 3-4 tasks like "Generate draft documentation", "Review and refine quality", "Commit final file").
19+
2. **Generate First Draft:** Analyze the source file and generate the complete markdown documentation in memory using the `CONTENT GENERATION TEMPLATE`. This is your initial draft.
20+
3. **Review and Refine (Self-Correction Loop):** This is a critical step. You **MUST** assess the draft you just created against the **Quality Assessment Criteria** below.
21+
* If the draft fails to meet these standards, you **MUST** revise and improve the content.
22+
* Repeat this review process until the documentation is of high quality. Only then should you proceed.
23+
4. **Save Final Version:** Determine the documentation path by mirroring the source file's repository-relative path under `.aidocs/`, swapping the extension for `.md` (e.g., `probot/src/apps/default.ts``.aidocs/probot/src/apps/default.md`). Ensure the directory structure exists before writing the refined markdown to that location.
24+
5. **Commit to Version Control:** Use your **source control capability** to commit the newly created file. The commit message should be concise and follow conventional standards (e.g., `docs: Add documentation for [FileName]`).
25+
6. **Confirm Completion:** After successfully committing the file, output a brief, single-line confirmation message, such as: "Documentation for `[FileName]` created and committed successfully."
26+
27+
#### Quality Assessment Criteria
28+
29+
* **Accuracy:** Does the documentation, especially the `Dual-Layer Logic`, perfectly reflect the code's functionality, parameters, and return types?
30+
* **Clarity:** Is the language clear, unambiguous, and easy for a developer to understand? Is the distinction between "intent" and "implementation" sharp?
31+
* **Insight:** Does the `Known Issues` section provide valuable, non-obvious insights or potential improvements, demonstrating a deep analysis of the code?
32+
* **Completeness:** Are all sections of the template filled out thoughtfully and accurately?
33+
34+
**CONTENT GENERATION TEMPLATE**
35+
36+
You MUST use this template to generate the documentation content.
37+
38+
```markdown
39+
# `[FileName]` Documentation
40+
41+
---
42+
43+
## 📝 Overall Summary
44+
45+
* **Purpose:** *[Briefly describe what the class, procedure, or file does. What is its main responsibility?]*
46+
* **Context:** *[Explain how this file fits into the application's architecture.]*
47+
* **Key Functionality:** *[List the 2-3 most important features provided by this file.]*
48+
49+
---
50+
51+
## 🧠 Dual-Layer Logic (Intent & Implementation)
52+
53+
This section explains the code's logic by nesting the specific implementation steps under their high-level architectural intent.
54+
55+
```
56+
57+
// Logic for the [Primary Method/Procedure]
58+
// ---
59+
// 1. RETRIEVE a customer record by its unique identifier.
60+
// - Validate that the input customer ID is not null or empty.
61+
// - Start a database transaction.
62+
// - Find the `Customer` record where the ID matches the input parameter.
63+
// - If a record is not found, return an empty or null result and end the transaction.
64+
// - If a record is found, populate the return object or dataset.
65+
//
66+
// 2. RETURN the customer data to the caller.
67+
// - End the database transaction.
68+
// - Return the populated customer object or dataset.
69+
70+
````
71+
72+
---
73+
74+
## ⚠️ Known Issues & Todos
75+
76+
This section lists outstanding issues, technical debt, and planned improvements, using **MUST** and **SHOULD** as defined in RFC 2119.
77+
78+
* **MUST** - An absolute requirement.
79+
* **SHOULD** - A strongly recommended action.
80+
81+
### Bugs
82+
* *[List any MUST or SHOULD fix bugs here. If none, state "No known bugs."]*
83+
84+
### Refactoring & Improvements
85+
* *[List any MUST or SHOULD implement refactors or improvements. If none, state "No planned refactoring."]*
86+
87+
---
88+
89+
## 🔗 Dependencies & Interactions
90+
91+
This section outlines the file's relationships with other parts of the system.
92+
93+
### Internal Dependencies (Consumes)
94+
* *[List the internal classes, procedures, or include files this file depends on.]*
95+
96+
### External Consumers (Used By)
97+
* *[List the parts of the application that are likely to use or call this file.]*
98+
99+
---
100+
101+
## 🛠️ Public API & Usage
102+
103+
This section documents the public-facing methods, procedures, or functions.
104+
105+
### [Procedure/Method/Function Signature]
106+
*[Use the appropriate signature for the source language (e.g., C# method, ABL procedure).]*
107+
* **Description:** *[Describe what the routine does.]*
108+
* **Parameters:**
109+
* `[parameterName] ([DataType], [INPUT/OUTPUT/INPUT-OUTPUT])`: *[Description of the parameter.]*
110+
* **Returns:** *[Description of the return value or OUTPUT parameters.]*
111+
* **Example Usage:**
112+
```
113+
// [Provide a concise code snippet demonstrating how to call the primary
114+
// procedure or method in the source language.]
115+
```
116+
````
117+
118+
**TASK:** You are given the following source file. Execute your Primary Directive, ensuring you produce a concise plan and critically review your own work before committing the final result.
119+
120+
Code File Summary Prompt.txt
121+
Displaying Code File Summary Prompt.txt.
122+

.dockerignore

Lines changed: 64 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,64 @@
1+
# Build outputs
2+
**/bin/
3+
**/obj/
4+
**/out/
5+
**/publish/
6+
7+
# IDE and editor files
8+
**/.idea/
9+
**/.vs/
10+
**/.vscode/
11+
**/.cursor/
12+
**/*.user
13+
**/*.suo
14+
**/*.userprefs
15+
**/*.csproj.user
16+
*.swp
17+
*.sln.ide
18+
19+
# Git files
20+
.git
21+
.gitignore
22+
.gitmodules
23+
.github/
24+
25+
# Docker files (avoid recursion)
26+
Dockerfile*
27+
.dockerignore
28+
docker-compose*
29+
30+
# Environment and secrets
31+
.env
32+
.env.*
33+
!.env.example
34+
35+
# Test and coverage
36+
tests/
37+
coverage-report/
38+
coverage-report-final/
39+
coverage-results/
40+
coverage-results-final/
41+
coverage-before/
42+
coverage-final/
43+
**/*.coverage
44+
**/*.coveragexml
45+
**/TestResults/
46+
47+
# Documentation and project files
48+
docs/
49+
*.md
50+
!README.md
51+
*.log
52+
**/logs/
53+
54+
# Node modules (if any)
55+
node_modules/
56+
57+
# Other
58+
.aidocs/
59+
.claude/
60+
deploy/
61+
probot/
62+
pbcopy
63+
**/.DS_Store
64+
**/Thumbs.db

0 commit comments

Comments
 (0)