forked from KptltD00M/nixy
Merge pull request 'feat/waybar' (#2) from feat/waybar into feat/gaming
Reviewed-on: KptltD00M/nixy#2
This commit is contained in:
@@ -1,223 +0,0 @@
|
|||||||
# ThinkPad NixOS Installation Guide
|
|
||||||
|
|
||||||
This guide provides step-by-step instructions for installing the NixOS configuration on your ThinkPad laptop.
|
|
||||||
|
|
||||||
## Prerequisites
|
|
||||||
|
|
||||||
- **ThinkPad laptop** (tested models: T480, T490, X1 Carbon)
|
|
||||||
- **USB flash drive** (8GB+ recommended)
|
|
||||||
- **Backup your data** - this will erase everything on the target device
|
|
||||||
- **NixOS ISO** - Download from [nixos.org](https://nixos.org/download.html)
|
|
||||||
- **Internet connection** (wired recommended for initial setup)
|
|
||||||
|
|
||||||
## Preparation
|
|
||||||
|
|
||||||
### 1. Create NixOS Installation Media
|
|
||||||
|
|
||||||
```bash
|
|
||||||
# On another Linux machine or macOS:
|
|
||||||
sudo dd if=nixos-minimal-*.iso of=/dev/sdX bs=4M status=progress oflag=sync
|
|
||||||
# Replace /dev/sdX with your USB device (e.g., /dev/sdb)
|
|
||||||
# WARNING: This will erase the target device completely
|
|
||||||
```
|
|
||||||
|
|
||||||
### 2. Boot from USB
|
|
||||||
|
|
||||||
1. Insert USB drive into ThinkPad
|
|
||||||
2. Power on and press **F12** to enter boot menu
|
|
||||||
3. Select the USB drive
|
|
||||||
4. At GRUB menu, select "NixOS"
|
|
||||||
|
|
||||||
## Installation Steps
|
|
||||||
|
|
||||||
### 3. Prepare Disks
|
|
||||||
|
|
||||||
```bash
|
|
||||||
# Identify your disk (likely /dev/nvme0n1 for NVMe SSDs)
|
|
||||||
lsblk
|
|
||||||
|
|
||||||
# Partition the disk (adjust for your needs)
|
|
||||||
sudo gdisk /dev/nvme0n1
|
|
||||||
# Use: o (create new GPT), n (new partition), accept defaults for EFI (512M), then Linux filesystem (rest)
|
|
||||||
# Set type for EFI to EF00, Linux filesystem to 8300
|
|
||||||
# Write changes with w
|
|
||||||
```
|
|
||||||
|
|
||||||
### 4. Format Partitions
|
|
||||||
|
|
||||||
```bash
|
|
||||||
# Format EFI partition
|
|
||||||
sudo mkfs.fat -F32 /dev/nvme0n1p1
|
|
||||||
|
|
||||||
# Format root partition
|
|
||||||
sudo mkfs.ext4 /dev/nvme0n1p2
|
|
||||||
|
|
||||||
# Mount partitions
|
|
||||||
sudo mount /dev/nvme0n1p2 /mnt
|
|
||||||
sudo mkdir -p /mnt/boot/efi
|
|
||||||
sudo mount /dev/nvme0n1p1 /mnt/boot/efi
|
|
||||||
```
|
|
||||||
|
|
||||||
### 5. Generate NixOS Configuration
|
|
||||||
|
|
||||||
```bash
|
|
||||||
# Generate initial configuration
|
|
||||||
sudo nixos-generate-config --root /mnt
|
|
||||||
|
|
||||||
# This creates /mnt/etc/nixos/configuration.nix and hardware-configuration.nix
|
|
||||||
```
|
|
||||||
|
|
||||||
### 6. Clone Your Nixy Configuration
|
|
||||||
|
|
||||||
```bash
|
|
||||||
# Clone your nixy repository
|
|
||||||
sudo nix-shell -p git
|
|
||||||
git clone https://gitea.doomlabs.de/KptltD00M/nixy.git /mnt/etc/nixos/nixy
|
|
||||||
cd /mnt/etc/nixos/nixy
|
|
||||||
|
|
||||||
# Copy hardware configuration
|
|
||||||
sudo cp /mnt/etc/nixos/hardware-configuration.nix hosts/laptop/hardware-configuration.nix
|
|
||||||
```
|
|
||||||
|
|
||||||
### 7. Install NixOS
|
|
||||||
|
|
||||||
```bash
|
|
||||||
# Switch to your laptop configuration
|
|
||||||
sudo nixos-install --flake /mnt/etc/nixos/nixy#laptop
|
|
||||||
|
|
||||||
# When prompted, set a root password
|
|
||||||
```
|
|
||||||
|
|
||||||
### 8. Post-Installation
|
|
||||||
|
|
||||||
```bash
|
|
||||||
# After reboot, log in as root
|
|
||||||
# Clone your configuration to your user
|
|
||||||
git clone https://gitea.doomlabs.de/KptltD00M/nixy.git ~/nixy
|
|
||||||
cd ~/nixy
|
|
||||||
|
|
||||||
# Switch to your user configuration
|
|
||||||
nix run nixpkgs#home-manager -- switch --flake .#andi@laptop
|
|
||||||
|
|
||||||
# Reboot
|
|
||||||
reboot
|
|
||||||
```
|
|
||||||
|
|
||||||
## ThinkPad-Specific Configuration
|
|
||||||
|
|
||||||
### 1. Trackpad Configuration
|
|
||||||
|
|
||||||
The configuration includes touchpad settings optimized for ThinkPad hardware. If you need to adjust:
|
|
||||||
|
|
||||||
```nix
|
|
||||||
# Edit hosts/laptop/home.nix
|
|
||||||
programs.hyprland = {
|
|
||||||
touchpad = {
|
|
||||||
naturalScroll = true;
|
|
||||||
tap-to-click = true;
|
|
||||||
disableWhileTyping = false;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
```
|
|
||||||
|
|
||||||
### 2. Keyboard Backlight
|
|
||||||
|
|
||||||
```bash
|
|
||||||
# Enable keyboard backlight control
|
|
||||||
sudo nix-env -iA nixos.hid-tools
|
|
||||||
sudo systemctl enable --now thinkpad-keyboard-backlight.service
|
|
||||||
```
|
|
||||||
|
|
||||||
### 3. Power Management
|
|
||||||
|
|
||||||
```bash
|
|
||||||
# Install TLP for better power management
|
|
||||||
sudo nix-env -iA nixos.tlp
|
|
||||||
sudo systemctl enable --now tlp
|
|
||||||
```
|
|
||||||
|
|
||||||
## Troubleshooting
|
|
||||||
|
|
||||||
### Common Issues
|
|
||||||
|
|
||||||
**1. WiFi not working:**
|
|
||||||
```bash
|
|
||||||
# Install firmware for your WiFi card
|
|
||||||
sudo nix-env -iA nixos.firmware
|
|
||||||
```
|
|
||||||
|
|
||||||
**2. Suspend/resume issues:**
|
|
||||||
```bash
|
|
||||||
# Edit hardware-configuration.nix
|
|
||||||
boot.kernelPackages = pkgs.linuxPackages_latest;
|
|
||||||
```
|
|
||||||
|
|
||||||
**3. Screen tearing:**
|
|
||||||
```bash
|
|
||||||
# Enable TearFree in hosts/laptop/configuration.nix
|
|
||||||
services.xserver.videoDrivers = [ "modesetting" ];
|
|
||||||
```
|
|
||||||
|
|
||||||
### Debugging Commands
|
|
||||||
|
|
||||||
```bash
|
|
||||||
# Check hardware detection
|
|
||||||
sudo dmesg | grep -i thinkpad
|
|
||||||
|
|
||||||
# Check battery status
|
|
||||||
upower -i /org/freedesktop/UPower/devices/battery_BAT0
|
|
||||||
|
|
||||||
# Check display configuration
|
|
||||||
hyprctl monitors
|
|
||||||
```
|
|
||||||
|
|
||||||
## Maintenance
|
|
||||||
|
|
||||||
### Updating Your System
|
|
||||||
|
|
||||||
```bash
|
|
||||||
# Update flake inputs
|
|
||||||
nix flake update
|
|
||||||
|
|
||||||
# Rebuild system
|
|
||||||
sudo nixos-rebuild switch --flake ~/nixy#laptop
|
|
||||||
|
|
||||||
# Rebuild home configuration
|
|
||||||
nix run nixpkgs#home-manager -- switch --flake ~/nixy#andi@laptop
|
|
||||||
```
|
|
||||||
|
|
||||||
### Backup Configuration
|
|
||||||
|
|
||||||
```bash
|
|
||||||
# Backup your hardware configuration
|
|
||||||
cp /etc/nixos/hardware-configuration.nix ~/nixy/hosts/laptop/
|
|
||||||
|
|
||||||
# Commit changes
|
|
||||||
cd ~/nixy
|
|
||||||
git add .
|
|
||||||
git commit -m "Update hardware config for ThinkPad"
|
|
||||||
git push
|
|
||||||
```
|
|
||||||
|
|
||||||
## Additional Resources
|
|
||||||
|
|
||||||
- [NixOS Manual](https://nixos.org/manual/nixos/stable/)
|
|
||||||
- [ThinkPad Wiki](https://www.thinkwiki.org/)
|
|
||||||
- [NixOS Discourse](https://discourse.nixos.org/)
|
|
||||||
|
|
||||||
## Notes
|
|
||||||
|
|
||||||
- **ThinkPad T480/X1 Carbon specific:** These models have excellent Linux support. The configuration includes:
|
|
||||||
- Trackpoint acceleration settings
|
|
||||||
- Keyboard backlight control
|
|
||||||
- Power management profiles
|
|
||||||
- Display brightness controls
|
|
||||||
- Suspend/resume fixes
|
|
||||||
|
|
||||||
- **Encryption:** If you enabled encryption during install, use:
|
|
||||||
```bash
|
|
||||||
sudo cryptsetup luksOpen /dev/nvme0n1p2 cryptroot
|
|
||||||
sudo mount /dev/mapper/cryptroot /mnt
|
|
||||||
```
|
|
||||||
|
|
||||||
- **Multi-boot:** If dual-booting with Windows, ensure Secure Boot is disabled in BIOS.
|
|
||||||
Generated
-137
@@ -213,98 +213,6 @@
|
|||||||
"type": "github"
|
"type": "github"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"caelestia-cli": {
|
|
||||||
"inputs": {
|
|
||||||
"caelestia-shell": "caelestia-shell",
|
|
||||||
"nixpkgs": [
|
|
||||||
"nixpkgs"
|
|
||||||
]
|
|
||||||
},
|
|
||||||
"locked": {
|
|
||||||
"lastModified": 1780375472,
|
|
||||||
"narHash": "sha256-Q8RAJoYlakA6B2I5DVcuxzNbhCNU1nnIjqQZYP1KGrM=",
|
|
||||||
"owner": "caelestia-dots",
|
|
||||||
"repo": "cli",
|
|
||||||
"rev": "d1c8c8fc09738d1b40576e97c274b4a11a2e0ac7",
|
|
||||||
"type": "github"
|
|
||||||
},
|
|
||||||
"original": {
|
|
||||||
"owner": "caelestia-dots",
|
|
||||||
"repo": "cli",
|
|
||||||
"type": "github"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"caelestia-cli_2": {
|
|
||||||
"inputs": {
|
|
||||||
"caelestia-shell": [
|
|
||||||
"caelestia-shell"
|
|
||||||
],
|
|
||||||
"nixpkgs": [
|
|
||||||
"caelestia-shell",
|
|
||||||
"nixpkgs"
|
|
||||||
]
|
|
||||||
},
|
|
||||||
"locked": {
|
|
||||||
"lastModified": 1779768519,
|
|
||||||
"narHash": "sha256-2n/447oNfAZrl1yncafLPgXMx5tuTF6T2B+zI/zFYkI=",
|
|
||||||
"owner": "caelestia-dots",
|
|
||||||
"repo": "cli",
|
|
||||||
"rev": "64a5507e74f6c7d0c29f9131964412f8f8c4dd89",
|
|
||||||
"type": "github"
|
|
||||||
},
|
|
||||||
"original": {
|
|
||||||
"owner": "caelestia-dots",
|
|
||||||
"repo": "cli",
|
|
||||||
"type": "github"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"caelestia-shell": {
|
|
||||||
"inputs": {
|
|
||||||
"caelestia-cli": [
|
|
||||||
"caelestia-cli"
|
|
||||||
],
|
|
||||||
"nixpkgs": [
|
|
||||||
"caelestia-cli",
|
|
||||||
"nixpkgs"
|
|
||||||
],
|
|
||||||
"quickshell": "quickshell"
|
|
||||||
},
|
|
||||||
"locked": {
|
|
||||||
"lastModified": 1780196414,
|
|
||||||
"narHash": "sha256-iXmyWULTZuRd68xRL79e9GyYL9FZ6gfh6zl1PPlWX2A=",
|
|
||||||
"owner": "caelestia-dots",
|
|
||||||
"repo": "shell",
|
|
||||||
"rev": "63bb82762bb29ac9b7fcd5b97839abae721ce860",
|
|
||||||
"type": "github"
|
|
||||||
},
|
|
||||||
"original": {
|
|
||||||
"owner": "caelestia-dots",
|
|
||||||
"repo": "shell",
|
|
||||||
"type": "github"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"caelestia-shell_2": {
|
|
||||||
"inputs": {
|
|
||||||
"caelestia-cli": "caelestia-cli_2",
|
|
||||||
"nixpkgs": [
|
|
||||||
"nixpkgs"
|
|
||||||
],
|
|
||||||
"quickshell": "quickshell_2"
|
|
||||||
},
|
|
||||||
"locked": {
|
|
||||||
"lastModified": 1780196414,
|
|
||||||
"narHash": "sha256-iXmyWULTZuRd68xRL79e9GyYL9FZ6gfh6zl1PPlWX2A=",
|
|
||||||
"owner": "caelestia-dots",
|
|
||||||
"repo": "shell",
|
|
||||||
"rev": "63bb82762bb29ac9b7fcd5b97839abae721ce860",
|
|
||||||
"type": "github"
|
|
||||||
},
|
|
||||||
"original": {
|
|
||||||
"owner": "caelestia-dots",
|
|
||||||
"repo": "shell",
|
|
||||||
"type": "github"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"crane": {
|
"crane": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1779130139,
|
"lastModified": 1779130139,
|
||||||
@@ -1660,55 +1568,10 @@
|
|||||||
"type": "github"
|
"type": "github"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"quickshell": {
|
|
||||||
"inputs": {
|
|
||||||
"nixpkgs": [
|
|
||||||
"caelestia-cli",
|
|
||||||
"caelestia-shell",
|
|
||||||
"nixpkgs"
|
|
||||||
]
|
|
||||||
},
|
|
||||||
"locked": {
|
|
||||||
"lastModified": 1779430452,
|
|
||||||
"narHash": "sha256-zTslhsxLqUlRTML506iougTGzyR38Fzhzn7t4KDEuuE=",
|
|
||||||
"ref": "refs/heads/master",
|
|
||||||
"rev": "4b4fca3224ab977dc515ac0bb78d00b3dfa71e00",
|
|
||||||
"revCount": 819,
|
|
||||||
"type": "git",
|
|
||||||
"url": "https://git.outfoxxed.me/outfoxxed/quickshell"
|
|
||||||
},
|
|
||||||
"original": {
|
|
||||||
"type": "git",
|
|
||||||
"url": "https://git.outfoxxed.me/outfoxxed/quickshell"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"quickshell_2": {
|
|
||||||
"inputs": {
|
|
||||||
"nixpkgs": [
|
|
||||||
"caelestia-shell",
|
|
||||||
"nixpkgs"
|
|
||||||
]
|
|
||||||
},
|
|
||||||
"locked": {
|
|
||||||
"lastModified": 1779430452,
|
|
||||||
"narHash": "sha256-zTslhsxLqUlRTML506iougTGzyR38Fzhzn7t4KDEuuE=",
|
|
||||||
"ref": "refs/heads/master",
|
|
||||||
"rev": "4b4fca3224ab977dc515ac0bb78d00b3dfa71e00",
|
|
||||||
"revCount": 819,
|
|
||||||
"type": "git",
|
|
||||||
"url": "https://git.outfoxxed.me/outfoxxed/quickshell"
|
|
||||||
},
|
|
||||||
"original": {
|
|
||||||
"type": "git",
|
|
||||||
"url": "https://git.outfoxxed.me/outfoxxed/quickshell"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"root": {
|
"root": {
|
||||||
"inputs": {
|
"inputs": {
|
||||||
"awesome-wallpapers": "awesome-wallpapers",
|
"awesome-wallpapers": "awesome-wallpapers",
|
||||||
"blog": "blog",
|
"blog": "blog",
|
||||||
"caelestia-cli": "caelestia-cli",
|
|
||||||
"caelestia-shell": "caelestia-shell_2",
|
|
||||||
"default-creds": "default-creds",
|
"default-creds": "default-creds",
|
||||||
"helium-browser": "helium-browser",
|
"helium-browser": "helium-browser",
|
||||||
"home-manager": "home-manager",
|
"home-manager": "home-manager",
|
||||||
|
|||||||
@@ -28,14 +28,7 @@
|
|||||||
url = "github:nix-community/home-manager";
|
url = "github:nix-community/home-manager";
|
||||||
inputs.nixpkgs.follows = "nixpkgs";
|
inputs.nixpkgs.follows = "nixpkgs";
|
||||||
};
|
};
|
||||||
caelestia-shell = {
|
|
||||||
url = "github:caelestia-dots/shell";
|
|
||||||
inputs.nixpkgs.follows = "nixpkgs";
|
|
||||||
};
|
|
||||||
caelestia-cli = {
|
|
||||||
url = "github:caelestia-dots/cli";
|
|
||||||
inputs.nixpkgs.follows = "nixpkgs";
|
|
||||||
};
|
|
||||||
|
|
||||||
# Server
|
# Server
|
||||||
nixarr.url = "github:rasmus-kirk/nixarr";
|
nixarr.url = "github:rasmus-kirk/nixarr";
|
||||||
|
|||||||
@@ -26,6 +26,9 @@
|
|||||||
pkgs.wifitui # TUI for managing wifi
|
pkgs.wifitui # TUI for managing wifi
|
||||||
pkgs-nur-hadi.usbguard-tui # TUI for managing USBGuard rules
|
pkgs-nur-hadi.usbguard-tui # TUI for managing USBGuard rules
|
||||||
|
|
||||||
|
blueman # Bluetooth manager (blueman-manager, blueman-adapters, blueman-sendto)
|
||||||
|
bluez # Bluetooth stack tools (bluetoothctl)
|
||||||
|
|
||||||
|
|
||||||
# I love CLIs
|
# I love CLIs
|
||||||
httpie # Command-line HTTP client, a user-friendly cURL replacement
|
httpie # Command-line HTTP client, a user-friendly cURL replacement
|
||||||
|
|||||||
@@ -91,14 +91,13 @@ in {
|
|||||||
"$mod,B, exec, uwsm app -- ${config.programs.librewolf.package}/bin/helium" # Browser
|
"$mod,B, exec, uwsm app -- ${config.programs.librewolf.package}/bin/helium" # Browser
|
||||||
|
|
||||||
# Power
|
# Power
|
||||||
"$mod, X, global, caelestia:session" # Powermenu
|
|
||||||
(
|
(
|
||||||
"$shiftMod, X, exec, "
|
"$mod, X, exec, "
|
||||||
+ lib.getExe (mkMenu [
|
+ lib.getExe (mkMenu [
|
||||||
{
|
{
|
||||||
key = "l";
|
key = "l";
|
||||||
desc = "Lock";
|
desc = "Lock";
|
||||||
cmd = "hyprctl dispatch global caelestia:lock";
|
cmd = "loginctl lock-session";
|
||||||
}
|
}
|
||||||
{
|
{
|
||||||
key = "s";
|
key = "s";
|
||||||
@@ -122,8 +121,8 @@ in {
|
|||||||
}
|
}
|
||||||
{
|
{
|
||||||
key = "c";
|
key = "c";
|
||||||
desc = "Restart caelestia";
|
desc = "Restart Waybar";
|
||||||
cmd = "hyprctl dispatch exec 'caelestia-shell kill | sleep 1 | caelestia-shell'";
|
cmd = "pkill -x waybar; waybar";
|
||||||
}
|
}
|
||||||
])
|
])
|
||||||
)
|
)
|
||||||
@@ -131,10 +130,9 @@ in {
|
|||||||
# Quick launch
|
# Quick launch
|
||||||
"$mod,RETURN, exec, uwsm app -- ${pkgs.ghostty}/bin/ghostty" # Ghostty (terminal)
|
"$mod,RETURN, exec, uwsm app -- ${pkgs.ghostty}/bin/ghostty" # Ghostty (terminal)
|
||||||
"$mod,E, exec, uwsm app -- ${pkgs.thunar}/bin/thunar" # Thunar
|
"$mod,E, exec, uwsm app -- ${pkgs.thunar}/bin/thunar" # Thunar
|
||||||
"$shiftMod, E, exec, pkill fuzzel || caelestia emoji -p" # Emoji picker
|
"$mod, SPACE, exec, walker" # Launcher
|
||||||
"$mod, SPACE, global, caelestia:launcher" # Launcher
|
"$mod, N, exec, ${lib.getExe pkgs.grimblast} save area" # Save screenshot
|
||||||
"$mod, N, exec, caelestia shell drawers toggle sidebar" # Sidebar (Notifications, quick actions)
|
"$mod, D, exec, ${lib.getExe pkgs.grimblast} copy area" # Copy screenshot
|
||||||
"$mod, D, exec, caelestia shell drawers toggle dashboard" # Dashboard
|
|
||||||
|
|
||||||
# Windows
|
# Windows
|
||||||
"$mod,Q, killactive," # Close window
|
"$mod,Q, killactive," # Close window
|
||||||
@@ -152,10 +150,9 @@ in {
|
|||||||
"$shiftMod,L, focusmonitor, 1" # Focus next monitor
|
"$shiftMod,L, focusmonitor, 1" # Focus next monitor
|
||||||
|
|
||||||
# Utilities
|
# Utilities
|
||||||
"$shiftMod, SPACE, exec, caelestia shell gameMode toggle" # Toggle Focus/Game mode
|
"$shiftMod, S, exec, ${lib.getExe pkgs.grimblast} copy area" # Capture region
|
||||||
"$shiftMod, S, global, caelestia:screenshotFreeze" # Capture region (freeze)
|
", Print, exec, ${lib.getExe pkgs.grimblast} copy area" # Capture region
|
||||||
", Print, global, caelestia:screenshotFreeze" # Capture region (freeze)
|
"$shiftMod+Alt, S, exec, ${lib.getExe pkgs.grimblast} save area" # Capture region
|
||||||
"$shiftMod+Alt, S, global, caelestia:screenshot" # Capture region
|
|
||||||
]
|
]
|
||||||
++ (builtins.concatLists (
|
++ (builtins.concatLists (
|
||||||
builtins.genList (
|
builtins.genList (
|
||||||
@@ -175,33 +172,23 @@ in {
|
|||||||
];
|
];
|
||||||
|
|
||||||
bindl = [
|
bindl = [
|
||||||
# Brightness
|
# Brightness
|
||||||
", XF86MonBrightnessUp, global, caelestia:brightnessUp"
|
", XF86MonBrightnessUp, exec, ${lib.getExe pkgs.brightnessctl} set 5%+"
|
||||||
", XF86MonBrightnessDown, global, caelestia:brightnessDown"
|
", XF86MonBrightnessDown, exec, ${lib.getExe pkgs.brightnessctl} set 5%-"
|
||||||
|
|
||||||
# Media
|
# Media
|
||||||
", XF86AudioPlay, global, caelestia:mediaToggle"
|
", XF86AudioPlay, exec, ${lib.getExe pkgs.playerctl} play-pause"
|
||||||
", XF86AudioPause, global, caelestia:mediaToggle"
|
", XF86AudioPause, exec, ${lib.getExe pkgs.playerctl} play-pause"
|
||||||
", XF86AudioNext, global, caelestia:mediaNext"
|
", XF86AudioNext, exec, ${lib.getExe pkgs.playerctl} next"
|
||||||
", XF86AudioPrev, global, caelestia:mediaPrev"
|
", XF86AudioPrev, exec, ${lib.getExe pkgs.playerctl} previous"
|
||||||
", XF86AudioStop, global, caelestia:mediaStop"
|
", XF86AudioStop, exec, ${lib.getExe pkgs.playerctl} stop"
|
||||||
|
|
||||||
|
# Sound
|
||||||
|
", XF86AudioMute, exec, wpctl set-mute @DEFAULT_AUDIO_SINK@ toggle"
|
||||||
|
", XF86AudioRaiseVolume, exec, wpctl set-mute @DEFAULT_AUDIO_SINK@ 0; wpctl set-volume -l 1 @DEFAULT_AUDIO_SINK@ 5%+"
|
||||||
|
", XF86AudioLowerVolume, exec, wpctl set-mute @DEFAULT_AUDIO_SINK@ 0; wpctl set-volume @DEFAULT_AUDIO_SINK@ 5%-"
|
||||||
|
];
|
||||||
|
|
||||||
# Sound
|
|
||||||
", XF86AudioMute, exec, wpctl set-mute @DEFAULT_AUDIO_SINK@ toggle"
|
|
||||||
", XF86AudioRaiseVolume, exec, wpctl set-mute @DEFAULT_AUDIO_SINK@ 0; wpctl set-volume -l 1 @DEFAULT_AUDIO_SINK@ 5%+"
|
|
||||||
", XF86AudioLowerVolume, exec, wpctl set-mute @DEFAULT_AUDIO_SINK@ 0; wpctl set-volume @DEFAULT_AUDIO_SINK@ 5%-"
|
|
||||||
];
|
|
||||||
|
|
||||||
bindin = [
|
|
||||||
# Launcher
|
|
||||||
"$mod, mouse:272, global, caelestia:launcherInterrupt"
|
|
||||||
"$mod, mouse:273, global, caelestia:launcherInterrupt"
|
|
||||||
"$mod, mouse:274, global, caelestia:launcherInterrupt"
|
|
||||||
"$mod, mouse:275, global, caelestia:launcherInterrupt"
|
|
||||||
"$mod, mouse:276, global, caelestia:launcherInterrupt"
|
|
||||||
"$mod, mouse:277, global, caelestia:launcherInterrupt"
|
|
||||||
"$mod, mouse_up, global, caelestia:launcherInterrupt"
|
|
||||||
"$mod, mouse_down, global, caelestia:launcherInterrupt"
|
|
||||||
];
|
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -0,0 +1,42 @@
|
|||||||
|
{ pkgs, ... }:
|
||||||
|
|
||||||
|
{
|
||||||
|
home.packages = with pkgs; [
|
||||||
|
walker
|
||||||
|
elephant
|
||||||
|
];
|
||||||
|
|
||||||
|
systemd.user.services.elephant = {
|
||||||
|
Unit = {
|
||||||
|
Description = "Elephant backend service";
|
||||||
|
PartOf = [ "graphical-session.target" ];
|
||||||
|
After = [ "graphical-session.target" ];
|
||||||
|
};
|
||||||
|
|
||||||
|
Service = {
|
||||||
|
ExecStart = "${pkgs.elephant}/bin/elephant";
|
||||||
|
Restart = "on-failure";
|
||||||
|
RestartSec = 5;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
systemd.user.services.walker = {
|
||||||
|
Unit = {
|
||||||
|
Description = "Walker application service";
|
||||||
|
PartOf = [ "graphical-session.target" ];
|
||||||
|
After = [ "elephant.service" "graphical-session.target" ];
|
||||||
|
Requires = [ "elephant.service" ];
|
||||||
|
};
|
||||||
|
|
||||||
|
Service = {
|
||||||
|
ExecStart = "${pkgs.walker}/bin/walker --gapplication-service";
|
||||||
|
Restart = "on-failure";
|
||||||
|
RestartSec = 5;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
wayland.windowManager.hyprland.settings.exec-once = [
|
||||||
|
"dbus-update-activation-environment --systemd --all"
|
||||||
|
"systemctl --user start elephant.service walker.service"
|
||||||
|
];
|
||||||
|
}
|
||||||
@@ -0,0 +1,277 @@
|
|||||||
|
{ pkgs, config, lib, ... }:
|
||||||
|
|
||||||
|
let
|
||||||
|
colors = config.lib.stylix.colors;
|
||||||
|
rgb = base:
|
||||||
|
"${colors."${base}-rgb-r"}, ${colors."${base}-rgb-g"}, ${colors."${base}-rgb-b"}";
|
||||||
|
terminal = cmd: "uwsm app -- ${lib.getExe pkgs.ghostty} -e ${cmd}";
|
||||||
|
|
||||||
|
radius = toString config.theme.bar-rounding;
|
||||||
|
in
|
||||||
|
{
|
||||||
|
home.packages = with pkgs; [
|
||||||
|
waybar
|
||||||
|
];
|
||||||
|
|
||||||
|
xdg.configFile."waybar/config".text = builtins.toJSON {
|
||||||
|
layer = "top";
|
||||||
|
position = "top";
|
||||||
|
height = 38;
|
||||||
|
|
||||||
|
spacing = 10;
|
||||||
|
|
||||||
|
"margin-top" = 8;
|
||||||
|
"margin-left" = 8;
|
||||||
|
"margin-right" = 8;
|
||||||
|
|
||||||
|
"gtk-layer-shell" = true;
|
||||||
|
"reload_style_on_change" = true;
|
||||||
|
|
||||||
|
"modules-left" = [
|
||||||
|
"hyprland/workspaces"
|
||||||
|
"tray"
|
||||||
|
];
|
||||||
|
|
||||||
|
"modules-center" = [
|
||||||
|
"hyprland/window"
|
||||||
|
];
|
||||||
|
|
||||||
|
"modules-right" = [
|
||||||
|
"custom/bluetooth"
|
||||||
|
"network"
|
||||||
|
"battery"
|
||||||
|
"pulseaudio"
|
||||||
|
"clock"
|
||||||
|
];
|
||||||
|
|
||||||
|
"hyprland/workspaces" = {
|
||||||
|
format = "{name}";
|
||||||
|
"disable-scroll" = true;
|
||||||
|
"all-outputs" = true;
|
||||||
|
"on-click" = "activate";
|
||||||
|
|
||||||
|
"persistent-workspaces" = {
|
||||||
|
"*" = 5;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
"hyprland/window" = {
|
||||||
|
format = "{}";
|
||||||
|
"max-length" = 70;
|
||||||
|
"separate-outputs" = true;
|
||||||
|
};
|
||||||
|
|
||||||
|
tray = {
|
||||||
|
spacing = 8;
|
||||||
|
"icon-size" = 20;
|
||||||
|
};
|
||||||
|
|
||||||
|
network = {
|
||||||
|
interval = 2;
|
||||||
|
|
||||||
|
"format-wifi" = " {signalStrength}%";
|
||||||
|
"format-ethernet" = " {ifname}";
|
||||||
|
"format-linked" = " {ifname}";
|
||||||
|
"format-disconnected" = "";
|
||||||
|
|
||||||
|
"tooltip-format" = "{essid}\n{ipaddr}";
|
||||||
|
"on-click" = terminal "wifitui";
|
||||||
|
};
|
||||||
|
|
||||||
|
battery = {
|
||||||
|
interval = 30;
|
||||||
|
states = {
|
||||||
|
warning = 30;
|
||||||
|
critical = 15;
|
||||||
|
};
|
||||||
|
|
||||||
|
format = " {capacity}%";
|
||||||
|
"format-charging" = " {capacity}%";
|
||||||
|
"format-plugged" = " {capacity}%";
|
||||||
|
"format-full" = " {capacity}%";
|
||||||
|
"tooltip-format" = "Battery {capacity}%\n{timeTo} remaining";
|
||||||
|
};
|
||||||
|
|
||||||
|
"custom/bluetooth" = {
|
||||||
|
exec = "echo ";
|
||||||
|
interval = 3600;
|
||||||
|
tooltip = false;
|
||||||
|
"on-click" = "uwsm app -- blueman-manager";
|
||||||
|
};
|
||||||
|
|
||||||
|
pulseaudio = {
|
||||||
|
"scroll-step" = 5;
|
||||||
|
|
||||||
|
format = " {volume}%";
|
||||||
|
"format-muted" = "";
|
||||||
|
|
||||||
|
tooltip = true;
|
||||||
|
"on-click" = terminal "wiremix";
|
||||||
|
};
|
||||||
|
|
||||||
|
clock = {
|
||||||
|
interval = 1;
|
||||||
|
|
||||||
|
format = " {:%H:%M}";
|
||||||
|
"tooltip-format" = "<big>{:%A, %d %B %Y}</big>";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
xdg.configFile."waybar/style.css".text = ''
|
||||||
|
* {
|
||||||
|
border: none;
|
||||||
|
min-height: 0;
|
||||||
|
|
||||||
|
font-family:
|
||||||
|
"${config.stylix.fonts.sansSerif.name}",
|
||||||
|
"${config.stylix.fonts.monospace.name}",
|
||||||
|
sans-serif;
|
||||||
|
|
||||||
|
font-size: 13px;
|
||||||
|
}
|
||||||
|
|
||||||
|
window#waybar {
|
||||||
|
background: transparent;
|
||||||
|
color: #${colors.base05};
|
||||||
|
}
|
||||||
|
|
||||||
|
.modules-left,
|
||||||
|
.modules-center,
|
||||||
|
.modules-right {
|
||||||
|
margin: 6px 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
#workspaces,
|
||||||
|
#window,
|
||||||
|
#tray,
|
||||||
|
#custom-bluetooth,
|
||||||
|
#network,
|
||||||
|
#battery,
|
||||||
|
#pulseaudio,
|
||||||
|
#clock {
|
||||||
|
background: rgba(${rgb "base01"}, 0.76);
|
||||||
|
|
||||||
|
border: 1px solid rgba(${rgb "base03"}, 0.45);
|
||||||
|
|
||||||
|
border-radius: ${radius}px;
|
||||||
|
|
||||||
|
padding: 0 14px;
|
||||||
|
margin: 6px 4px;
|
||||||
|
|
||||||
|
transition:
|
||||||
|
background-color 180ms ease,
|
||||||
|
border-color 180ms ease,
|
||||||
|
color 180ms ease;
|
||||||
|
}
|
||||||
|
|
||||||
|
#workspaces {
|
||||||
|
padding: 4px;
|
||||||
|
}
|
||||||
|
|
||||||
|
#workspaces button {
|
||||||
|
background: transparent;
|
||||||
|
color: #${colors.base04};
|
||||||
|
|
||||||
|
padding: 0 12px;
|
||||||
|
margin: 0 2px;
|
||||||
|
|
||||||
|
border-radius: ${radius}px;
|
||||||
|
|
||||||
|
transition: all 180ms ease;
|
||||||
|
}
|
||||||
|
|
||||||
|
#workspaces button:hover {
|
||||||
|
background: rgba(${rgb "base02"}, 0.70);
|
||||||
|
color: #${colors.base05};
|
||||||
|
}
|
||||||
|
|
||||||
|
#workspaces button.active {
|
||||||
|
background: #${colors.base0D};
|
||||||
|
color: #${colors.base00};
|
||||||
|
}
|
||||||
|
|
||||||
|
#workspaces button.urgent {
|
||||||
|
background: #${colors.base08};
|
||||||
|
color: #${colors.base00};
|
||||||
|
}
|
||||||
|
|
||||||
|
#window {
|
||||||
|
min-width: 260px;
|
||||||
|
|
||||||
|
padding-left: 18px;
|
||||||
|
padding-right: 18px;
|
||||||
|
|
||||||
|
color: #${colors.base05};
|
||||||
|
}
|
||||||
|
|
||||||
|
#window.empty {
|
||||||
|
background: transparent;
|
||||||
|
border: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
#tray {
|
||||||
|
padding-left: 10px;
|
||||||
|
padding-right: 10px;
|
||||||
|
}
|
||||||
|
|
||||||
|
#custom-bluetooth {
|
||||||
|
color: #${colors.base0E};
|
||||||
|
}
|
||||||
|
|
||||||
|
#network {
|
||||||
|
color: #${colors.base0C};
|
||||||
|
}
|
||||||
|
|
||||||
|
#network.disconnected {
|
||||||
|
color: #${colors.base08};
|
||||||
|
}
|
||||||
|
|
||||||
|
#battery {
|
||||||
|
color: #${colors.base0A};
|
||||||
|
}
|
||||||
|
|
||||||
|
#battery.charging,
|
||||||
|
#battery.plugged {
|
||||||
|
color: #${colors.base0B};
|
||||||
|
}
|
||||||
|
|
||||||
|
#battery.warning {
|
||||||
|
color: #${colors.base0A};
|
||||||
|
}
|
||||||
|
|
||||||
|
#battery.critical {
|
||||||
|
color: #${colors.base08};
|
||||||
|
}
|
||||||
|
|
||||||
|
#pulseaudio {
|
||||||
|
color: #${colors.base0B};
|
||||||
|
}
|
||||||
|
|
||||||
|
#pulseaudio.muted {
|
||||||
|
color: #${colors.base08};
|
||||||
|
}
|
||||||
|
|
||||||
|
#clock {
|
||||||
|
color: #${colors.base0D};
|
||||||
|
font-weight: 600;
|
||||||
|
}
|
||||||
|
|
||||||
|
tooltip {
|
||||||
|
background: rgba(${rgb "base00"}, 0.90);
|
||||||
|
|
||||||
|
border: 1px solid rgba(${rgb "base03"}, 0.70);
|
||||||
|
|
||||||
|
border-radius: ${radius}px;
|
||||||
|
}
|
||||||
|
|
||||||
|
tooltip label {
|
||||||
|
color: #${colors.base05};
|
||||||
|
}
|
||||||
|
'';
|
||||||
|
|
||||||
|
wayland.windowManager.hyprland.settings = {
|
||||||
|
exec-once = [
|
||||||
|
"waybar"
|
||||||
|
];
|
||||||
|
};
|
||||||
|
}
|
||||||
@@ -33,7 +33,8 @@
|
|||||||
# System
|
# System
|
||||||
# ─────────────────────────────────────────────────────────────
|
# ─────────────────────────────────────────────────────────────
|
||||||
../../home/system/hyprland
|
../../home/system/hyprland
|
||||||
../../home/system/caelestia-shell
|
../../home/system/waybar
|
||||||
|
../../home/system/walker
|
||||||
../../home/system/hyprpaper
|
../../home/system/hyprpaper
|
||||||
../../home/system/mime
|
../../home/system/mime
|
||||||
../../home/system/udiskie
|
../../home/system/udiskie
|
||||||
|
|||||||
@@ -26,12 +26,14 @@
|
|||||||
../../home/programs/group/basic-apps.nix
|
../../home/programs/group/basic-apps.nix
|
||||||
../../home/programs/group/dev.nix
|
../../home/programs/group/dev.nix
|
||||||
../../home/programs/group/misc.nix
|
../../home/programs/group/misc.nix
|
||||||
|
../../home/programs/group/gaming-apps.nix
|
||||||
|
|
||||||
# ─────────────────────────────────────────────────────────────
|
# ─────────────────────────────────────────────────────────────
|
||||||
# System
|
# System
|
||||||
# ─────────────────────────────────────────────────────────────
|
# ─────────────────────────────────────────────────────────────
|
||||||
../../home/system/hyprland
|
../../home/system/hyprland
|
||||||
../../home/system/caelestia-shell
|
../../home/system/waybar
|
||||||
|
../../home/system/walker
|
||||||
../../home/system/hyprpaper
|
../../home/system/hyprpaper
|
||||||
../../home/system/mime
|
../../home/system/mime
|
||||||
../../home/system/udiskie
|
../../home/system/udiskie
|
||||||
|
|||||||
+2
-1
@@ -22,7 +22,8 @@
|
|||||||
|
|
||||||
# System (Desktop environment like stuff)
|
# System (Desktop environment like stuff)
|
||||||
../../home/system/hyprland
|
../../home/system/hyprland
|
||||||
../../home/system/caelestia-shell
|
../../home/system/waybar
|
||||||
|
../../home/system/walker
|
||||||
../../home/system/hyprpaper
|
../../home/system/hyprpaper
|
||||||
../../home/system/mime
|
../../home/system/mime
|
||||||
../../home/system/udiskie
|
../../home/system/udiskie
|
||||||
|
|||||||
Reference in New Issue
Block a user