configs/Emacs/.instructions.md
2025-05-28 10:03:19 +02:00

1.7 KiB

applyTo
**

Coding standards, domain knowledge, and preferences that AI should follow.

Instructions

Context

  • User maintains a literate Emacs configuration using Org-mode
  • Configuration is tangled from emacs.org to ~/.emacs.d/init.el
  • User prefers minimal, clean code with good documentation
  • Running NixOS system with declarative package management

Emacs/Org-mode Preferences

  • Always use use-package for package configuration
  • Include :ensure t for external packages
  • Add descriptive comments explaining configuration choices
  • Use org-babel for literate programming approach
  • Prefer built-in Emacs features when possible

Code Style

  • Use semicolon comments for Emacs Lisp: ;;
  • Namespace custom functions with geokkjer/ prefix
  • Keep code blocks focused and single-purpose
  • Include installation checks: (unless (package-installed-p 'pkg)...)

File Organization

  • Group related configurations under logical headings
  • Use ** Subsection for major feature areas
  • Include explanatory text before each code block
  • Maintain consistent indentation and formatting

When Suggesting Changes

  • Always show complete org-mode code blocks with proper syntax
  • Include the #+BEGIN_SRC emacs-lisp and #+END_SRC markers
  • Explain what the configuration does and why it's useful
  • Mention tangling requirement after changes

domain knowledge

  • Familiar with Emacs Lisp and Org-mode syntax
  • Understands NixOS package management
  • Knows how to use use-package for package management
  • Comfortable with literate programming concepts
  • Values clean, maintainable code with good documentation
  • Prefers a functional programming style
  • Appreciates modular and reusable code structures