Ayman's (~) Nix and NixOS dotfiles It uses nixOS, home-manager, and nix-darwin.
Colorscheme: Onedark
Shell: zsh/pwsh
Terminal: Ghostty/iTerm2/WindowsTerminal
Font: Inconsolata LGC + NF
This is only necessary when you're not running NixOS.
# On MacOS
# Use Determinate Systems Nix installer
# I find this a more stable and reliable installation for MacOS
# You can also use the official Nix installer
# sh <(curl -L https://nixos.org/nix/install)
curl --proto '=https' --tlsv1.2 -sSf -L https://install.determinate.systems/nix | sh -s -- install
# Install Homebrew (Optional)
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
# Add the fonts tap (Optional)
brew tap homebrew/cask-fonts
# Change the hostname and machine name
# Go to System Settings and change both the machine name and Sharing hostname
# to the machine hostname.
# You also want to set the hostname using `scutil`
sudo scutil --set HostName <hostname>
# On Linux
sh <(curl -L https://nixos.org/nix/install) --daemon
See Nix download page for more info.
This dotfiles use Nix Flakes, make sure it's enabled on your system.
Using NixOS, add the following to your configuration.nix
:
nix = {
package = pkgs.nixFlakes;
extraOptions = ''
experimental-features = nix-command flakes
'';
};
Otherwise:
mkdir -p "$HOME/.config/nix"
echo "experimental-features = nix-command flakes" >> "$HOME/.config/nix/nix.conf"
To apply or update the dotfiles and configurations, first make sure you have cloned the repository:
git clone https://github.com/aymanbagabas/dotfiles.git ~/.dotfiles
Now you can use nix develop
to run the commands in development shell.
# apply dotfiles
nix develop .#default --command dot-apply
# sync with latest
nix develop .#default --command dot-sync
See this gist.
Neovim: