Setting up a workstation involves two main phases:
- Bootstrap – Install Nix on a Debian-based system and the base tools (populating nix/base)
- Provision – Install APT/Flatpak packages and apply configurations via mise
The setup process requires the dennybaa/dotfiles repository (you're already here). Install Git and perform the initial configuration:
sudo apt install git -y
# Clone the repository
cd ~ && git clone git@github.com:dennybaa/dotfiles.git
# Alternative: clone via public HTTPS
# cd ~ && git clone https://github.com/dennybaa/dotfiles.gitThe provision phase installs required software and applies system configurations. This process is orchestrated by mise and leverages:
nu/install-packages.nu– Handles package operations: updating APT sources, installing APT and Flatpak packages, and managing pre-built Nix profiles- mise – Executes configuration hooks
-
Bootstrap installs Nix on your Debian-based system—the first step to using this repository.
cd ~/dotfiles && ./bootstrap.sh && . /etc/profile.d/nix.sh
Once bootstrapped, proceed with full provisioning using mise tasks.
-
Run the necessary bootstrap tasks (post-Nix setup).
mise run bootstrap
-
Configure GitHub token for tools
Why this matters: Configuring authentication prevents GitHub API rate limiting when package managers like Nix or mise fetch sources.
Recommended approach: Create and use a fine-grained personal access token (PAT) for:
- Generate a token at: https://github.com/settings/personal-access-tokens for only public repositories
Use the
setup:github-tokentask: This will prompt you for the token input and update necessary files:mise run setup:github-token
Mise tasks:
mise tasks
mise run nix:add --help # for details about the command adding packages from nix/<bundle> flakes into profileChoose the appropriate command based on your system type:
-
Console system (terminal-only):
mise provision
-
Desktop system (includes GUI applications):
mise provision:desktop
Note: Use the
--update(or-u) flag to refresh installed packages.
System package configuration is defined in packages.nu. Here's what it contains:
AptSources– Files to be placed in/etc/apt/sources.list.d/and optional GPG key URLs for provisioningAptPackagesandFlatpakPackages– Application bundles organized by type (base, desktop, etc.)
For example, to install both base and desktop APT package bundles:
mise packages:apt base desktopNote: Management of flake-based Nix profiles is intentionally not grouped under the mise
packages:nixtask.
Nix profiles are defined in nix/*/flake.nix files. A Nix flake may have multiple outputs—for instance, nix/code/flake.nix contains default and desktop outputs.
When installing a Nix profile, you cannot install multiple output sets simultaneously. Choose the specific output you need:
mise nix -o desktop nix/codeNote: If you previously installed a different flake output for a given profile, the operation will fail.