No description
  • Nix 42.3%
  • Emacs Lisp 41.6%
  • Shell 13.7%
  • TypeScript 2.4%
Find a file
2026-08-15 12:04:49 -07:00
features feat(pi): add pi-npm-activate — zsh with pi's npm environment 2026-08-15 12:04:49 -07:00
programs fix(tmux/ghostty): disable extended-keys, add stty -ixon, disable ghostty shell-integration 2026-07-29 22:16:02 -07:00
.gitignore feat(agents): implement shared directory and add skills 2026-04-13 17:14:33 -07:00
AGENTS.md docs: add guidance on lib.mkIf vs lib.optionals/lib.optionalAttrs to AGENTS.md files 2026-05-10 10:32:29 -07:00
flake.lock chore(pi): bump llm-agents pin to 03eb805f (pi 0.84.2) 2026-08-15 11:22:16 -07:00
flake.nix feat: add zellij support as a feature flag; convert tmux to feature flag too 2026-07-01 22:18:04 -07:00
home.nix feat: add zellij support as a feature flag; convert tmux to feature flag too 2026-07-01 22:18:04 -07:00
README.md Update README 2026-01-09 17:20:56 -08:00

nix-conf

My personal nix configuration.

Installing nix

Darwin

Install Deterministic Nix curl -fsSL https://install.determinate.systems/nix | sh -s -- install

Linux

Use the multiuser installer

sh <(curl --proto '=https' --tlsv1.2 -L https://nixos.org/nix/install) --daemon

Setup this home-manager config

nix run home-manager/master -- --init switch

rm -rf ~/.config/home-manager

git clone git@github.com:davebenvenuti/home-manager.git ~/.config/home-manager

Apply

Assuming the hostnames are set properly (air or shithouse),

home-manager switch

If they're not set, you can switch to individual configurations by doing

home-manager switch --flake .#dave@air

If you get an error about clobber files, run

home-manager switch -b hmbackup

Uninstalling Nix

Darwin

/nix/nix-installer uninstall

Linux

See Nix Reference Manual | Uninstalling Nix

Notes

home-manager was initialized with nix run home-manager/master -- init --switch. This created ~/.config/home-manager.

For more information see the home-manager flakes standalone docs

man home-configuration.nix explains Home Manager configuration specification

https://github.com/sadjow/home-manager/ was helpful

Zshrc.private Sync System

This configuration includes a system to securely sync your ~/.zshrc.private file to Bitwarden. This file is meant for sensitive environment variables, API keys, and other secrets that shouldn't be committed to version control.

How it works:

  1. Prompt Indicator: A yellow asterisk (*) appears in your zsh prompt when ~/.zshrc.private has been modified but not yet synced to Bitwarden.

  2. Sync Command: Run sync-zshrc-private to upload the current version to Bitwarden as a secure note. The note is named .zshrc.private (HOSTNAME).

  3. Status Check: Use zshrc-private-status to check if your file is synced without syncing.

  4. Manual Refresh: If needed, run refresh-zsh-prompt to immediately update the prompt indicator.

Setup:

  1. Ensure Bitwarden CLI is installed and configured (bw command available)
  2. Run bw login to log into your Bitwarden account
  3. Run bw unlock to unlock your vault and get a session key
  4. Set the session key as an environment variable:
    export BW_SESSION="$(bw unlock --raw)"
    
    (Consider adding this to your shell configuration)

Files:

  • ~/.zshrc.private: Your private shell configuration (not tracked in git)
  • ~/.zshrc.private.lastsync: Stores the hash of the last synced version
  • ~/.local/bin/sync-zshrc-private.sh: Sync script
  • ~/.local/share/zsh/zshrc-private-sync.zsh: Zsh plugin for prompt integration

How the prompt indicator updates:

The indicator is part of the PROMPT string itself ($(_zshrc_private_prompt_indicator)), so it's evaluated each time the prompt is displayed. This means it updates automatically without needing to reload your shell or run special commands.