minor fixes and updates

This commit is contained in:
foglar 2025-04-06 10:39:38 +02:00
parent 2bb34bcaa0
commit 6744369399
10 changed files with 66 additions and 23 deletions

BIN
config/mars.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 401 KiB

View File

@ -16,7 +16,7 @@
editor = "neovim"; # neovim, vscode editor = "neovim"; # neovim, vscode
# List all themes: $ nix build nixpkgs#base16-schemes && ls result/share/themes # List all themes: $ nix build nixpkgs#base16-schemes && ls result/share/themes
theme = "tokyo-night-dark"; # catppuccin-mocha, tokyo-night-dark, one-dark theme = "catppuccin-mocha"; # catppuccin-mocha, tokyo-night-dark, one-dark
background = background =
if userSettings.theme == "catppuccin-mocha" if userSettings.theme == "catppuccin-mocha"
then "aurora_borealis.png" then "aurora_borealis.png"

View File

@ -36,7 +36,6 @@
#bootloader.systemd-boot.enable = true; #bootloader.systemd-boot.enable = true;
desktop = { desktop = {
hyprland.enable = true; hyprland.enable = true;
gnome.enable = true;
steamdeck.enable = false; steamdeck.enable = false;
}; };
fonts.packages = true; fonts.packages = true;

View File

@ -95,16 +95,16 @@
get_cover() { get_cover() {
DOWNLOAD_PATH="$HOME/.cache/cover.png" DOWNLOAD_PATH="$HOME/.cache/cover.png"
FALLBACK_PATH="./images/music.png" # Change this to your static image path FALLBACK_PATH="./images/music.png" # Change this to your static image path
# Get the image URL from playerctl # Get the image URL from playerctl
URL=$(playerctl metadata mpris:artUrl 2>/dev/null) URL=$(playerctl metadata mpris:artUrl 2>/dev/null)
# If the URL is empty or playerctl fails, return the fallback path # If the URL is empty or playerctl fails, return the fallback path
if [[ -z "$URL" ]]; then if [[ -z "$URL" ]]; then
echo "$FALLBACK_PATH" echo "$FALLBACK_PATH"
return return
fi fi
# Try downloading the image # Try downloading the image
if curl -s -o "$DOWNLOAD_PATH" "$URL"; then if curl -s -o "$DOWNLOAD_PATH" "$URL"; then
echo "$DOWNLOAD_PATH" echo "$DOWNLOAD_PATH"
@ -116,7 +116,7 @@
get_watched_length() { get_watched_length() {
total_length=$(playerctl metadata --format "{{ duration(mpris:length) }}" | awk -F: '{ print ($1 * 60) + $2 }') total_length=$(playerctl metadata --format "{{ duration(mpris:length) }}" | awk -F: '{ print ($1 * 60) + $2 }')
current_position=$(playerctl metadata --format "{{ duration(position) }}" | awk -F: '{ print ($1 * 60) + $2 }') current_position=$(playerctl metadata --format "{{ duration(position) }}" | awk -F: '{ print ($1 * 60) + $2 }')
if [[ "$total_length" -gt 0 ]]; then if [[ "$total_length" -gt 0 ]]; then
percentage=$(awk "BEGIN { printf \"%.2f\", ($current_position / $total_length) * 100 }") percentage=$(awk "BEGIN { printf \"%.2f\", ($current_position / $total_length) * 100 }")
echo "$percentage" echo "$percentage"
@ -275,7 +275,7 @@
label = [ label = [
{ {
monitor = ""; monitor = "";
text = "$TIME "; text = "$TIME";
color = "$text"; color = "$text";
font_size = 12; font_size = 12;
@ -342,11 +342,11 @@
#{ #{
# monitor = ""; # monitor = "";
# text = "cmd[update:1000] playerctl-hyprlock --status-symbol"; # text = "cmd[update:1000] playerctl-hyprlock --status-symbol";
# #
# color = "$fg0"; # color = "$fg0";
# font_size = 16; # font_size = 16;
# font_family = "$font-symbol"; # font_family = "$font-symbol";
# #
# position = "700, -370"; # position = "700, -370";
# halign = "left"; # halign = "left";
# valign = "bottom"; # valign = "bottom";

View File

@ -13,7 +13,7 @@
programs.git = { programs.git = {
enable = true; enable = true;
userName = "${userSettings.username}"; userName = "${userSettings.username}";
userEmail = "kohout.fi.2023@skola.ssps.cz"; userEmail = "sigma@goon.cz";
lfs.enable = true; lfs.enable = true;
}; };

View File

@ -12,8 +12,30 @@
(lib.mkIf config.program.tor.enable { (lib.mkIf config.program.tor.enable {
services.tor = { services.tor = {
enable = true; enable = true;
# ** This block exposes your service to the tor network **
# ** Change the port and target to your service **
# ** Get the onion address from /var/lib/tor/[myOnion]/hostname **
#enableGeoIP = false;
#relay.onionServices = {
#myOnion = {
# version = 3;
# map = [
# {
# port = 80;
# target = {
# addr = "127.0.0.1";
# port = 3000;
# };
# }
# ];
#};
#};
#settings = {
# ClientUseIPv4 = true;
# ClientUseIPv6 = false;
# ClientPreferIPv6ORPort = false;
#};
}; };
services.tor.client.enable = true;
}) })
(lib.mkIf config.program.proxychains.enable { (lib.mkIf config.program.proxychains.enable {
programs.proxychains = { programs.proxychains = {

View File

@ -15,13 +15,18 @@
}; };
config = lib.mkIf config.sys.default-applications.enable { config = lib.mkIf config.sys.default-applications.enable {
environment.sessionVariables = { environment.sessionVariables = let
editor-bin =
if userSettings.editor == "neovim"
then "nvim"
else userSettings.editor;
in {
DEFAULT_BROWSER = DEFAULT_BROWSER =
if userSettings.browser != "zen" if userSettings.browser != "zen"
then "${pkgs."${userSettings.browser}"}/bin/${userSettings.browser}" then "${pkgs."${userSettings.browser}"}/bin/${userSettings.browser}"
else "zen"; else "zen";
TERMINAL = "${pkgs."${userSettings.terminal}"}/bin/${userSettings.terminal}"; TERMINAL = "${pkgs."${userSettings.terminal}"}/bin/${userSettings.terminal}";
EDITOR = "${pkgs."${userSettings.editor}"}/bin/${userSettings.editor}"; EDITOR = "${pkgs."${userSettings.editor}"}/bin/${editor-bin}";
FLAKE = "/home/${userSettings.username}/.dotfiles"; FLAKE = "/home/${userSettings.username}/.dotfiles";
}; };

View File

@ -53,8 +53,8 @@
# Enable the Nvidia settings menu, # Enable the Nvidia settings menu,
# accessible via `nvidia-settings`. # accessible via `nvidia-settings`.
nvidiaSettings = true; nvidiaSettings = true;
prime.amdgpuBusId = "pci@000:04:0"; prime.amdgpuBusId = "PCI:4:0:0";
prime.nvidiaBusId = "pci@000:01:0"; prime.nvidiaBusId = "PCI:1:0:0";
# Optionally, you may need to select the appropriate driver version for your specific GPU. # Optionally, you may need to select the appropriate driver version for your specific GPU.
package = config.boot.kernelPackages.nvidiaPackages.stable; package = config.boot.kernelPackages.nvidiaPackages.stable;
}; };

View File

@ -30,7 +30,7 @@
# Scanning # Scanning
hardware.sane.enable = true; hardware.sane.enable = true;
services.ipp-usb.enable = true; services.ipp-usb.enable = true;
#hardware.sane.extraBackends = [pkgs.hplipWithPlugin]; hardware.sane.extraBackends = [pkgs.hplipWithPlugin];
users.users.${userSettings.username}.extraGroups = ["lp" "scanner"]; users.users.${userSettings.username}.extraGroups = ["lp" "scanner"];
}; };

View File

@ -16,7 +16,24 @@
image = ../../../config/backgrounds/${userSettings.background}; image = ../../../config/backgrounds/${userSettings.background};
base16Scheme = base16Scheme =
if userSettings.theme == "catppuccin-mocha" if userSettings.theme == "catppuccin-mocha"
then "${pkgs-stable.base16-schemes}/share/themes/${userSettings.theme}.yaml" then {
base00 = "#1e1e2e";
base01 = "#181825"; # mantle
base02 = "#313244"; # surface0
base03 = "#45475a"; # surface1
base04 = "#585b70"; # surface2
base05 = "#cdd6f4"; # text
base06 = "#f5e0dc"; # rosewater
base07 = "#b4befe"; # lavender
base08 = "#f38ba8"; # red
base09 = "#fab387"; # peach
base0A = "#f9e2af"; # yellow
base0B = "#a6e3a1"; # green
base0C = "#94e2d5"; # teal
base0D = "#89b4fa"; # blue
base0E = "#cba6f7"; # mauve
base0F = "#f2cdcd"; # flamingo
}
else if userSettings.theme == "evangelion-blood" else if userSettings.theme == "evangelion-blood"
then # List all possible themes: $ nix build nixpkgs#base16-schemes && ls result/share/themes then # List all possible themes: $ nix build nixpkgs#base16-schemes && ls result/share/themes
{ {
@ -77,13 +94,13 @@
}; };
serif = { serif = {
package = pkgs.nerd-fonts.monaspace; package = pkgs.nerd-fonts.ubuntu;
name = "Monaspace Xenon"; name = "Ubuntu NF";
}; };
sansSerif = { sansSerif = {
package = pkgs.nerd-fonts.monaspace; package = pkgs.nerd-fonts.ubuntu;
name = "Monaspace Argon"; name = "Ubuntu NF";
}; };
monospace = { monospace = {
@ -100,11 +117,11 @@
targets = { targets = {
plymouth = { plymouth = {
logo = logo =
if (userSettings.theme == "evangelion-blood") if userSettings.theme == "evangelion-blood"
then ../../../config/nerv.png then ../../../config/nerv.png
else if (userSettings.theme == "tokyo-night-dark") else if (userSettings.theme == "tokyo-night-dark")
then ../../../config/copeland.png then ../../../config/copeland.png
else ""; else ../../../config/mars.png;
logoAnimated = logoAnimated =
if "evangelion-blood" == userSettings.theme || "tokyo-night-dark" == userSettings.theme if "evangelion-blood" == userSettings.theme || "tokyo-night-dark" == userSettings.theme
then false then false