Skip to content

Instantly share code, notes, and snippets.

View patrl's full-sized avatar

Patrick Elliott patrl

View GitHub Profile
@kborling
kborling / init.el
Last active November 16, 2023 18:07
My emacs config
;;; init.el --- My personal emacs config -*- lexical-binding: t; -*-
;; Author: Kevin Borling <https://github.com/kborling>
;; Version: 1.1.0
;; Keywords: configuration
;; URL: https://gist.github.com/kborling/13f2300e60ae4878d5d96f5f4d041664
;; Homepage: https://gist.github.com/kborling/13f2300e60ae4878d5d96f5f4d041664
;; Package-Requires: ((emacs "28.1"))
;;; Commentary:
@dysinger
dysinger / configuration.nix
Last active December 28, 2022 18:39
Basic Full-Disk Encrypted ZFS Thinkpad (w/ 512 sector SSD) booted from USB key
# Basic Full-Disk Encrypted ZFS Thinkpad (w/ 512 sector SSD) booted from USB key
# EFI/BOOT:
# export BOOT=/dev/disk/by-id/usb-SanDisk_Ultra_Fit_4C530001011030101042-0\:0
# parted --script $BOOT -- \
# mklabel gpt \
# mkpart esp fat32 1MiB 512MiB \
# mkpart primary 512MiB 100% \
# set 1 boot on
# mkfs.vfat -n BOOT $BOOT-part1
@masaeedu
masaeedu / init-haskell.sh
Last active May 20, 2021 15:24
Basic nix haskell setup
#!/usr/bin/env bash
set -Eeuxo pipefail
# Set up git
git init
gitignore haskell
echo '*.cabal' >> .gitignore
# Set up niv
niv init
@dysinger
dysinger / nixos-encrypted-zfs.sh
Last active March 7, 2023 14:51
How I installed Encrypted ZFS root on NixOS
# MOVED HERE https://gist.github.com/dysinger/2a768db5b6e3b729ec898d7d4208add3
@peti
peti / README.md
Last active January 29, 2024 00:21
Make NixOS provide version-specific LOCALE_ARCHIVE environment variables

This NixOS code ensures that the system provide version-specific $LOCALE_ARCHIVE environment variables to mitigate the effects of NixOS/nixpkgs#38991.

To deploy it, copy the file into your /etc/nixos folder using a file name like multi-glibc-locale-paths.nix. Then edit your configuration.nix file to contain the attribute:

imports = [ ./multi-glibc-locale-paths.nix ];
@schar
schar / Heim.hs
Last active April 9, 2018 11:03
Heim (1983) monadically
import Control.Applicative
import Control.Monad
import Data.List
data Atom = P | Q | R | Top
deriving (Show, Eq, Enum)
type W = [Atom]
type C = [W]
type Upd m = m C -> m C
@micrub
micrub / xmonad-default-key-bindings.md
Last active March 28, 2024 15:06
Xmonad default key bindings

xmonad default key bindings

Action key bindings

Key binding Action
mod - shift - slash Run xmessage with a summary of the default keybindings (useful for beginners)
mod - shift - return Launch terminal
mod - p Launch dmenu
mod - shift - p Launch gmrun
% requires the booktabs package
\newcommand\semtower[2]{% a 2-level semantic tower
\begin{tabular}[c]{@{\,}c@{\,}}
\(#1\)
\\
\midrule
\(#2\)
\\
\end{tabular}
}
{-# language KindSignatures #-}
{-# language PolyKinds #-}
{-# language DataKinds #-}
{-# language TypeFamilies #-}
{-# language RankNTypes #-}
{-# language NoImplicitPrelude #-}
{-# language FlexibleContexts #-}
{-# language MultiParamTypeClasses #-}
{-# language GADTs #-}
{-# language ConstraintKinds #-}
@pkazmierczak
pkazmierczak / aws-openvpn-cf.json
Last active December 15, 2019 20:03
Cloudformation template for creating a simple OpenVPN server
{
"AWSTemplateFormatVersion": "2010-09-09",
"Description": "OpenVPN server template",
"Mappings": {
"AWSRegion2AMI": {
"ap-northeast-1": {
"AMI": "ami-5ea72b5e"
},
"ap-southeast-1": {
"AMI": "ami-365c5764"