How Sync Your Shell History With Atuin in Nix

Atuin is a great tool I recently discovered that can be used to sync our shell history across multiple machines. We can either self-host this or use the “officially” hosted one. In a future article, I will show you how you can self-host your version of Atuin on fly.io. But for this article, I will assume you have a server setup. Your history is end-to-end encrypted so the official server is safe to use and store your history on. ...

TIL: How to get Kanshi to work on NixOS and Hyprland

TIL: How to get Kanshi to work on NixOS and Hyprland I have been using Kanshi to setup my monitor setups automagically depending on which monitors are plugged i.e. if my laptop is docked or not. If it is docked I want my laptop display to be off, when not docked I want it to be on. So my kanshi config file ~/.config/kanshi/config to look something like: I use the name of my monitors as the ports they are plugged into my vary. ...

Part 1: NixOS as part of your Development Workflow

Introduction Dev Machine My main machine for development at the moment is a 12th Generation Intel Framework Laptop. This series has been inspired by Dev Workflow Intro by Josh Medeski. In this series of posts, I will go over how I have set up my developer workflow and explain why I have made certain decisions and why I use certain tools. This series aim to make it less daunting for you to start your journey on improving your developer workflow. ...

Update Nix Packages Using update-nix-fetchgit

Recently I’ve been trying to work out how to update packages that I define declaratively in my Nix config. I think I figured out how to do it using my Nix flake. By running nix flake update and then sudo nixos-rebuild switch --flake ~/dotfiles#framework to update the packages. However, I have some plugins say for tmux which are defined like so: t-smart-manager = pkgs.tmuxPlugins.mkTmuxPlugin { pluginName = "t-smart-tmux-session-manager"; version = "unstable-2023-06-05"; rtpFilePath = "t-smart-tmux-session-manager. ...

Setting Up Tmux With Nix Home Manager

Introduction In this post I will show you how you can setup tmux (plugins) using the nix package manager, specifically using home-manager. I will also show you how you can avoid an issue I encountered where tmux resurrect wasn’t working properly due to plugin ordering. Typically we use the tmux plugin manager to manage our tmux plugins. However, when I moved to NixOS, I wanted to move away from having lots of different ways of managing what is on my system. ...

Why I moved to NixOS

Recently I decided to move from Arch Linux to NixOS. Rather than doing what I should’ve done which was try to use NixOS in a VM first and learn Nix properly. I decided to jump into the deep end and completely delete my current Arch Linux build with Nix. This included replacing my dotfiles setup using DotBot moving them to Nix flakes and home-manager (more on this in a bit). In this post, I’ll go over why I moved over to NixOS, and why I am staying put for now. ...

TIL: How to use NUR with Home-Manager & Nix Flakes

TIL: How to use NUR with Home-Manager & Nix Flakes NUR is the Nix user repository like the Arch user repository (AUR). It exists so that: The NUR was created to share new packages from the community in a faster and more decentralized way. - https://github.com/nix-community/NUR If we want to install packages from NUR in our home manager config which is set up using Nix Flakes. Assuming you build your home manager like ...

TIL: How to Declaratively Setup Mullvad VPN with NixOS

TIL: How to Declaratively Setup Mullvad VPN with NixOS I have recently moved to NixOS, one of the great features of NixOS is that you can set up your entire machine from a single git repo. We can do this declaratively, what we mean by this is we tell nix what we want the state to be and nixos will work out how to get there. For example, we can install Mullvad set various options already. ...