From 2e6cb4bb180eeaf9f82c02cada010df08d061a37 Mon Sep 17 00:00:00 2001 From: James Armstrong <32995055+jmarmstrong1207@users.noreply.github.com> Date: Thu, 29 Feb 2024 16:26:57 -0800 Subject: [PATCH 1/2] Change NixOS guide Instead of changing the environment variable directory, it'll be better to change the setting directly within Nix. See here for more info: https://search.nixos.org/options?channel=23.11&from=0&size=50&sort=relevance&type=packages&query=programs.zsh.oh --- README.MD | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/README.MD b/README.MD index ca2c790..a07edcd 100644 --- a/README.MD +++ b/README.MD @@ -25,10 +25,12 @@ Then add `nix-shell` to the plugins list in `~/.zshrc`. If you have installed `zsh` using `nix` the plugins directory is readonly since it's inside of the nix store. To get around this you can override the [`ZSH_CUSTOM` directory](https://github.com/ohmyzsh/ohmyzsh/wiki/Customization#using-another-customization-directory). -Simply create a writable directory inside of your home directory (e.g. `$HOME/.config/oh-my-zsh`) and set `ZSH_CUSTOM` to that path inside of your `.zshrc` file. +Do so by setting the "custom" attribute in your oh-my-zsh Nix config: -```sh -ZSH_CUSTOM=$HOME/.config/oh-my-zsh +```nix + oh-my-zsh = { + custom = "${config.users.users.YOURUSERNAME.home}/.config/oh-my-zsh"; + }; ``` After that simply install for `oh-my-zsh` as normal. From ab5cf94acc5616d6bf377ea4280b99e712473ff7 Mon Sep 17 00:00:00 2001 From: James Armstrong <32995055+jmarmstrong1207@users.noreply.github.com> Date: Thu, 29 Feb 2024 18:18:38 -0800 Subject: [PATCH 2/2] change home directory The previous variable used only works depending on the environment the home manager was installed --- README.MD | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.MD b/README.MD index a07edcd..e85361f 100644 --- a/README.MD +++ b/README.MD @@ -29,7 +29,7 @@ Do so by setting the "custom" attribute in your oh-my-zsh Nix config: ```nix oh-my-zsh = { - custom = "${config.users.users.YOURUSERNAME.home}/.config/oh-my-zsh"; + custom = "/home/YOURUSERNAME/.config/oh-my-zsh"; }; ```