Skip to content

Instantly share code, notes, and snippets.

@timstott
timstott / partition-nixos-zfs-swap-luks.sh
Last active June 7, 2021 22:29
discourse.nixos.org/t/nixos-on-luks-encrypted-partition-with-zfs-and-swap/6873 - original script
#!/usr/bin/env bash
# NixOS install with encrypted root and swap
#
# sda
# ├─sda1 BOOT
# └─sda2 LINUX (LUKS CONTAINER)
# └─cryptroot LUKS MAPPER
# └─cryptroot1 SWAP
# └─cryptroot2 ZFS
@timstott
timstott / use-password-store-with-forge.org
Last active February 2, 2024 11:31
Use password-store (aka pass) with forge and github-review

Use password-store (aka pass) with forge and github-review

We can use pass as an emacs auth-source backend to access credentials.

Add auth-source-pass (included with emacs 26) to your emacs config:

(require 'auth-source-pass)
(auth-source-pass-enable)

This prepends password-store to the variable auth-sources.

@timstott
timstott / circleci_fetch_artifact
Created March 23, 2021 15:45
Fetch/Download specific artifact from CircleCI build
#!/usr/bin/env bash
set -euo pipefail
log_debug() {
local blue="\e[34m"
local default="\e[39m"
# ISO8601 timestamp + ms
local timestamp=$(date +%FT%T.%3NZ)
echo -e "${blue}${timestamp} [debug] $1${default}" 1>&2
@timstott
timstott / install.sh
Last active December 22, 2023 08:28 — forked from mx00s/install.sh
NixOS install script based on @grahamc's "Erase Your Darlings" blog post
#!/usr/bin/env bash
# Original https://gist.github.com/mx00s/ea2462a3fe6fdaa65692fe7ee824de3e
#
# NixOS install script synthesized from:
#
# - Erase Your Darlings (https://grahamc.com/blog/erase-your-darlings)
# - ZFS Datasets for NixOS (https://grahamc.com/blog/nixos-on-zfs)
# - NixOS Manual (https://nixos.org/nixos/manual/)
#