Screenshots last updated September 3rd, 2024
This is my NixOS configuration, based on FrostPhoenix's amazing config
- Home-Manager is installed as a standalone
- NeoVim is my editor of choice, the configuration is in its own repository. It is manually cloned in the installer script
- The color scheme is Gruvbox-Dark There are other minor differences, mainly small changes like installed packages and extensions.
- flake.nix base of the configuration
- hosts 🌳 per-host configurations that contain machine specific configurations
- modules 🍱 modularized NixOS configurations
- core ⚙️ Core NixOS configuration
- home 🏠 my Home-Manager config
- services 📥 Self-hosted services mainly running on homelab
- wallpapers 🌄 wallpaper and lock screen images
| NixOS + Hyprland | |
|---|---|
| Window Manager | Hyprland |
| Bar | Waybar |
| Application Launcher | fuzzel |
| Notification Daemon | swaync |
| Terminal Emulator | Kitty |
| Shell | zsh + oh-my-zsh / nushell + Starship |
| Text Editor | VSCodium + Neovim |
| network management tool | NetworkManager + network-manager-applet |
| System resource monitor | Btop |
| File Manager | nemo + yazi |
| Fonts | Nerd fonts + SN Pro |
| Color Scheme | Gruvbox-Dark |
| Cursor | Nordzy-cursors |
| Icons | Gruvbox-Icons + Gruvbox-Icons-Plus |
| Lockscreen | Swaylock-effects |
| Image Viewer | imv |
| Media Player | mpv |
| Music Player | audacious |
| Screenshot Software | grimblast |
| Screen Recording | wf-recorder |
| Clipboard | wl-clip-persist |
| Color Picker | hyprpicker |
| Notes | Obsidian |
Utils (EXPAND)
-
c$\rightarrow$ clear -
cd$\rightarrow$ z -
tt$\rightarrow$ gtrash put -
vim$\rightarrow$ nvim -
cat$\rightarrow$ bat -
nano$\rightarrow$ micro -
icat$\rightarrow$ kitten icat -
dsize$\rightarrow$ du -hs -
findw$\rightarrow$ grep -rl -
l$\rightarrow$ eza --icons -a --group-directories-first -1 -
ll$\rightarrow$ eza --icons -a --group-directories-first -1 --no-user --long -
tree$\rightarrow$ eza --icons --tree --group-directories-first -
inv$\rightarrow$ fzf -m --preview="bat --color=always {}" --bind "enter:become(nvim {+})" -
clip$\rightarrow$ wl-copy <
Nixos (EXPAND)
${host} is either
desktoporlaptop
-
cdnix$\rightarrow$ cd ~/nixos-config && codium ~/nixos-config -
nix-switch$\rightarrow$ sudo nixos-rebuild switch --flake ~/nixos-config#${host} -
nix-switchu$\rightarrow$ sudo nixos-rebuild switch --upgrade --flake ~/nixos-config#${host} -
nix-flake-update$\rightarrow$ sudo nix flake update ~/nixos-config# -
nix-clean$\rightarrow$ nh clean all --keep 5 -
nix-list$\rightarrow$ sudo nix-env --list-generations --profile /nix/var/nix/profiles/system -
hm-switch$\rightarrow$ home-manager switch --flake ~/nixos-config -
hm-list$\rightarrow$ home-manager generations -
nix-switch-all$\rightarrow$ hm-switch && nix-switch -
nix-develop$\rightarrow$ nix develop -c $SHELL
Git (EXPAND)
-
ga$\rightarrow$ git add -
gaa$\rightarrow$ git add --all -
gs$\rightarrow$ git status -
gb$\rightarrow$ git branch -
gm$\rightarrow$ git merge -
gpl$\rightarrow$ git pull -
gplo$\rightarrow$ git pull origin -
gps$\rightarrow$ git push -
gpso$\rightarrow$ git push origin -
gc$\rightarrow$ git commit -
gcm$\rightarrow$ git commit -m -
gch$\rightarrow$ git checkout -
gchb$\rightarrow$ git checkout -b -
gcoe$\rightarrow$ git config user.email -
gcon$\rightarrow$ git config user.name
All the scripts are in modules/home/scripts/scripts/ and are exported as packages in modules/home/scripts/default.nix
extract.sh
Description: This script extracts tar.gz archives in the current directory.
Usage: extract <archive_file>
compress.sh
Description: This script compresses a file or a folder into a tar.gz archives which is created in the current directory with the name of the chosen file or folder.
Usage: compress <file> or compress <folder>
toggle_blur.sh
Description: This script toggles the Hyprland blur effect. If the blur is currently enabled, it will be disabled, and if it's disabled, it will be turned on.
Usage: toggle_blur
toggle_oppacity.sh
Description: This script toggles the Hyperland oppacity effect. If the oppacity is currently set to 0.90, it will be set to 1, and if it's set to 1, it will be set to 0.90.
Usage: toggle_oppacity
maxfetch.sh
Description: This script is a modified version of the jobcmax/maxfetch script.
Usage: maxfetch
music.sh
Description: This script is for managing Audacious (music player). If Audacious is currently running, it will be killed (stopping the music); otherwise, it will start Audacious in the 8th workspace and resume the music.
Usage: music
runbg.sh
Description: This script runs a provided command along with its arguments and detaches it from the terminal. Handy for launching apps from the command line without blocking it.
Usage: runbg <command> <arg1> <arg2> <...>
View all keybinds by pressing $mainMod F1 and wallpaper picker by pressing $mainMod w. By default $mainMod is the SUPER key.
Keybindings
bind = $mainMod, Return, exec, kittybind = ALT, Return, exec, kitty --title float_kittybind = $mainMod SHIFT, Return, exec, kitty --start-as=fullscreen -o 'font_size=16'bind = $mainMod, B, exec, firefoxbind = $mainMod, Q, killactive,bind = $mainMod, F, fullscreen, 0bind = $mainMod SHIFT, F, fullscreen, 1bind = $mainMod, Space, togglefloating,bind = $mainMod, D, exec, fuzzelbind = $mainMod, Escape, exec, swaylockbind = $mainMod SHIFT, Escape, exec, shutdown-scriptbind = $mainMod, P, pseudo,bind = $mainMod, J, togglesplit,bind = $mainMod, E, exec, nemobind = $mainMod SHIFT, B, exec, pkill -SIGUSR1 .waybar-wrappedbind = $mainMod, C ,exec, hyprpicker -abind = $mainMod, W,exec, wallpaper-picker
Screenshot
bind = $mainMod, Print, exec, grimblast --notify --cursor save area ~/Pictures/$(date +'%Y-%m-%d-At-%Ih%Mm%Ss').pngbind = ,Print, exec, grimblast --notify --cursor copy area
Switch window focus
bind = $mainMod, left, movefocus, lbind = $mainMod, right, movefocus, rbind = $mainMod, up, movefocus, ubind = $mainMod, down, movefocus, d
Switch workspace
bind = $mainMod, 1, workspace, 1bind = $mainMod, 2, workspace, 2bind = $mainMod, 3, workspace, 3bind = $mainMod, 4, workspace, 4bind = $mainMod, 5, workspace, 5bind = $mainMod, 6, workspace, 6bind = $mainMod, 7, workspace, 7bind = $mainMod, 8, workspace, 8bind = $mainMod, 9, workspace, 9bind = $mainMod, 0, workspace, 10
Switch window to workspace
bind = $mainMod SHIFT, 1, movetoworkspace, 1bind = $mainMod SHIFT, 2, movetoworkspace, 2bind = $mainMod SHIFT, 3, movetoworkspace, 3bind = $mainMod SHIFT, 4, movetoworkspace, 4bind = $mainMod SHIFT, 5, movetoworkspace, 5bind = $mainMod SHIFT, 6, movetoworkspace, 6bind = $mainMod SHIFT, 7, movetoworkspace, 7bind = $mainMod SHIFT, 8, movetoworkspace, 8bind = $mainMod SHIFT, 9, movetoworkspace, 9bind = $mainMod SHIFT, 0, movetoworkspace, 10bind = $mainMod CTRL, c, movetoworkspace, empty
Window control
bind = $mainMod SHIFT, left, movewindow, lbind = $mainMod SHIFT, right, movewindow, rbind = $mainMod SHIFT, up, movewindow, ubind = $mainMod SHIFT, down, movewindow, dbind = $mainMod CTRL, left, resizeactive, -80 0bind = $mainMod CTRL, right, resizeactive, 80 0bind = $mainMod CTRL, up, resizeactive, 0 -80bind = $mainMod CTRL, down, resizeactive, 0 80bind = $mainMod ALT, left, moveactive, -80 0bind = $mainMod ALT, right, moveactive, 80 0bind = $mainMod ALT, up, moveactive, 0 -80bind = $mainMod ALT, down, moveactive, 0 80
Media and volume controls
bind = ,XF86AudioRaiseVolume,exec, pamixer -i 2bind = ,XF86AudioLowerVolume,exec, pamixer -d 2bind = ,XF86AudioMute,exec, pamixer -tbind = ,XF86AudioPlay,exec, playerctl play-pausebind = ,XF86AudioNext,exec, playerctl nextbind = ,XF86AudioPrev,exec, playerctl previousbind = , XF86AudioStop, exec, playerctl stopbind = $mainMod, mouse_down, workspace, e-1bind = $mainMod, mouse_up, workspace, e+1
Mouse binding
bindm = $mainMod, mouse:272, movewindowbindm = $mainMod, mouse:273, resizewindow
⚠️ Use this configuration at your own risk!⚠️
Applying custom configurations, especially those related to your operating system, can have unexpected consequences and may interfere with your system's normal behavior. While I have tested these configurations on my own setup, there is no guarantee that they will work flawlessly on all systems.
I am not responsible for any issues that may arise from using this configuration.
It is highly recommended to review the configuration contents and make necessary modifications to customize it to your needs before attempting the installation.
-
Install NixOs
First install NixOS using any graphical ISO image.
Only been tested using the Gnome graphical installer and choosing the
No desktopoption durring instalation. -
Clone the repo
nix-shell -p git git clone https://github.com/praktikantonelli/nixos-config cd nixos-config -
Install script
First make sure to read the install script, it isn't long
Execute and follow the installation script :
./install.shYou will need to change the git account yourself in ./modules/home/git.nix
programs.git = { ... settings.user = { name = "yourName"; email = "your.name@domain.com"; }; ... }; -
Reboot
After rebooting, you'll be greeted by swaylock prompting for your password, with the wallpaper in the background.
-
Manual config
Even though I use home manager, there is still a little bit of manual configuration to do:
- Enable Discord theme (in Discord settings under VENCORD > Themes).
- Configure the browser (for now, all browser configuration is done manually).
- Set appearance of Obsidian:
- Set the interface and text fonts to "SN Pro"
- Set the monospace font to "JetBrainsMonoNL Nerd Fonts"
-
Removing OSprober
OSprober is a tool that scans drives for alternative boot options. You need this in case you are running a dual boot setup, i.e. if you're using multiple operating sstems on one device. The problem with OSprober is that it runs every time you rebuild the system. Here's the alternative:
- Run OSprober once and reboot your system, ensuring that the boot entries actually work
- Set
boot.loader.grub.useOSprober = false; - Navigate to
/boot/grub/grub.cfgand copy any non-NixOS entry - Add the entries into
boot.loader.grub.extraEntriesas a single string
A brief walkthrough of what the install script does.
-
Get username
You will receive a prompt to enter your username, with a confirmation check.
-
Set username
The script will replace all occurancies of the default usename
CURRENT_USERNAMEby the given one stored in$username -
Create basic directories
The following directories will be created:
~/Music~/Documents~/Pictures/wallpapers/others
-
Copy the wallpapers
Then the wallpapers will be copied into
~/Pictures/wallpapers/otherswhich is the folder in which thewallpaper-picker.shscript will be looking for them. -
Get the hardware configuration
It will also automatically copy the hardware configuration from
/etc/nixos/hardware-configuration.nixto./hosts/nixos/hardware-configuration.nixso that the hardware configuration used is yours and not the default one. -
Choose a host (desktop / laptop)
Now you will need to choose the host you want. It depends on whether you are using a desktop or laptop.
-
Build the system
Finally, it will build the system, which includes both the flake config and home-manager config.
Other dotfiles that I learned/copied from:
-
Nix Flakes
- nomadics9/NixOS-Flake: This is where I started my NixOS / hyprland journey.
- samiulbasirfahim/Flakes: General flake / files structure
- justinlime/dotfiles: Mainly waybar (old design)
- skiletro/nixfiles: Vscodium config (that prevents crash)
- fufexan/dotfiles
-
README

