Skip to content

Commit 3462548

Browse files
CopilotOmidID
andauthored
Add comprehensive GitHub Copilot instructions for awesome-avalonia repository (#219)
* Initial plan * Add comprehensive GitHub Copilot instructions for awesome-avalonia repository Co-authored-by: OmidID <[email protected]> --------- Co-authored-by: copilot-swe-agent[bot] <[email protected]> Co-authored-by: OmidID <[email protected]>
1 parent d89e62a commit 3462548

File tree

1 file changed

+151
-0
lines changed

1 file changed

+151
-0
lines changed

.github/copilot-instructions.md

Lines changed: 151 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,151 @@
1+
# Awesome Avalonia Curation Repository
2+
3+
Awesome Avalonia is a curated list of Avalonia UI libraries, tools, samples, and resources maintained in a single README.md file. This is a documentation-only repository with no build processes or code compilation.
4+
5+
Always reference these instructions first and fallback to search or bash commands only when you encounter unexpected information that does not match the info here.
6+
7+
## Working Effectively
8+
9+
### Repository Structure
10+
- `README.md` - The main awesome list containing all Avalonia resources organized by categories
11+
- `CONTRIBUTING.md` - Guidelines for contributors submitting new entries
12+
- `.github/workflows/link-check.yml` - Weekly automated link validation
13+
- `.gitignore` and `.gitattributes` - Standard Git configuration files
14+
15+
### Essential Commands
16+
- Install the markdown link checker: `cargo install mlc`
17+
- Check all links: `/home/runner/.cargo/bin/mlc . --throttle 100`
18+
- Check specific file: `/home/runner/.cargo/bin/mlc README.md --throttle 100`
19+
- View link checker help: `/home/runner/.cargo/bin/mlc --help`
20+
21+
### Link Validation - NEVER CANCEL
22+
- **CRITICAL**: Link checking takes 22-25 seconds. NEVER CANCEL. Set timeout to 60+ minutes.
23+
- The tool checks 299+ links across the repository
24+
- Expect 40-50 broken links due to site changes, redirects, or temporary outages
25+
- Exit code 1 is NORMAL when broken links are found - this is not a failure
26+
- Use `--throttle 100` to avoid being rate-limited by external sites
27+
- Both commands (`mlc .` and `mlc README.md`) produce identical results since only README.md contains links
28+
29+
### Timing Expectations
30+
- **Link checking**: 22-25 seconds for full repository check. NEVER CANCEL.
31+
- **Manual validation**: 2-3 minutes to verify new entries follow format guidelines
32+
- **Content editing**: Immediate - no build or compilation steps required
33+
34+
## Validation
35+
36+
### Pre-commit Validation Steps
37+
ALWAYS run these commands before committing changes:
38+
1. `cd /home/runner/work/awesome-avalonia/awesome-avalonia`
39+
2. `/home/runner/.cargo/bin/mlc README.md --throttle 100` (22-25 seconds - NEVER CANCEL)
40+
3. Manually verify any new entries follow the format: `- [Name](link) - Description.` (note period)
41+
4. Check that entries are properly categorized and alphabetically sorted within sections
42+
5. Verify descriptions are concise (under 100 characters) and end with a period
43+
44+
### Manual Content Validation
45+
When adding or editing entries:
46+
- Verify links are accessible and lead to the correct resource
47+
- Ensure descriptions are concise and accurate (under 100 characters)
48+
- Check that the resource is actually related to Avalonia UI
49+
- Confirm entries follow the established format exactly
50+
- Validate entries are placed in the correct category section
51+
52+
### GitHub Actions Workflow
53+
- The `.github/workflows/link-check.yml` runs weekly on Mondays at 9 AM UTC
54+
- Uses `becheran/[email protected]` to check all markdown links
55+
- Can be triggered manually via GitHub UI using workflow_dispatch
56+
- Failures are expected due to external site changes - review and update as needed
57+
58+
## Common Tasks
59+
60+
### Adding a New Entry
61+
1. Identify the correct category section in README.md
62+
2. Use the exact format: `- [Name](link) - Description.` (note the period at the end)
63+
3. Insert alphabetically within the category
64+
4. Validate the link works and description is accurate (under 100 characters)
65+
5. Run link checker: `/home/runner/.cargo/bin/mlc README.md --throttle 100` (22-25 seconds)
66+
6. Ensure description follows CONTRIBUTING.md guidelines: short, simple, and descriptive
67+
68+
### Fixing Broken Links
69+
1. Run full link check: `/home/runner/.cargo/bin/mlc . --throttle 100` (22-25 seconds - NEVER CANCEL)
70+
2. Review the "broken links" list in the output (expect 40-50 broken links normally)
71+
3. Research each broken link to find:
72+
- Updated URL if the resource moved
73+
- Alternative resource if the original is permanently gone
74+
- Remove entry if resource is no longer relevant
75+
4. Update README.md with corrections
76+
5. Re-run link checker to verify fixes: `/home/runner/.cargo/bin/mlc README.md --throttle 100`
77+
78+
### Updating Categories
79+
1. Edit README.md table of contents if adding new sections
80+
2. Ensure internal anchor links match section headers exactly (case-sensitive)
81+
3. Verify all TOC links work: `/home/runner/.cargo/bin/mlc README.md --throttle 100` (22-25 seconds)
82+
4. Follow the existing hierarchy: major sections, subsections, and sub-subsections
83+
84+
## Repository Reference
85+
86+
### Exact Entry Format Examples
87+
**Correct format:**
88+
```
89+
- [Avalonia](https://github.com/AvaloniaUI/Avalonia) - Avalonia source code.
90+
- [AvaloniaVS](https://github.com/AvaloniaUI/AvaloniaVS) - Visual Studio Extension for Avalonia.
91+
```
92+
93+
**Common mistakes to avoid:**
94+
- Missing period at end: `- [Name](link) - Description`
95+
- Wrong bullet format: `* [Name](link) - Description.`
96+
- Missing space after bullet: `-[Name](link) - Description.`
97+
- Inconsistent capitalization in descriptions
98+
99+
### Current Structure Output
100+
```
101+
ls -la /home/runner/work/awesome-avalonia/awesome-avalonia
102+
total 68
103+
drwxr-xr-x 4 runner docker 4096 Sep 9 15:07 .
104+
drwxr-xr-x 3 runner docker 4096 Sep 9 15:06 ..
105+
drwxr-xr-x 7 runner docker 4096 Sep 9 15:07 .git
106+
-rw-r--r-- 1 runner docker 378 Sep 9 15:07 .gitattributes
107+
drwxr-xr-x 3 runner docker 4096 Sep 9 15:07 .github
108+
-rw-r--r-- 1 runner docker 649 Sep 9 15:07 .gitignore
109+
-rw-r--r-- 1 runner docker 397 Sep 9 15:07 CONTRIBUTING.md
110+
-rw-r--r-- 1 runner docker 36899 Sep 9 15:07 README.md
111+
```
112+
113+
### Current Link Statistics
114+
- **Total links**: 299
115+
- **Working links**: ~246 (82%)
116+
- **Warnings**: ~9 (redirects)
117+
- **Broken links**: ~44 (15%)
118+
- **Check frequency**: Weekly via GitHub Actions
119+
120+
### Key Categories in README.md
121+
- General
122+
- Samples and Projects (Audio, Communication, Documents, Gaming, Graphics, Productivity, Software Development)
123+
- Tutorials
124+
- Libraries & Extensions (Generic, Localization, Themes, MVVM, Charts, Controls, Games, Web)
125+
- Videos
126+
- Articles
127+
- Community
128+
- Tooling
129+
130+
## Important Notes
131+
132+
- **NO BUILD PROCESS**: This repository has no compilation, testing, or build steps
133+
- **NO DEPENDENCIES**: No package.json, requirements.txt, or similar dependency files
134+
- **CONTENT FOCUS**: Primary work involves curating and organizing Avalonia-related resources
135+
- **LINK MAINTENANCE**: Regular validation and updating of external links is the main maintenance task
136+
- **COLLABORATIVE**: Follow CONTRIBUTING.md guidelines when adding community suggestions
137+
138+
## Troubleshooting
139+
140+
### Link Checker Issues
141+
- If mlc is not installed: `cargo install mlc`
142+
- If Rust/Cargo is not available: Install Rust toolchain first
143+
- If links fail due to rate limiting: Increase `--throttle` value (e.g., `--throttle 200`)
144+
- If checker hangs: Wait at least 60 seconds before considering alternatives
145+
146+
### Content Issues
147+
- Verify entry format matches existing entries exactly
148+
- Check that links use HTTPS when available
149+
- Ensure descriptions end with a period
150+
- Confirm alphabetical ordering within categories
151+
- Validate that new categories have corresponding TOC entries

0 commit comments

Comments
 (0)