No description
Find a file
Luc Perkins 6a7eefd8fd
Some checks failed
ci.yml / Update root flake input (push) Failing after 0s
Update root flake input
2026-06-11 17:52:23 -07:00
.github No longer build all templates in CI 2025-10-08 06:04:38 -05:00
bun Add formatter to all templates 2026-03-22 15:06:57 -03:00
c-cpp Remove conan 2026-06-11 17:43:45 -07:00
clojure Remove x86_64-darwin support 2026-03-22 15:27:13 -03:00
csharp Small fixes to csharp template 2026-04-28 12:32:17 -03:00
cue Remove x86_64-darwin support 2026-03-22 15:27:13 -03:00
deno Remove x86_64-darwin support 2026-03-22 15:27:13 -03:00
dhall Remove x86_64-darwin support 2026-03-22 15:27:13 -03:00
elixir Update Elixir/Erlang versions 2026-05-04 10:10:34 -05:00
elm Remove x86_64-darwin support 2026-03-22 15:27:13 -03:00
empty Remove x86_64-darwin support 2026-03-22 15:27:13 -03:00
gleam Remove x86_64-darwin support 2026-03-22 15:27:13 -03:00
go Bump go version to fix ci build 2026-06-05 20:12:56 +01:00
hashi Remove x86_64-darwin support 2026-03-22 15:27:13 -03:00
haskell Remove x86_64-darwin support 2026-03-22 15:27:13 -03:00
haxe Use plain haxe attribute 2026-06-05 13:15:52 -07:00
java Remove x86_64-darwin support 2026-03-22 15:27:13 -03:00
jupyter Bump Jupyter Python version to 3.13 to fix ci 2026-06-05 21:13:02 +01:00
kotlin Remove x86_64-darwin support 2026-03-22 15:27:13 -03:00
latex Remove x86_64-darwin support 2026-03-22 15:27:13 -03:00
lean4 Remove x86_64-darwin support 2026-03-22 15:27:13 -03:00
nickel Remove x86_64-darwin support 2026-03-22 15:27:13 -03:00
nim Remove x86_64-darwin support 2026-03-22 15:27:13 -03:00
nix fix deprecation warning for nixfmt-classic 2026-06-05 21:22:01 +01:00
node Remove node2nix and update pnpm reference 2026-04-14 21:19:33 +02:00
ocaml Remove x86_64-darwin support 2026-03-22 15:27:13 -03:00
odin Remove x86_64-darwin support 2026-03-22 15:27:13 -03:00
opa Remove x86_64-darwin support 2026-03-22 15:27:13 -03:00
php Remove x86_64-darwin support 2026-03-22 15:27:13 -03:00
platformio Remove x86_64-darwin support 2026-03-22 15:27:13 -03:00
powershell Add PowerShell template 2026-06-07 21:49:04 +01:00
presenterm add presenterm development flake 2026-05-30 00:14:06 +08:00
protobuf Remove x86_64-darwin support 2026-03-22 15:27:13 -03:00
pulumi Remove x86_64-darwin support 2026-03-22 15:27:13 -03:00
purescript Remove x86_64-darwin support 2026-03-22 15:27:13 -03:00
python Update Nixpkgs epochs 2026-05-04 10:16:24 -05:00
r Remove x86_64-darwin support 2026-03-22 15:27:13 -03:00
ruby Remove x86_64-darwin support 2026-03-22 15:27:13 -03:00
rust Remove x86_64-darwin support 2026-03-22 15:27:13 -03:00
scala Remove x86_64-darwin support 2026-03-22 15:27:13 -03:00
shell Remove x86_64-darwin support 2026-03-22 15:27:13 -03:00
swi-prolog Remove x86_64-darwin support 2026-03-22 15:27:13 -03:00
swift fix swift flake ci build 2026-06-05 21:29:04 +01:00
typst Remove x86_64-darwin support 2026-03-22 15:27:13 -03:00
vlang Remove x86_64-darwin support 2026-03-22 15:27:13 -03:00
zig Update Nixpkgs epochs 2026-05-04 10:16:24 -05:00
.editorconfig Add editorconfig file 2022-07-12 02:01:42 +02:00
.envrc Update clojure and csharp 2023-07-13 15:15:22 -07:00
.gitignore Remove all flake.lock files 2025-09-12 15:35:25 +02:00
flake.lock Update root flake input 2026-06-11 17:52:23 -07:00
flake.nix Fix root flake.nix 2026-06-07 18:32:45 -07:00
LICENSE Add license file 2025-09-29 13:01:12 +02:00
README.md Add PowerShell template 2026-06-07 21:49:04 +01:00

Nix flake templates for easy dev environments

built with nix

To initialize (where ${ENV} is listed in the table below):

nix flake init --template "https://flakehub.com/f/the-nix-way/dev-templates/*#${ENV}"

You can also use the shorter GitHub form:

nix flake init -t github:the-nix-way/dev-templates#${ENV}

Here's an example (for the rust template):

# Initialize in the current project
nix flake init --template "https://flakehub.com/f/the-nix-way/dev-templates/*#rust"

# or with the short GitHub form
nix flake init -t github:the-nix-way/dev-templates#rust

# Create a new project
nix flake new --template "https://flakehub.com/f/the-nix-way/dev-templates/*#rust" ${NEW_PROJECT_DIRECTORY}

How to use the templates

Once your preferred template has been initialized, you can use the provided shell in two ways:

  1. If you have nix-direnv installed, you can initialize the environment by running direnv allow.
  2. If you don't have nix-direnv installed, you can run nix develop to open up the Nix-defined shell.

Available templates

Language/framework/tool Template
Bun bun
C / C++ c-cpp
Clojure clojure
C# csharp
Cue cue
Deno deno
Dhall dhall
Elixir elixir
Elm elm
Empty (change at will) empty
Gleam gleam
Go go
Hashicorp tools hashi
Haskell haskell
Haxe haxe
Java java
Jupyter jupyter
Kotlin kotlin
LaTeX latex
Nickel nickel
Nim nim
Nix nix
Node.js node
OCaml ocaml
Odin odin
Open Policy Agent opa
PHP php
PlatformIO platformio
Presenterm presenterm
PowerShell powershell
Protobuf protobuf
Pulumi pulumi
Purescript purescript
Python python
R r
Ruby ruby
Rust rust
Scala scala
Shell shell
SWI-prolog swi-prolog
Swift swift
Typst typst
Vlang vlang
Zig zig

Template contents

The sections below list what each template includes. In all cases, you're free to add and remove packages as you see fit; the templates are just boilerplate.

bun

c-cpp

clojure

csharp

  • dotnet
  • [omnisharp-roslyn]
  • [Mono]
  • [msbuild]

cue

dhall

elixir

elm

Empty

A dev template that's fully customizable.

gleam

go

hashi

haskell

haxe

java

jupyter

kotlin

latex

lean4

nickel

nim

nix

node

ocaml

odin

opa

php

platformio

Presenterm

powershell

protobuf

pulumi

purescript

python

r

ruby

  • Ruby, plus the standard Ruby tools (bundle, gem, etc.)

rust

  • Rust, including cargo, Clippy, and the other standard tools. The Rust version is determined as follows, in order:
    • From the rust-toolchain.toml file if present
    • From the rust-toolchain file if present
    • Version 1.78.0 if neither is present
  • rust-analyzer
  • cargo-edit
  • cargo-deny

scala

shell

swi-prolog

swift

typst

vlang

zig