Skip to content
Oeiuwq Faith Blog OpenSource Porfolio

AEduardo-dev/flk

Flakes development environments management tool

AEduardo-dev/flk.json
{
"createdAt": "2025-10-24T09:55:00Z",
"defaultBranch": "main",
"description": "Flakes development environments management tool",
"fullName": "AEduardo-dev/flk",
"homepage": "https://aeduardo-dev.github.io/flk/",
"language": "Rust",
"name": "flk",
"pushedAt": "2026-03-21T09:41:10Z",
"stargazersCount": 8,
"topics": [],
"updatedAt": "2026-03-04T16:28:11Z",
"url": "https://github.com/AEduardo-dev/flk"
}

A modern CLI tool for managing Nix flake development environments with the simplicity of Devbox

Crates.io CI License: MIT Rust codecov

flk makes managing Nix flakes feel like using a package manager. No more manually editing flake.nix files โ€” just use simple commands to add packages, create custom shell commands, and manage your development environment.

  • ๐ŸŽฏ Smart Initialization โ€” Auto-detects your project type (Rust, Python, Node.js, Go)
  • ๐Ÿ“ฆ Easy Package Management โ€” Add/remove packages, pin specific versions
  • โšก Custom Shell Commands โ€” Define reusable commands for your workflow
  • ๐ŸŒ Environment Variables โ€” Manage per-project variables through the CLI
  • ๐Ÿ‘ค Multi-Profile Support โ€” Maintain separate configurations within one project
  • ๐Ÿ”’ Lock File Management โ€” Backup, preview, and restore your flake.lock
  • ๐Ÿณ Container Export โ€” Export environments to Docker, Podman, or JSON
  • ๐Ÿ”„ Hot Reload โ€” Shell hooks for instant refresh and switch between profiles
Terminal window
cargo install flk # install via cargo (or see table below)
flk init # scaffold a flake (auto-detects language)
flk add ripgrep # add a package
flk cmd add test "cargo test --all"
flk env add DB_URL "postgres://localhost/dev"
flk activate # enter the dev shell

See the Getting Started guide for a full walkthrough.

Prerequisites: Nix with flakes enabled โ€” recommended via Lix or the Determinate installer.

MethodCommand
Cargocargo install flk
Nix (run)nix run github:AEduardo-dev/flk#flk
Nix (install)nix profile install github:AEduardo-dev/flk#flk
From sourcegit clone โ€ฆ && cd flk && cargo install --path .
BinariesGitHub Releases
Cachixcachix use flk-cache (prebuilt Nix binaries)

For Nix flake input, overlay, and Home Manager options see the Installation guide.

Enable hot-reload (refresh) and profile switching (switch):

Terminal window
eval "$(flk hook bash)" # or zsh; Fish: flk hook fish | source
CommandDescription
flk initInitialize a new flake environment
flk add / removeAdd or remove packages (--version to pin)
flk search / deep-searchSearch nixpkgs
flk list / showList packages or pretty-print full config
flk cmd add|remove|listManage custom shell commands
flk env add|remove|listManage environment variables
flk profile add|remove|list|set-defaultManage profiles
flk activateEnter the dev shell
flk updateUpdate flake inputs (auto-backup)
flk lock show|history|restoreManage flake.lock snapshots
flk exportExport to Docker, Podman, or JSON
flk direnv init|attach|detachDirenv integration
flk hook <shell>Generate shell hooks
flk completionsGenerate shell completions

Most commands accept -p, --profile <NAME> to target a specific profile.

Full command reference โ†’ Commands documentation

Terminal window
git clone https://github.com/AEduardo-dev/flk.git && cd flk
nix develop # or ensure Rust 1.83+ is available
cargo build # debug build
cargo test # all tests
cargo fmt --all -- --check && cargo clippy -- -D warnings # lint

See the Development guide for project structure, testing details, and CI info.

ResourceLink
User Guide (mdBook)aeduardo-dev.github.io/flk
API Referencedocs.rs/flk

Build locally:

Terminal window
# User guide โ€” serve with live reload
cd flk-book && mdbook serve # http://localhost:3000
# Rust API docs
cargo doc --no-deps --open
# Both via Nix
nix build .#docs

Roadmap

Contributions welcome! See [CONTRIBUTING.md]!(CONTRIBUTING.md) for details. For bugs, please open an issue with reproduction steps and environment info.

  • Devbox โ€” Instant, portable dev environments (inspiration for flk)
  • devenv โ€” Fast, declarative developer environments
  • Flox โ€” Developer environments you can take with you
  • direnv โ€” Shell extension for loading environments

MIT โ€” see [LICENSE]!(LICENSE) for details.

  • The Nix community for creating an amazing ecosystem
  • Jetify for the Devbox inspiration
  • Special mention to @vic for nix-versions
  • All contributors and users of flk

Made with โค๏ธ by AEduardo-dev