WEYL WEYL
← Back to Weyl Standard

Weyl Standard Nix

A specification for reproducible, composable infrastructure on Nix

Documentation for the Weyl Standard—a specification for reproducible, composable infrastructure built on Nix.

uncategorized

  • Weyl Standard

    A collection of coding standards, patterns, and conventions for building production systems, codifying principles for high-performance computing, infrastructure, and software engineering.

  • Weyl Standard Nix

    A specification for building reproducible, composable infrastructure on Nix with flakes, flake-parts, and consistent naming conventions.

  • Contributors

    Thanks to all contributors to Weyl Standard Nix and acknowledgments to the Nix community.

languages

  • Languages

    Weyl Standard provides coding guidelines for production systems across multiple languages, optimizing for disambiguation, testability, and maintainability.

  • Weyl Standard Python

    Production Python for GPU inference and ML orchestration, emphasizing type safety, structured logging, and disambiguation over brevity.

  • Weyl Standard C++

    C++ guidelines for extreme performance requirements, using modern C++23 features with emphasis on clarity and disambiguation in agent-heavy development.

  • Weyl Standard Haskell

    Production Haskell guidelines optimizing for disambiguation, focusing on pragmatic patterns for web servers, compilers, and systems programming.

  • Weyl Standard Rust

    Production Rust for memory safety without garbage collection: explicit error handling, type-driven development, and agent-friendly patterns.

  • Weyl Standard TypeScript

    Conventions, patterns, and requirements for TypeScript code within Weyl AI systems for web services and tooling.

  • Weyl Standard Bash

    Conventions, patterns, and requirements for Bash scripts within Weyl AI systems.

guides

  • Cross-Compilation

    Building for aarch64 targets from x86_64 workstations.

  • Installation

    Prerequisites and setup for Weyl Standard Nix projects.

  • Documentation

    Use ndg for modules, nixdoc-style comments for functions, and helpful error messages with clear explanations and examples.

  • Overlays

    Advanced overlay composition patterns.

  • Your First Flake

    Create your first conformant flake with Weyl Standard.

  • File Placement

    Nix is infrastructure, not the main attraction. All Nix code lives under nix/ with clear organization for modules, packages, overlays, and configurations.

  • Standard Environments

    The weyl-stdenv family provides opinionated build environments for serious systems work.

  • Consuming Weyl Standard

    How to use weyl-std in your projects.

  • Forbidden Patterns

    These patterns are explicitly prohibited in Weyl Standard Nix to avoid common pitfalls and maintain code quality.

  • weyl-pkgs — The Debuggable Universe

    Every package. Every library. Every time. RelWithDebInfo for the entire dependency closure.

  • Infrastructure

    Configure your environment to use shared infrastructure for faster builds.

  • Module Systems

    Nix has multiple module systems that share syntax but differ in semantics - flake-parts, NixOS, nix-darwin, and home-manager.

  • Naming Conventions

    Standard nixpkgs idioms are fine, everything else gets spelled out. Optimize for grep and maintainability.

  • Testing

    Every flake output must be built or checked by nix flake check. Untested code is broken code.

  • Writing Modules

    Modules should be self-contained with options and config together, using mkIf and mkMerge for lazy evaluation.

  • Writing Packages

    Packages should be callPackage-able functions using finalAttrs pattern for proper override support.

  • Guides

    Practical guides for working with Weyl Standard Nix, covering getting started, patterns, and advanced topics.

  • Advanced

    Advanced topics for experienced Nix users.

  • Getting Started

    Start here to set up your first Weyl Standard Nix project.

  • Patterns

    Coding patterns for Weyl Standard Nix.

philosophy

reference

  • Library

    weyl-std library functions, available via weyl-std.lib.

  • Options

    Module configuration options for weyl-std.

  • Reference

    API reference and option documentation.

rfc

  • RFC-001: Weyl Standard Nix

    This RFC establishes Weyl Standard Nix, a specification for writing Nix code within the weyl-ai organization.

  • RFC-002: wsn-lint

    This RFC specifies wsn-lint, a static analysis tool that mechanically enforces Weyl Standard Nix.

  • RFCs

    Request for Comments — the normative specifications for Weyl Standard Nix.