Skip to content

Instantly share code, notes, and snippets.

@jmatsushita
jmatsushita / README
Last active May 9, 2024 19:39
Setup nix, nix-darwin and home-manager from scratch on an M1 Macbook Pro
###
### [2023-06-19] UPDATE: Just tried to use my instructions again on a fresh install and it failed in a number of places.
###. Not sure if I'll update this gist (though I realise it seems to still have some traffic), but here's a list of
###. things to watch out for:
### - Check out the `nix-darwin` instructions, as they have changed.
### - There's a home manager gotcha https://github.com/nix-community/home-manager/issues/4026
###
# I found some good resources but they seem to do a bit too much (maybe from a time when there were more bugs).
# So here's a minimal Gist which worked for me as an install on a new M1 Pro.
@simonw
simonw / how-to-upgrade-heroku-postgresql.md
Last active April 29, 2024 05:07
How to upgrade a Heroku PostgreSQL database to a new plan

How to upgrade a Heroku PostgreSQL database to a new plan

I started a project on a Hobby Dev plan (free, limit 10,000 rows), and then later needed to upgrade it to Hobby Basic ($9/month, limit 10,000,000 rows).

After assigning the new database, I had two databases attached to the application. They looked something like this:

  • HEROKU_POSTGRESQL_OLIVE (postgresql-dimensional-3321) Old, free-tier (Hobby Dev) database
@j-keck
j-keck / notebook-impure.nix
Last active January 27, 2022 13:47
nixos - ipython with octave kernel
with import <nixpkgs> {}; {
pyEnv = stdenv.mkDerivation {
name = "octave-kernel";
buildInputs = [ python27Packages.pip python27Packages.virtualenv python27Packages.jupyter python27Packages.notebook octave gnuplot];
shellHook = ''
if [ ! -d venv ] ; then
virtualenv venv
./venv/bin/pip install octave_kernel