This commit is contained in:
coast 2025-10-26 23:13:27 +03:30
parent 9c3d012f9d
commit faa09ea0c7
6 changed files with 74 additions and 32 deletions

24
.wezterm.lua Normal file
View file

@ -0,0 +1,24 @@
local wezterm = require 'wezterm'
local config = wezterm.config_builder()
config.initial_cols = 120
config.initial_rows = 28
config.font_size = 12
config.font = wezterm.font("MapleMono")
config.window_close_confirmation = 'NeverPrompt'
config.enable_tab_bar = false
config.window_background_opacity = 0.9
config.window_padding = {
left = 5,
right = 5,
top = 5,
bottom = 5,
}
config.color_scheme = 'Afterglow'
return config

View file

@ -18,25 +18,26 @@ in
networking.hostName = "core";
networking.enableIPv6 = false;
networking.networkmanager.enable = true;
time.timeZone = "Asia/Tehran";
hardware = {
# graphics.enable = true;
# nvidia = {
# modesetting.enable = true;
# powerManagement.enable = true;
# open = false;
# nvidiaSettings = true;
# package = pkgs.linuxPackages.nvidiaPackages.beta;
# prime.offload = {
# enable = true;
# enableOffloadCmd = true;
# };
# prime = {
# intelBusId = "PCI:0:2:0";
# nvidiaBusId = "PCI:1:0:0";
# };
# };
graphics.enable = true;
nvidia = {
modesetting.enable = true;
powerManagement.enable = true;
open = false;
nvidiaSettings = true;
package = pkgs.linuxPackages.nvidiaPackages.beta;
prime.offload = {
enable = true;
enableOffloadCmd = true;
};
prime = {
intelBusId = "PCI:0:2:0";
nvidiaBusId = "PCI:1:0:0";
};
};
bluetooth.enable = true;
bluetooth.powerOnBoot = true;
};
@ -62,6 +63,8 @@ in
simple-mtpfs
android-tools
unstable.qbittorrent
unstable.zathura
unstable.kew
];
nix.settings.experimental-features = [ "nix-command" "flakes" ];

View file

@ -1,24 +1,23 @@
{ config, pkgs, ... }: {
{ pkgs, ... }: {
services = {
xserver = {
enable = true;
# videoDrivers = ["modesetting" "nvidia"];
videoDrivers = ["modesetting" "nvidia"];
windowManager.qtile.enable = false;
};
displayManager.ly.enable = true;
blueman.enable = false;
printing.enable = false;
#pipewire
pipewire = {
alsa.enable = true;
alsa.support32Bit = true;
pulse.enable = true;
};
};
security.rtkit.enable = true;
services.pipewire = {
enable = true;
alsa.enable = true;
alsa.support32Bit = true;
pulse.enable = true;
};
nixpkgs.config.allowUnfree = true;
@ -44,6 +43,7 @@
nerd-fonts._0xproto
nerd-fonts.droid-sans-mono
nerd-fonts.jetbrains-mono
vazir-fonts
];
services.openssh.enable = true;

View file

@ -10,7 +10,7 @@
eww = "eww";
};
modifier = "Mod4";
terminal = "footclient";
terminal = "${pkgs.wezterm}/bin/wezterm";
menu = "${pkgs.wmenu}/bin/wmenu-run";
in {
home.username = "coast";
@ -22,8 +22,8 @@ in {
home.packages = with pkgs; [
alsa-utils nix-search-cli neofetch dysk nsxiv tree wl-clipboard appimage-run libnotify grim slurp yazi mate.caja htop nixpkgs-fmt
swaybg wmenu mako nwg-look xorg.xkill
mpv vesktop wlr-randr autotiling
nodejs gcc gnumake clang-tools ruby_3_4 pkg-config dmd dtools rustup
mpv vesktop wlr-randr autotiling wezterm
nodejs gcc_multi gnumake clang-tools ruby_3_4 pkg-config dmd dtools rustup python3 python313Packages.pip texliveMedium unzip zip
];
wayland.windowManager.sway = {
@ -69,10 +69,15 @@ in {
"${modifier}+Shift+i" = "exec caja";
"${modifier}+Shift+r" = "reload";
"${modifier}+Shift+q" = "exit";
"${modifier}+Shift+v" = "exec vesktop --ozone-platform=wayland";
"${modifier}+Shift+p" = "exec /home/coast/.local/src/local/bin/setwall.sh";
};
startup = [
{ command = "autotiling"; }
{ command = "foot -s"; }
];
};
};
@ -88,7 +93,7 @@ in {
enableCompletion = true;
shellAliases = {
nf = "neofetch";
nrs = "doas nixos-rebuild switch";
nrs = "sudo nixos-rebuild switch";
emoji = "cat ~/.local/src/local/share/emoji | grep";
ls = "ls --color=auto";
smi = "nvidia-smi";
@ -102,8 +107,8 @@ in {
main = "man";
mian = "man";
mna = "man";
dias = "doas";
delgen = "doas nix-env --delete-generations old --profile /nix/var/nix/profiles/system";
dias = "sudo";
delgen = "sudo nix-env --delete-generations old --profile /nix/var/nix/profiles/system";
alsamixer = "alsamixer -c 0 --no-color";
la = "ls --color=auto -la";
};

8
local/bin/setwall.sh Executable file
View file

@ -0,0 +1,8 @@
#!/usr/bin/env bash
set -euo pipefail
WALL_DIR="/home/coast/.local/src/wall"
SUBDIR=$(find "$WALL_DIR" -mindepth 1 -maxdepth 1 -type d | shuf -n1)
FILE=$(find "$SUBDIR" -type f \( -iname '*.jpg' -o -iname '*.png' -o -iname '*.jpeg' \) | shuf -n1)
if [[ -n "$FILE" ]]; then
swaymsg output '*' bg "$FILE" fill
fi

2
local/bin/vesktop.sh Executable file
View file

@ -0,0 +1,2 @@
#!/bin/sh
vesktop --ozone-platform=wayland