From 400251c08fadb3a837b8849edcaae0132daeb329 Mon Sep 17 00:00:00 2001 From: earnest ma Date: Wed, 6 Jul 2022 13:52:32 -0400 Subject: [PATCH] Add sd --- .sd/nix/sync | 14 ++++++++++++++ user.nix | 6 ++++++ zsh/.zshrc | 3 +++ 3 files changed, 23 insertions(+) create mode 100755 .sd/nix/sync create mode 100644 user.nix diff --git a/.sd/nix/sync b/.sd/nix/sync new file mode 100755 index 0000000..ada4cd5 --- /dev/null +++ b/.sd/nix/sync @@ -0,0 +1,14 @@ +#!/usr/bin/env bash + +# make user environment match ~/.dotfiles/user.nix +# +# This will remove any packages you've installed with nix-env +# but have not added to user.nix. To see exactly what this +# will do, run: +# +# sd nix diff +# https://github.com/ianthehenry/sd-nix/blob/master/sync + +set -euo pipefail + +nix-env -irf ~/.dotfiles/user.nix diff --git a/user.nix b/user.nix new file mode 100644 index 0000000..7a53c49 --- /dev/null +++ b/user.nix @@ -0,0 +1,6 @@ +with import {}; [ + ghq + onefetch + nodejs + nix +] diff --git a/zsh/.zshrc b/zsh/.zshrc index 5d0c7d4..ffb67d9 100644 --- a/zsh/.zshrc +++ b/zsh/.zshrc @@ -138,6 +138,9 @@ miniplug theme 'tjquillan/pastel' miniplug load +export SD_ROOT="$HOME/.dotfiles/.sd" +export SD_CAT=bat + # auto cd must be set later setopt AUTO_CD