Skip to content

Personal config files for NixOS. See my other rices in the link below!

License

Notifications You must be signed in to change notification settings

datsfilipe/dotfiles

Repository files navigation

datsfilipe’s Dotfiles

GitHub Repo stars GitHub issues

Preview

Description

Note: The wallpapers I use are here: https://drive.google.com/drive/folders/walls.

This repository contains personal configuration files for Linux-based systems, specifically tailored for NixOS. This is where I do my rices =D

If you wanna see my past rices, take a look here (this website is awful, I know. I'll improve it soon).

Installation

An observation: There's probably a better and easier way to do this installation, so if you know a better way, please let me know, I'm not an expert in NixOS.

Some notes before we start:

  • flake will be used to refer to this project (repository), which is a flake. If you want to know more about flakes and Nix, I recommend this.
  • <name> is literally just the name of the folder you can choose to clone the repository as. Ex: git clone https://github.com/datsfilipe/dotfiles.git /mnt/etc/nixos/<name>.

Step-by-step

  1. First you need to create your disk partitions and filesystems and mount them. Please refer to NixOS documentation for this.
  2. Clone the repository inside the /mnt/etc/nixos directory:
$ nix-shell -p git # inside the shell...
$ git clone https://github.com/datsfilipe/dotfiles.git /mnt/etc/nixos/<name>
  1. Some tweaks are required. First, you need to update the .gitmodules file inside the flake (the repository you just cloned) to point to the correct submodule url. As you don't have my ssh keys (thanks god!) you need to update them to https links, it's pretty straightforward, so I'm gonna extend on that. After you updated it, do:
$ git submodule update --init --recursive
  1. You also need to update the submodule paths insdie flake.nix to point to the correct submodule folders. Example:

git+file:///home/dtsf/.dotfiles/dotfiles/nvim?shallow=1 -> git+file:///mnt/etc/nixos/<name>/dotfiles/nvim?shallow=1

  1. You also need to generate your hardware configuration file (if you already created it, you can skip this step). This is done by running:
$ nixos-generate-config --root /mnt
  1. You need to delete the /mnt/etc/nixos/<name>/hosts/dtsf-machine/hardware-configuration.nix file inside the flake.
  2. You need to copy the /mnt/etc/nixos/hardware-configuration.nix file inside the flake (copy it to /mnt/etc/nixos/<name>/hosts/dtsf-machine/hardware-configuration.nix).
  3. Now you can install the system:
$ cd /mnt/etc/nixos/<name>
$ nixos-install --flake .?submodules=1#<host>

Star History

Star History Chart