Markdown Converter
Agent skill for markdown-converter
This file provides guidance to AI Agents such as Claude Code or ChatGPT Codex when working with code in this repository.
Sign in to like and favorite skills
This file provides guidance to AI Agents such as Claude Code or ChatGPT Codex when working with code in this repository.
Use idiomatic Go as possible. Prefer simple code than complex.
Gemserve is a simple Gemini protocol server written in Go that serves static files over TLS-encrypted connections. The Gemini protocol is a lightweight, privacy-focused alternative to HTTP designed for serving text-based content.
# Build, test, and format everything make # Run tests only make test # Build binaries to ./dist/ (gemserve, gemget, gembench) make build # Format code with gofumpt and gci make fmt # Run golangci-lint make lint # Run linter with auto-fix make lintfix # Clean build artifacts make clean # Run the server (after building) ./dist/gemserve # Generate TLS certificates for development certs/generate.sh
Core Components
Key Patterns
filepath.IsLocal() and path cleaning to prevent directory traversallib/apperrors package distinguishing fatal from non-fatal errorsRequest Flow
Configuration
Server configured via CLI flags:
--listen: Server address (default: localhost:1965)--root-path: Directory to serve files from--dir-indexing: Enable directory browsing (default: false)--log-level: Logging verbosity (debug, info, warn, error; default: info)--response-timeout: Response timeout in seconds (default: 30)--tls-cert: TLS certificate file path (default: certs/server.crt)--tls-key: TLS key file path (default: certs/server.key)--max-response-size: Maximum response size in bytes (default: 5242880)Testing Strategy
Security Considerations