Templates I use for setting up language-specific development environments, based on Nix flakes.
To use these templates, run:
mkdir my-go-proj && cd my-go-proj
# For Golang
nix flake init -t github:chzerv/nix-flake-templates#go
go mod init github.com/<username>/my-go-proj
Tip
# Build the project
nix build
- Fenix for installing toolchains and rust-analyzer
- Crane for building the project
- Let's us build the project's dependencies in a separate step and thus, avoid rebuilding them whenever we build the project
- Treefmt for project-wide formatting
mkdir my-crate && cd my-crate
nix flake init -t github:chzerv/nix-flake-templates#typst
cargo init
cargo generate-lockfile
Tip
# Build the project (Cargo.toml and Cargo.lock must be already generated!)
nix build
# Clippy and cargo-audit
nix flake check
# Project-wide formatting
nix fmt
Simple template that just installs Gleam
, Erlang
and rebar3
, according to the Gleam docs
mkdir my-gleam-proj && cd my-gleam-proj
nix flake init -t github:chzerv/nix-flake-templates#gleam
gleam new .
mkdir my-tf-proj && cd my-tf-proj
nix flake init -t github:chzerv/nix-flake-templates#terraform
mkdir my-latex-proj && cd my-latex-proj
nix flake init -t github:chzerv/nix-flake-templates#latex
mkdir my-typst-proj && cd my-typst-proj
nix flake init -t github:chzerv/nix-flake-templates#typst
- Rust
- Python
- Ansible
- Terraform