diff --git a/README.md b/README.md
index 20ff1ed..c02e927 100644
--- a/README.md
+++ b/README.md
@@ -1,4 +1,4 @@
-[//]: # (This is autogenerated)
+[//]: # (This file is autogenerated)
@@ -10,16 +10,16 @@
@@ -94,7 +94,7 @@ sudo nixos-rebuild switch --flake ~/.config/nixos#yourhostname
- [THEMES.md](docs/THEMES.md): How themes work and how to create your own
- [SCRIPTS.md](docs/SCRIPTS.md): Scripts that are available
-- [KEYBINDINGS.md](docs/KEYBINDINGS.md): Keybindings available in Hyprland
+- [KEYBINDINGS-HYPRLAND.md](docs/KEYBINDINGS-HYPRLAND.md): Keybindings available in Hyprland
- [WALLPAPERS.md](https://github.com/anotherhadi/nixy-wallpapers): A collection of wallpapers for Nixy.
- [TODO.md](docs/TODO.md): What's next (feel free to contribute)
diff --git a/docs/CONTRIBUTING.md b/docs/CONTRIBUTING.md
index a3fee25..53971b6 100644
--- a/docs/CONTRIBUTING.md
+++ b/docs/CONTRIBUTING.md
@@ -9,9 +9,6 @@ The process is straight-forward.
- Write your changes (new theme, bug fixes, task in to-do, ...).
- Create a Pull Request against the main branch of Nixy.
-> [!TIP]
-> When wallpapers are added, run `./docs/scripts/compress_png.sh` and `./docs/scripts/create_preview_wallpapers.sh`
-
> [!TIP]
> To update the README, change the `./docs/src/README_template.md` and run `./docs/scripts/create_readme.sh`
diff --git a/docs/KEYBINDINGS-HYPRLAND.md b/docs/KEYBINDINGS-HYPRLAND.md
new file mode 100644
index 0000000..fe7346d
--- /dev/null
+++ b/docs/KEYBINDINGS-HYPRLAND.md
@@ -0,0 +1,42 @@
+# Keybindings for Hyprland
+
+The list of the keybindings working on Hyprland:
+
+| Description | Keybinding |
+|------------------------------|--------------------------|
+| Switch Workspace | SUPER + {Number} |
+| Move app to Workspace | SHIFT + SUPER + {Number} |
+| Kitty | SUPER + RETURN |
+| Thunar | SUPER + E |
+| Qutebrowser | SUPER + B |
+| Bitwarden | SUPER + K |
+| Lock | SUPER + L |
+| Powermenu | SUPER + X |
+| Launcher | SUPER + SPACE |
+| Toggle HyprFocus | SHIFT + SUPER + SPACE |
+| Close window | SUPER + Q |
+| Toggle Floating | SUPER + T |
+| Toggle Fullscreen | SUPER + F |
+| Move focus left | SUPER + left |
+| Move focus Right | SUPER + right |
+| Move focus Up | SUPER + up |
+| Move focus Down | SUPER + down |
+| Add to master | SHIFT + SUPER + left |
+| Remove from master | SHIFT + SUPER + right |
+| Screenshot window | SUPER + PRINT |
+| Screenshot monitor | PRINT |
+| Screenshot region | SHIFT + SUPER + PRINT |
+| Screenshot region then edit | ALT PRINT |
+| Search on internet with wofi | SHIFT + SUPER + S |
+| Clipboard picker with wofi | SHIFT + SUPER + C |
+| Emoji picker with wofi | SHIFT + SUPER + E |
+| Turn off night shift | SUPER + F2 |
+| Turn on night shift | SUPER + F3 |
+| Move Window (mouse) | SUPER + mouse:272 |
+| Resize Window (mouse) | SUPER + R |
+| Toggle Mute | XF86AudioMute |
+| Lock when closing Lid | switch:Lid Switch |
+| Sound Up | XF86AudioRaiseVolume |
+| Sound Down | XF86AudioLowerVolume |
+| Brightness Up | XF86MonBrightnessUp |
+| Brightness Down | XF86MonBrightnessDown |
diff --git a/docs/KEYBINDINGS.md b/docs/KEYBINDINGS.md
deleted file mode 100644
index 740a0ec..0000000
--- a/docs/KEYBINDINGS.md
+++ /dev/null
@@ -1,42 +0,0 @@
-# Keybindings
-
-The list of the keybindings working on Hyprland:
-
-| Description | Keybinding |
-|--------------------------------------------|--------------------------|
-| Switch Workspace | SUPER + {Number} |
-| Move app to Workspace | SHIFT + SUPER + {Number} |
-| Kitty | SUPER + RETURN |
-| Thunar | SUPER + E |
-| Qutebrowser | SUPER + B |
-| Bitwarden | SUPER + K |
-| Lock | SUPER + L |
-| Powermenu | SUPER + X |
-| Launcher | SUPER + SPACE |
-| "\$shiftMod, SPACE, hyprexpo:expo, toggle" | |
-| Close window | SUPER + Q |
-| Toggle Floating | SUPER + T |
-| Toggle Fullscreen | SUPER + F |
-| Move focus left | SUPER + left |
-| Move focus Right | SUPER + right |
-| Move focus Up | SUPER + up |
-| Move focus Down | SUPER + down |
-| Add to master | SHIFT + SUPER + left |
-| Remove from master | SHIFT + SUPER + right |
-| Screenshot window | SUPER + PRINT |
-| Screenshot monitor | PRINT |
-| Screenshot region | SHIFT + SUPER + PRINT |
-| Screenshot region then edit | ALT PRINT |
-| Search on internet with wofi | SHIFT + SUPER + S |
-| Clipboard picker with wofi | SHIFT + SUPER + C |
-| Emoji picker with wofi | SHIFT + SUPER + E |
-| Turn off night shift | SUPER + F2 |
-| Turn on night shift | SUPER + F3 |
-| Move Window (mouse) | SUPER + mouse:272 |
-| Resize Window (mouse) | SUPER + R |
-| Toggle Mute | XF86AudioMute |
-| Lock when closing Lid | switch:Lid Switch |
-| Sound Up | XF86AudioRaiseVolume |
-| Sound Down | XF86AudioLowerVolume |
-| Brightness Up | XF86MonBrightnessUp |
-| Brightness Down | XF86MonBrightnessDown |
diff --git a/docs/SCRIPTS.md b/docs/SCRIPTS.md
index 213c33b..588248e 100644
--- a/docs/SCRIPTS.md
+++ b/docs/SCRIPTS.md
@@ -1,55 +1,88 @@
-# Scripts
-
-Scripts are located in the `home/scripts` folder. Home-manager add those in the user's path.
-
-## Nix/NixOs shortcuts
-
-> [!TIP]
-> The `hostname` variable in `hosts/yourhost/variables.nix` should be also the name of the `nixosConfiguration` in `flake.nix` file.
-
-- `nixy` # UI
-- `nixy rebuild`
-- `nixy update`
-- `nixy upgrade`
-- `nixy gc` # garbage collection
-- `nixy cb` # clean boot menu
-
-## Brightness control
-
-- `brightness-up`
-- `brightness-down`
-- `brightness-set [value]`
-- `brightness-change [up/down] `
-
-## Sound control
-
-- `sound-up`
-- `sound-down`
-- `sound-toggle`
-- `sound-set [value]`
-- `sound-change [up/down/mute] `
-
-## Caffeine
-
-Caffeine is a simple script that toggles hypridle (disable suspend & screenlock).
-
-- `caffeine` # Toggle caffeine
-- `caffeine-status` # Return 1/0
-- `caffeine-status-icon` # Return /
-
-## Night-Shift
-
-Blue light filter, using wlsunset
-
-- `night-shift` # Toggle night shift
-- `night-shift-status` # Return 1/0
-- `night-shift-status-icon` # Return /
-- `night-shift-on`
-- `night-shift-off`
-
-## Nerdfont FZF
-
-Nerdfont fzf is a quick way to search for nerdfont icons locally.
-It will copy the selected icon to the clipboard.
-
-- `nerdfont-fzf`
+[//]: # (This file is autogenerated)
+# Scripts
+
+Scripts are located in the 'home/scripts' folder. Home-manager add those in the user's path.
+
+## Brightness
+
+This module provides a set of scripts to control the brightness of the screen.
+
+- `brightness-up` increases the brightness by 5%.
+- `brightness-down` decreases the brightness by 5%.
+- `brightness-set [value]` sets the brightness to the given value.
+- `brightness-change [up|down] [value]` increases or decreases the brightness by the given value.
+
+## Caffeine
+
+Caffeine is a simple script that toggles hypridle (disable suspend & screenlock).
+
+- `caffeine-status` - Check if hypridle is running. (0/1)
+- `caffeine-status-icon` - Check if hypridle is running. (icon)
+- `caffeine` - Toggle hypridle.
+
+## Hyprfocus
+
+A simple script to toggle focus on few windows in Hyprland.
+(disable gaps, border, shadow, opacity, etc.)
+
+- `hyprfocus-on` - Enable hyprfocus.
+- `hyprfocus-off` - Disable hyprfocus.
+- `hyprfocus-toggle` - Toggle hyprfocus.
+
+## Hyprpanel
+
+Quick scripts to toggle, reload and kill hyprpanel.
+
+- `hyprpanel-toggle` - Toggle hyprpanel.
+- `hyprpanel-reload` - Reload hyprpanel.
+- `hyprpanel-kill` - Kill hyprpanel.
+
+## Nerdfont FZF
+
+This module provides a script to search for Nerd Fonts icons using fzf.
+
+- `nerdfont-fzf` - Search for Nerd Fonts icons using fzf.
+
+## Night-Shift
+
+Night-Shift is a feature that reduces the amount of blue light emitted by your screen, which can help reduce eye strain and improve sleep quality. This module provides a set of scripts to control Night-Shift on your system.
+
+- `night-shift-on` activates Night-Shift.
+- `night-shift-off` deactivates Night-Shift.
+- `night-shift` toggles Night-Shift.
+- `night-shift-status` checks if Night-Shift is active. (0/1)
+- `night-shift-status-icon` checks if Night-Shift is active. (icon)
+
+## Nixy
+
+Nixy is a simple script that I use to manage my NixOS system. It's a simple script that provides a menu to rebuild, upgrade, update, collect garbage, clean boot menu, etc.
+
+- `nixy` - UI wizard to manage the system.
+- `nixy rebuild` - Rebuild the system.
+- `nixy ...` - ... see the script for more commands.
+
+
+
+## Screenshot
+
+This module provides a script to take screenshots using `hyprshot` and `swappy`.
+
+- `screenshot [region|window|monitor] [swappy]` - Take a screenshot of the region, window, or monitor. Optionally, use `swappy` to copy the screenshot to the clipboard.
+
+## Sound
+
+This module provides a set of scripts to control the volume of the default audio sink using `wpctl`.
+
+- `sound-up` increases the volume by 5%.
+- `sound-down` decreases the volume by 5%.
+- `sound-set [value]` sets the volume to the given value.
+- `sound-toggle` toggles the mute state of the default audio sink.
+
+## System
+
+Usefull quick scripts
+
+- `menu` - Open wofi with drun mode.
+- `powermenu` - Open power dropdown menu.
+- `lock` - Lock the screen.
+
diff --git a/docs/scripts/create_readme.sh b/docs/scripts/create_readme.sh
index 3da3ef1..0997c83 100644
--- a/docs/scripts/create_readme.sh
+++ b/docs/scripts/create_readme.sh
@@ -10,8 +10,8 @@ table_of_content=$(md-table-of-contents ./docs/src/README_template.md) # https:/
readme_content=$(cat "./docs/src/README_template.md")
# Replace variables
-readme_content=${readme_content//\{primarycolor\}/89b4fa}
-readme_content=${readme_content//\{backgroundcolor\}/181825}
+readme_content=${readme_content//\{primarycolor\}/A594FD}
+readme_content=${readme_content//\{backgroundcolor\}/0b0b0b}
readme_content=${readme_content//\{md_table_of_content\}/$table_of_content}
echo "[//]: # (This file is autogenerated)" >"$README_FILE"
diff --git a/docs/scripts/create_scripts_docs.sh b/docs/scripts/create_scripts_docs.sh
new file mode 100644
index 0000000..10353d2
--- /dev/null
+++ b/docs/scripts/create_scripts_docs.sh
@@ -0,0 +1,26 @@
+#!/usr/bin/env bash
+
+[[ -d "./docs" ]] || (echo "Folder ./docs not found" && exit 1)
+
+DOCS_FILE="./docs/SCRIPTS.md"
+SCRIPTS_FOLDER="./home/scripts"
+
+# search for every directory in the scripts folder:
+# The docs for each scripts are in the beginning of the file prefixed by "#-" or "# -" for the title
+# Inside the folders, the scripts are stored in default.nix files
+echo "[//]: # (This file is autogenerated)" >"$DOCS_FILE"
+echo "# Scripts" >>"$DOCS_FILE"
+echo "" >>"$DOCS_FILE"
+echo "Scripts are located in the 'home/scripts' folder. Home-manager add those in the user's path." >>"$DOCS_FILE"
+echo "" >>"$DOCS_FILE"
+
+for folder in "$SCRIPTS_FOLDER"/*; do
+ script="$folder/default.nix"
+ [[ -f "$script" ]] || continue
+
+ content=$(cat "$script")
+ content=$(echo "$content" | grep -E "^#-|^# -" | sed 's/^#- //;s/^# - //;s/#-//')
+
+ echo "$content" >>"$DOCS_FILE"
+ echo "" >>"$DOCS_FILE"
+done
diff --git a/docs/scripts/keybindings_to_markdown.sh b/docs/scripts/keybindings_to_markdown.sh
index c4a9c52..a4b9aa8 100644
--- a/docs/scripts/keybindings_to_markdown.sh
+++ b/docs/scripts/keybindings_to_markdown.sh
@@ -4,7 +4,7 @@
[[ -d "./docs" ]] || (echo "Folder ./docs not found" && exit 1)
-KEYBINDINGS_FILE="./docs/KEYBINDINGS.md"
+KEYBINDINGS_FILE="./docs/KEYBINDINGS-HYPRLAND.md"
function getList() {
content=$1
@@ -33,7 +33,8 @@ bindle=$(getList "$config" "bindle")
# Join the lists:
keybindings=$(echo -e "$bind\n$bindm\n$bindl\n$bindle" | grep '"')
-echo "# Keybindings" >"$KEYBINDINGS_FILE"
+echo "[//]: # (This file is autogenerated)" >"$KEYBINDINGS_FILE"
+echo "# Keybindings for Hyprland" >>"$KEYBINDINGS_FILE"
echo "" >>"$KEYBINDINGS_FILE"
echo "The list of the keybindings working on Hyprland:" >>"$KEYBINDINGS_FILE"
echo "" >>"$KEYBINDINGS_FILE"
diff --git a/docs/src/README_template.md b/docs/src/README_template.md
index b3b150b..2abdd23 100644
--- a/docs/src/README_template.md
+++ b/docs/src/README_template.md
@@ -84,7 +84,7 @@ sudo nixos-rebuild switch --flake ~/.config/nixos#yourhostname
- [THEMES.md](docs/THEMES.md): How themes work and how to create your own
- [SCRIPTS.md](docs/SCRIPTS.md): Scripts that are available
-- [KEYBINDINGS.md](docs/KEYBINDINGS.md): Keybindings available in Hyprland
+- [KEYBINDINGS-HYPRLAND.md](docs/KEYBINDINGS-HYPRLAND.md): Keybindings available in Hyprland
- [WALLPAPERS.md](https://github.com/anotherhadi/nixy-wallpapers): A collection of wallpapers for Nixy.
- [TODO.md](docs/TODO.md): What's next (feel free to contribute)
diff --git a/home/programs/nvim/keymaps.nix b/home/programs/nvim/keymaps.nix
index 6e50ea6..b06aba7 100644
--- a/home/programs/nvim/keymaps.nix
+++ b/home/programs/nvim/keymaps.nix
@@ -62,7 +62,7 @@
}
{
key = "E";
- action = "Neotree";
+ action = "Neotree toggle";
options.desc = "Neotree";
}
diff --git a/home/scripts/brightness/default.nix b/home/scripts/brightness/default.nix
index 98efc20..bfab164 100644
--- a/home/scripts/brightness/default.nix
+++ b/home/scripts/brightness/default.nix
@@ -1,3 +1,12 @@
+# - ## Brightness
+#-
+#- This module provides a set of scripts to control the brightness of the screen.
+#-
+#- - `brightness-up` increases the brightness by 5%.
+#- - `brightness-down` decreases the brightness by 5%.
+#- - `brightness-set [value]` sets the brightness to the given value.
+#- - `brightness-change [up|down] [value]` increases or decreases the brightness by the given value.
+
{ pkgs, ... }:
let
diff --git a/home/scripts/caffeine/default.nix b/home/scripts/caffeine/default.nix
index 675fea0..bbd1a89 100644
--- a/home/scripts/caffeine/default.nix
+++ b/home/scripts/caffeine/default.nix
@@ -1,3 +1,11 @@
+# - ## Caffeine
+#-
+#- Caffeine is a simple script that toggles hypridle (disable suspend & screenlock).
+#-
+#- - `caffeine-status` - Check if hypridle is running. (0/1)
+#- - `caffeine-status-icon` - Check if hypridle is running. (icon)
+#- - `caffeine` - Toggle hypridle.
+
{ pkgs, ... }:
let
caffeine-status = pkgs.writeShellScriptBin "caffeine-status" ''
diff --git a/home/scripts/hyprfocus/default.nix b/home/scripts/hyprfocus/default.nix
index bfb72e0..30e6697 100644
--- a/home/scripts/hyprfocus/default.nix
+++ b/home/scripts/hyprfocus/default.nix
@@ -1,3 +1,11 @@
+# - ## Hyprfocus
+#-
+#- A simple script to toggle focus on few windows in Hyprland.
+#- (disable gaps, border, shadow, opacity, etc.)
+#-
+#- - `hyprfocus-on` - Enable hyprfocus.
+#- - `hyprfocus-off` - Disable hyprfocus.
+#- - `hyprfocus-toggle` - Toggle hyprfocus.
{ pkgs, ... }:
let
hyprfocus-on = pkgs.writeShellScriptBin "hyprfocus-on"
diff --git a/home/scripts/hyprpanel/default.nix b/home/scripts/hyprpanel/default.nix
index 932abed..8f62e20 100644
--- a/home/scripts/hyprpanel/default.nix
+++ b/home/scripts/hyprpanel/default.nix
@@ -1,3 +1,10 @@
+# - ## Hyprpanel
+#-
+#- Quick scripts to toggle, reload and kill hyprpanel.
+#-
+#- - `hyprpanel-toggle` - Toggle hyprpanel.
+#- - `hyprpanel-reload` - Reload hyprpanel.
+#- - `hyprpanel-kill` - Kill hyprpanel.
{ pkgs, ... }:
let
hyprpanel-toggle = pkgs.writeShellScriptBin "hyprpanel-toggle" ''
diff --git a/home/scripts/nerdfont_fzf/default.nix b/home/scripts/nerdfont_fzf/default.nix
index d23c42b..84455ba 100644
--- a/home/scripts/nerdfont_fzf/default.nix
+++ b/home/scripts/nerdfont_fzf/default.nix
@@ -1,3 +1,8 @@
+# - ## Nerdfont FZF
+#-
+#- This module provides a script to search for Nerd Fonts icons using fzf.
+#-
+#- - `nerdfont-fzf` - Search for Nerd Fonts icons using fzf.
{ pkgs, config, ... }:
let
homedir = config.home.homeDirectory;
diff --git a/home/scripts/night-shift/default.nix b/home/scripts/night-shift/default.nix
index 7462854..ad85f89 100644
--- a/home/scripts/night-shift/default.nix
+++ b/home/scripts/night-shift/default.nix
@@ -1,3 +1,12 @@
+# - ## Night-Shift
+#-
+#- Night-Shift is a feature that reduces the amount of blue light emitted by your screen, which can help reduce eye strain and improve sleep quality. This module provides a set of scripts to control Night-Shift on your system.
+#-
+#- - `night-shift-on` activates Night-Shift.
+#- - `night-shift-off` deactivates Night-Shift.
+#- - `night-shift` toggles Night-Shift.
+#- - `night-shift-status` checks if Night-Shift is active. (0/1)
+#- - `night-shift-status-icon` checks if Night-Shift is active. (icon)
{ pkgs, ... }:
let
diff --git a/home/scripts/nixy/default.nix b/home/scripts/nixy/default.nix
index c3facc0..3e39fe3 100644
--- a/home/scripts/nixy/default.nix
+++ b/home/scripts/nixy/default.nix
@@ -1,55 +1,65 @@
+# - ## Nixy
+#-
+#- Nixy is a simple script that I use to manage my NixOS system. It's a simple script that provides a menu to rebuild, upgrade, update, collect garbage, clean boot menu, etc.
+#-
+#- - `nixy` - UI wizard to manage the system.
+#- - `nixy rebuild` - Rebuild the system.
+#- - `nixy ...` - ... see the script for more commands.
{ pkgs, config, ... }:
let
- nixy = pkgs.writeShellScriptBin "nixy" ''
- function exec() {
- $@
- }
+ nixy = pkgs.writeShellScriptBin "nixy"
+ # bash
+ ''
+ function exec() {
+ $@
+ }
- function ui(){
- DEFAULT_ICON=""
+ function ui(){
+ DEFAULT_ICON=""
- # "icon;name;command"[]
- apps=(
- ";Rebuild;nixy rebuild"
- ";Upgrade;nixy upgrade"
- ";Update;nixy update"
- ";Collect Garbage;nixy gc"
- ";Clean Boot Menu;nixy cb"
- )
+ # "icon;name;command"[]
+ apps=(
+ ";Rebuild;nixy rebuild"
+ ";Upgrade;nixy upgrade"
+ ";Update;nixy update"
+ ";Collect Garbage;nixy gc"
+ ";Clean Boot Menu;nixy cb"
+ " ;Hyprland Keybindings;nvim ${config.var.configDirectory}/docs/KEYBINDINGS-HYPRLAND.md"
+ )
- # Apply default icons if empty:
- for i in "''${!apps[@]}"; do
- apps[i]=$(echo "''${apps[i]}" | sed 's/^;/'$DEFAULT_ICON';/')
- done
+ # Apply default icons if empty:
+ for i in "''${!apps[@]}"; do
+ apps[i]=$(echo "''${apps[i]}" | sed 's/^;/'$DEFAULT_ICON';/')
+ done
- fzf_result=$(printf "%s\n" "''${apps[@]}" | awk -F ';' '{print $1" "$2}' | fzf)
- [[ -z $fzf_result ]] && exit 0
- fzf_result=''${fzf_result/ /;}
- line=$(printf "%s\n" "''${apps[@]}" | grep "$fzf_result")
- command=$(echo "$line" | sed 's/^[^;]*;//;s/^[^;]*;//')
+ fzf_result=$(printf "%s\n" "''${apps[@]}" | awk -F ';' '{print $1" "$2}' | fzf)
+ [[ -z $fzf_result ]] && exit 0
+ fzf_result=''${fzf_result/ /;}
+ line=$(printf "%s\n" "''${apps[@]}" | grep "$fzf_result")
+ command=$(echo "$line" | sed 's/^[^;]*;//;s/^[^;]*;//')
- exec "$command"
- exit 0
- }
+ exec "$command"
+ exit 0
+ }
- [[ $1 == "" ]] && ui
+ [[ $1 == "" ]] && ui
- if [[ $1 == "rebuild" ]];then
- sudo nixos-rebuild switch --flake ${config.var.configDirectory}#${config.var.hostname}
- elif [[ $1 == "upgrade" ]];then
- sudo nixos-rebuild switch --upgrade --flake ${config.var.configDirectory}#${config.var.hostname}
- elif [[ $1 == "update" ]];then
- cd ${config.var.configDirectory} && nix flake update
- elif [[ $1 == "gc" ]];then
- cd ${config.var.configDirectory} && sudo nix-collect-garbage -d
- elif [[ $1 == "cb" ]];then
- sudo /run/current-system/bin/switch-to-configuration boot
- elif [[ $1 == "remote" ]];then
- cd ~/.config/nixos && git add . && git commit -m "update" && git push
- ssh jack -S -C "cd /home/hadi/.config/nixos && git pull && sudo -S nixos-rebuild switch --flake ~/.config/nixos#jack"
- else
- echo "Unknown argument"
- fi
- '';
+ if [[ $1 == "rebuild" ]];then
+ sudo nixos-rebuild switch --flake ${config.var.configDirectory}#${config.var.hostname}
+ elif [[ $1 == "upgrade" ]];then
+ sudo nixos-rebuild switch --upgrade --flake ${config.var.configDirectory}#${config.var.hostname}
+ elif [[ $1 == "update" ]];then
+ cd ${config.var.configDirectory} && nix flake update
+ elif [[ $1 == "gc" ]];then
+ cd ${config.var.configDirectory} && sudo nix-collect-garbage -d
+ elif [[ $1 == "cb" ]];then
+ sudo /run/current-system/bin/switch-to-configuration boot
+ elif [[ $1 == "remote" ]];then
+ cd ~/.config/nixos && git add . && git commit -m "update" && git push
+ ssh jack -S -C "cd /home/hadi/.config/nixos && git pull && sudo -S nixos-rebuild switch --flake ~/.config/nixos#jack"
+ else
+ echo "Unknown argument"
+ fi
+ '';
in { home.packages = [ nixy ]; }
diff --git a/home/scripts/screenshot/default.nix b/home/scripts/screenshot/default.nix
index ebd9dbe..0610f97 100644
--- a/home/scripts/screenshot/default.nix
+++ b/home/scripts/screenshot/default.nix
@@ -1,5 +1,9 @@
+# - ## Screenshot
+#-
+#- This module provides a script to take screenshots using `hyprshot` and `swappy`.
+#-
+#- - `screenshot [region|window|monitor] [swappy]` - Take a screenshot of the region, window, or monitor. Optionally, use `swappy` to copy the screenshot to the clipboard.
{ pkgs, ... }:
-
let
screenshot = pkgs.writeShellScriptBin "screenshot" ''
if [[ $2 == "swappy" ]];then
diff --git a/home/scripts/sounds/default.nix b/home/scripts/sounds/default.nix
index 02e1673..c3ca7d0 100644
--- a/home/scripts/sounds/default.nix
+++ b/home/scripts/sounds/default.nix
@@ -1,3 +1,11 @@
+# - ## Sound
+#-
+#- This module provides a set of scripts to control the volume of the default audio sink using `wpctl`.
+#-
+#- - `sound-up` increases the volume by 5%.
+#- - `sound-down` decreases the volume by 5%.
+#- - `sound-set [value]` sets the volume to the given value.
+#- - `sound-toggle` toggles the mute state of the default audio sink.
{ pkgs, ... }:
let
diff --git a/home/scripts/system/default.nix b/home/scripts/system/default.nix
index b7713c7..f251626 100644
--- a/home/scripts/system/default.nix
+++ b/home/scripts/system/default.nix
@@ -1,3 +1,10 @@
+# - ## System
+#-
+#- Usefull quick scripts
+#-
+#- - `menu` - Open wofi with drun mode.
+#- - `powermenu` - Open power dropdown menu.
+#- - `lock` - Lock the screen.
{ pkgs, ... }:
let