Skip to content

Instantly share code, notes, and snippets.

@lesserfish
lesserfish / nixos_setup.md
Last active July 5, 2025 04:03
Setting up NixOS with impermanence!

Nix OS with impermanence

The following steps describe how to set up NixOS with impermanence using a ZFS drive.

Getting an initial configuration file

The configuration file generated by nixos-generate-config is quite barebones. If you are comfortable creating the initial configuration.nix file yourself, feel free to skip these steps.

  1. Run the NixOS installer normally. Install NixOS on your entire hard drive.
  2. Once finished, do NOT restart
@nessex
nessex / upgrade-qidi-x-plusmax3.sh
Last active July 7, 2025 08:53
Script for updating a QIDI X-Plus3 / X-Max3 to latest Klipper, Moonraker, Fluidd etc.
#!/bin/bash
## upgrade-qidi-x-plusmax3.sh
##
## Usage:
##
## ssh -u mks {printer_ip}
## curl https://gist.githubusercontent.com/nessex/7b574fbe6d965439b773d922ca1b9e05/raw -sSF | bash
##
## OR:
##
@jrknox1977
jrknox1977 / ollama_dspy.py
Created February 9, 2024 18:06
ollama+DSPy using OpenAI APIs.
# install DSPy: pip install dspy
import dspy
# Ollam is now compatible with OpenAI APIs
#
# To get this to work you must include `model_type='chat'` in the `dspy.OpenAI` call.
# If you do not include this you will get an error.
#
# I have also found that `stop='\n\n'` is required to get the model to stop generating text after the ansewr is complete.
# At least with mistral.
@luchoeben
luchoeben / citadel-x86-setup.md
Last active February 29, 2024 19:14 — forked from pwltr/citadel-x86-setup.md
Citadel Guide #1: How to get Citadel running on x86

How to get Citadel running on a regular computer

This is a step-by-step guide to get Citadel running on a x86 architecture computer like a desktop PC, laptop or Intel NUC.

The system requirements for running a Citadel are:

• Ubuntu 22.04 / Debian 11 (or later)
• 4GB RAM (minimum)
• 1.5GHz CPU (minimum)

• 1TB SSD

@baradhiren
baradhiren / .bashrc
Created August 28, 2019 14:38
Termux bashrc with common aliases and functions
#########
# Aliases
#########
# Always copy contents of directories (r)ecursively and explain (v) what was done
alias cp='cp -rv'
# List contents with colors for file types, (A)lmost all hidden files (without . and ..), in (C)olumns, with class indicators (F)
alias ls='ls --color=auto -ACF'
# List contents with colors for file types, (a)ll hidden entries (including . and ..), use (l)ong listing format, with class indicators >
alias ll='ls --color=auto -alF'