1 files changed,
33 insertions(+),
0 deletions(-)
Author:
Oleksandr Smirnov
olexsmir@gmail.com
Committed at:
2026-02-05 22:16:36 +0200
Authored at:
2026-02-05 22:07:02 +0200
Change ID:
pwupxvqumkzmynqlnvkzmpxvwvrqxkkk
Parent:
f59c329
A
AGENTS.md
ยทยทยท 1 +# mugit 2 + 3 +This is a Go-based Git repository web interface. Use these guidelines when working on this codebase. 4 + 5 + 6 +## Project Structure 7 + 8 +``` 9 +internal/ 10 +โโโ cli/ # CLI command handling 11 +โโโ config/ # Configuration management (YAML) 12 +โโโ git/ # Git operations 13 +โ โโโ gitservice/ # git upload-pack and git receive-pack implementation 14 +โโโ handlers/ # Web interface and Git HTTP protocol handlers 15 +โโโ humanize/ # Time formatting utilities 16 +โโโ mirror/ # Repository mirroring worker 17 +โโโ ssh/ # SSH Git server 18 +โโโ web/ # All things web 19 +``` 20 + 21 +## Key Dependencies 22 + 23 +- `github.com/urfave/cli/v3` - CLI framework 24 +- `github.com/go-git/go-git/v5` - Pure Go Git library 25 +- `github.com/gliderlabs/ssh` - SSH server 26 +- `github.com/yuin/goldmark` - Markdown rendering 27 +- `github.com/cyphar/filepath-securejoin` - Secure path joining 28 +- `olexsmir.xyz/x/is` - Test assertions 29 + 30 +## Security 31 + 32 +- Always use `securejoin.SecureJoin()` when constructing filesystem paths from user input 33 +- Check `repo.IsPrivate()` before serving public repository content