Search code examples
zsh

What is the difference between .zshrc and .zshrc.local and when is .zshrc.local sourced?


I was following this tutorial https://nixos.wiki/wiki/Development_environment_with_nix-shell

And it says to put some code in .zshrc.local. I never heard about this file and can't find any documentation about it.

What is the difference between .zshrc and .zshrc.local and when is the latter sourced?


Solution

  • The file .zshrc.local is specfic to Grml's Zsh config: https://github.com/grml/grml-etc-core/blob/master/etc/zsh/zshrc#L14

    The page you linked to is from an unofficial NixOS users' wiki. Whoever wrote that page just happened to use Grml and apparently didn't realize that .zshrc.local is non-standard. Grml is also referred to in a couple of other pages on that wiki.