Skip to content

Preface

Welcome! This guide is my take on trying to teach the wonders of Nix and NixOS from scratch. Although the main goal of this guide is getting you started with NixOS, we’ll only install the OS later on. I try to prioritize getting a safe environment for you to learn in over getting NixOS installed fully right away.

Prerequisites

You’ll need to already be on a Linux distro, as Nix is for Linux (and MacOS technically) only.

In addition you should be familiar with a few concepts.

  1. Linux in general, NixOS isn’t a good distro to start out with
  2. Programming (even better, functional programming)
  3. Git

Reading

There will be a few visual aids used throughout this book.

Code blocks will be obvious against all other text, you can view the name of the file you should be editing in the tab at the top.

file.nix
# Look at the tab!

There will be times when you’ll need to replace parts of a code block with stuff specific to you. When this happens that part of the code will be highlighted.

file.nix
# A line
# another line
# REPLACE THIS!

Finally, to keep things clean I’ll often omit part of files. This will be denoted with ....

file.nix
# ...
# the important part
# ...

Ready?

That’s about all you need to know before starting. Thank you for reading!