Skip to content

Instantly share code, notes, and snippets.

View nat-418's full-sized avatar

Nat nat-418

View GitHub Profile
@nat-418
nat-418 / running-your-own-nix-channel.md
Last active March 24, 2024 20:02
Running your own Nix channel

Running your own Nix channel

In my previous article, [How to build with Nix], I explained how to write a Nix package and contribute it to the official Nix package repository. One of the advantages of Nix is how easy it is to develop your own custom Nix package repository, called a channel. A channel can be implemented simply as a tarball containing a default.nix file like this:

let
  pkgs = import <nixpkgs> {};
in
@nat-418
nat-418 / packaging-scripts-for-nix.md
Last active March 21, 2024 17:09
Packaging scripts for Nix

Packaging scripts for Nix

In a previous article, I described how to [build a Nix package]. In this article, I will discuss how to package scripts: specifically, how to handle their runtime dependencies.

Let's begin with the example of a simple script:

#!/usr/bin/env xonsh

aspe:keyoxide.org:ESQIYIHUFMW4ZI3NLH3TFYM2CM

@nat-418
nat-418 / conduit-heisenberg-caddy-nixos.md
Last active May 12, 2025 02:51
Self-hosting Matrix with an IRC bridge on NixOS

Self-hosting Matrix with an IRC bridge on NixOS

Warning

I initially wrote this after getting everything described set up. Since then I have learned the hard way that Matrix is actually broken in several important aspects and I do not recommend self-hosting it. I am leaving the Gist up for reference and in the off-chance it may help others.

Introduction

There are two main free and open-source technologies today for real-time