psst. i'm the logo.
🌨️ you found the nix way
Крок 0 / 11
Step 0

What even is an OS?

An operating system is the layer that starts your computer, runs programs, talks to hardware, and keeps everything organized. Windows and macOS are operating systems. Linux systems are operating systems too, and NixOS is one of them.

Step 1

What is NixOS?

The OS that never lies about its state.

Think of it this way: most operating systems are like a messy desk. You install things, delete things, update things — and over time the desk gets cluttered with stuff you don't remember putting there. NixOS is different. It's like having a desk that resets to exactly the state you described every single morning. You write down what you want — 'I want Firefox, git, and a running web server' — and NixOS makes exactly that happen. Nothing extra. Nothing hidden. And if you wrote it down wrong, you just go back to yesterday's note.

Step 2

nixpkgs is the source map

A GitHub repo with 80,000+ Nix expressions. Each expression says how software should be built.

The important part: nixpkgs is not a magic binary package server.

It is a git repo full of build recipes. Binary caches are an optimization layered on top.

firefox: 109.0 → 110.0
8f31c2a · packages/browser
now
+ version = "110.0"; + hash = "sha256-new"; + patches = [ ./sandbox.patch ]; - version = "109.0";
openssl: patch CVE metadata
4a91e70 · pkgs/development
+2s
+ knownVulnerabilities = []; + meta.security = "patched"; - meta.security = "pending";
nginx: enable brotli module
d0c31fb · servers/http
+4s
+ modules = [ brotli ]; + passthru.tests = nginxTests; - modules = [];
python312Packages: refresh hashes
b71a092 · python-modules
+6s
+ pytestCheckHook + sha256 = "sha256-refreshed"; - sha256 = "sha256-old";
Step 3

A derivation is a recipe

It describes inputs and build steps. It is not the package itself.

{
  name = "hello-2.12.1";
  src = fetchurl {
    url = "mirror://gnu/hello/hello-2.12.1.tar.gz";
    sha256 = "sha256-...";
  };
  buildInputs = [ gcc glibc ];
  buildPhase = "make";
}
name

A human-readable package identity. Still only part of the recipe.

Step 4

The Nix store makes state explicit

Every package lands in a unique immutable path. Dependencies are not hidden.

source.tar.gz sha256-... hello.drv builder + inputs /nix/store/abc123-firefox-109/ /nix/store/def456-gtk-3.24/ /nix/store/ghi789-glibc-2.37/ /nix/store/jkl012-openssl-3.0/
Step 5

configuration.nix describes truth

You declare the system you want. NixOS builds that state instead of guessing what changed.


          
look at you, enabling everything 👀

          
Step 6

Generations & Rollback

Every time you change your config and rebuild, NixOS saves the old version. You can jump back to any point like a save file in a game.


          

Step 7

Flakes make inputs explicit

A flake adds locked inputs and predictable outputs. The lockfile pins the exact nixpkgs revision.

{
  description = "demo system";

  inputs.nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable";

  outputs = { self, nixpkgs }: {
    packages.x86_64-linux.default = ...;
    devShells.x86_64-linux.default = ...;
  };
}

inputs.nixpkgs.url

Where nixpkgs comes from. No implicit channel.

outputs

A function from inputs to buildable results.

packages / devShells

Named things other machines can build the same way.

Step 8

Dev shells remove setup drift

nix develop drops you into a shell with every tool your project needs — exact versions, no conflicts, works on any machine.

Before (other OS)

click to run setup

With Nix

click to enter shell
Step 9

The Nix Language

Nix code looks strange first, but most common snippets are small ideas repeated.

{ pkgs, ... }: { ... }

This is a function. It receives the package collection and returns your config.

with pkgs; [ git firefox ]

with is like saying 'look inside pkgs for these names'. The list is your packages.

mkDerivation { ... }

mkDerivation is the recipe builder. Give it a name, source, and build steps — it gives you a package.

Step 10

Why it matters

NixOS turns machine state into data you can inspect, rebuild, and roll back.

Reproducible Builds

The recipe lists exact inputs. If inputs match, the build path and result can match too.

Atomic Upgrades

A new system generation is built beside the old one. Switch succeeds as one step or the old system remains.

Instant Rollbacks

Old generations stay available. If an upgrade breaks, boot or switch back to known-good state.

Step 11

Where to go from here

Built as a school project by Melvi Made with vanilla HTML, CSS, and JS — no frameworks. Design inspired by Anthropic/Claude.ai. fan detected ✦

Fun facts