Compare commits
2 commits
04560dfbc5
...
02a284fe90
Author | SHA1 | Date | |
---|---|---|---|
02a284fe90 | |||
c41543edcf |
28 changed files with 512 additions and 570 deletions
|
@ -1,6 +1,6 @@
|
||||||
{ config, lib, pkgs, jovian, ... }:
|
{ config, lib, pkgs, jovian, ... }:
|
||||||
{
|
{
|
||||||
imports = [ jovian.nixosModules.jovian ];
|
imports = [ jovian.nixosModules.default ];
|
||||||
|
|
||||||
options.system.steamdeck.enable = lib.mkEnableOption "Jovian NixOS environment";
|
options.system.steamdeck.enable = lib.mkEnableOption "Jovian NixOS environment";
|
||||||
|
|
||||||
|
@ -22,7 +22,10 @@
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
boot.kernelPackages = lib.mkForce pkgs.linuxPackages_jovian;
|
boot = {
|
||||||
|
kernelPackages = lib.mkForce pkgs.linuxPackages_jovian;
|
||||||
|
kernelParams = ["amd_pstate=active"];
|
||||||
|
};
|
||||||
|
|
||||||
programs.steam.extest.enable = true;
|
programs.steam.extest.enable = true;
|
||||||
|
|
||||||
|
|
|
@ -4,37 +4,24 @@
|
||||||
programs.firefox = {
|
programs.firefox = {
|
||||||
enable = true;
|
enable = true;
|
||||||
package = pkgs.librewolf;
|
package = pkgs.librewolf;
|
||||||
profiles = let
|
profiles.default = {
|
||||||
# FireFox css, based on https://github.com/Dook97/firefox-qutebrowser-userchrome
|
isDefault = true;
|
||||||
themeFont = ''
|
containersForce = true;
|
||||||
--tab-font: '${config.look.fonts.main}';
|
|
||||||
--urlbar-font: '${config.look.fonts.main}';
|
|
||||||
'';
|
|
||||||
themeMain = ''
|
|
||||||
:root {
|
|
||||||
--tab-active-bg-color: #${config.look.colors.prime};
|
|
||||||
--tab-hover-bg-color: #${config.look.colors.accent};
|
|
||||||
--tab-inactive-bg-color: #${config.look.colors.dark};
|
|
||||||
--tab-active-fg-fallback-color: #FFFFFF;
|
|
||||||
--tab-inactive-fg-fallback-color: #${config.look.colors.text};
|
|
||||||
--urlbar-focused-bg-color: #${config.look.colors.dark};
|
|
||||||
--urlbar-not-focused-bg-color: #${config.look.colors.dark};
|
|
||||||
--toolbar-bgcolor: #${config.look.colors.dark} !important;
|
|
||||||
'';
|
|
||||||
themeAlt = ''
|
|
||||||
:root {
|
|
||||||
--tab-active-bg-color: #${config.look.colors.dark};
|
|
||||||
--tab-hover-bg-color: #${config.look.colors.accent};
|
|
||||||
--tab-inactive-bg-color: #${config.look.colors.prime};
|
|
||||||
--tab-active-fg-fallback-color: #${config.look.colors.text};
|
|
||||||
--tab-inactive-fg-fallback-color: #FFFFFF;
|
|
||||||
--urlbar-focused-bg-color: #${config.look.colors.prime};
|
|
||||||
--urlbar-not-focused-bg-color: #${config.look.colors.prime};
|
|
||||||
--toolbar-bgcolor: #${config.look.colors.prime} !important;
|
|
||||||
'';
|
|
||||||
|
|
||||||
# Profile settings
|
containers = {
|
||||||
commonExtensions = with pkgs.nur.repos.rycee.firefox-addons; [
|
home = {
|
||||||
|
color = "purple";
|
||||||
|
icon = "fruit";
|
||||||
|
id = 0;
|
||||||
|
};
|
||||||
|
school = {
|
||||||
|
color = "red";
|
||||||
|
icon = "briefcase";
|
||||||
|
id = 1;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
extensions = with pkgs.nur.repos.rycee.firefox-addons; [
|
||||||
bitwarden
|
bitwarden
|
||||||
darkreader
|
darkreader
|
||||||
return-youtube-dislikes
|
return-youtube-dislikes
|
||||||
|
@ -43,7 +30,8 @@
|
||||||
ublock-origin
|
ublock-origin
|
||||||
violentmonkey
|
violentmonkey
|
||||||
];
|
];
|
||||||
commonSearch = {
|
|
||||||
|
search = {
|
||||||
force = true;
|
force = true;
|
||||||
default = "Ecosia";
|
default = "Ecosia";
|
||||||
order = [
|
order = [
|
||||||
|
@ -64,6 +52,7 @@
|
||||||
}];
|
}];
|
||||||
definedAliases = [ "@e" ];
|
definedAliases = [ "@e" ];
|
||||||
};
|
};
|
||||||
|
|
||||||
"NixPKGs" = {
|
"NixPKGs" = {
|
||||||
urls = [{
|
urls = [{
|
||||||
template = "https://search.nixos.org/packages";
|
template = "https://search.nixos.org/packages";
|
||||||
|
@ -80,6 +69,7 @@
|
||||||
}];
|
}];
|
||||||
definedAliases = [ "@p" ];
|
definedAliases = [ "@p" ];
|
||||||
};
|
};
|
||||||
|
|
||||||
"MyNixOS" = {
|
"MyNixOS" = {
|
||||||
urls = [{
|
urls = [{
|
||||||
template = "https://mynixos.com/search";
|
template = "https://mynixos.com/search";
|
||||||
|
@ -90,6 +80,7 @@
|
||||||
}];
|
}];
|
||||||
definedAliases = [ "@my" ];
|
definedAliases = [ "@my" ];
|
||||||
};
|
};
|
||||||
|
|
||||||
"YouTube" = {
|
"YouTube" = {
|
||||||
urls = [{
|
urls = [{
|
||||||
template = "https://www.youtube.com/results";
|
template = "https://www.youtube.com/results";
|
||||||
|
@ -100,13 +91,17 @@
|
||||||
}];
|
}];
|
||||||
definedAliases = [ "@y" ];
|
definedAliases = [ "@y" ];
|
||||||
};
|
};
|
||||||
|
|
||||||
"Spotify" = {
|
"Spotify" = {
|
||||||
urls = [{ template = "https://open.spotify.com/search/{searchTerms}"; }];
|
urls = [{ template = "https://open.spotify.com/search/{searchTerms}"; }];
|
||||||
definedAliases = [ "@s" ];
|
definedAliases = [ "@s" ];
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
commonSettings = {
|
|
||||||
|
settings = {
|
||||||
|
force = true;
|
||||||
|
|
||||||
# Generic
|
# Generic
|
||||||
"browser.download.useDownloadDir" = true;
|
"browser.download.useDownloadDir" = true;
|
||||||
"browser.shell.checkDefaultBrowser" = false;
|
"browser.shell.checkDefaultBrowser" = false;
|
||||||
|
@ -121,9 +116,9 @@
|
||||||
"webgl.disabled" = false;
|
"webgl.disabled" = false;
|
||||||
|
|
||||||
# Fonts
|
# Fonts
|
||||||
"font.name.serif.x-western" = config.look.fonts.main;
|
|
||||||
"font.name.sans-serif.x-western" = config.look.fonts.main;
|
|
||||||
"font.name.monospace.x-western" = config.look.fonts.mono;
|
"font.name.monospace.x-western" = config.look.fonts.mono;
|
||||||
|
"font.name.sans-serif.x-western" = config.look.fonts.main;
|
||||||
|
"font.name.serif.x-western" = config.look.fonts.main;
|
||||||
|
|
||||||
# Theming and visibility
|
# Theming and visibility
|
||||||
"browser.aboutConfig.showWarning" = false;
|
"browser.aboutConfig.showWarning" = false;
|
||||||
|
@ -143,47 +138,46 @@
|
||||||
"browser.newtabpage.enabled" = false;
|
"browser.newtabpage.enabled" = false;
|
||||||
|
|
||||||
# Safe browsing
|
# Safe browsing
|
||||||
|
"browser.safebrowsing.blockedURIs.enabled" = false;
|
||||||
"browser.safebrowsing.downloads.enabled" = false;
|
"browser.safebrowsing.downloads.enabled" = false;
|
||||||
"browser.safebrowsing.downloads.remote.enabled" = false;
|
|
||||||
"browser.safebrowsing.downloads.remote.block_uncommon" = false;
|
|
||||||
"browser.safebrowsing.downloads.remote.block_potentially_unwanted" = false;
|
"browser.safebrowsing.downloads.remote.block_potentially_unwanted" = false;
|
||||||
|
"browser.safebrowsing.downloads.remote.block_uncommon" = false;
|
||||||
|
"browser.safebrowsing.downloads.remote.enabled" = false;
|
||||||
"browser.safebrowsing.malware.enabled" = false;
|
"browser.safebrowsing.malware.enabled" = false;
|
||||||
"browser.safebrowsing.phishing.enabled" = false;
|
"browser.safebrowsing.phishing.enabled" = false;
|
||||||
"browser.safebrowsing.blockedURIs.enabled" = false;
|
|
||||||
"browser.safebrowsing.provider.google4.gethashURL" = false;
|
|
||||||
"browser.safebrowsing.provider.google4.updateURL" = false;
|
|
||||||
"browser.safebrowsing.provider.google.gethashURL" = false;
|
"browser.safebrowsing.provider.google.gethashURL" = false;
|
||||||
"browser.safebrowsing.provider.google.updateURL" = false;
|
"browser.safebrowsing.provider.google.updateURL" = false;
|
||||||
|
"browser.safebrowsing.provider.google4.gethashURL" = false;
|
||||||
|
"browser.safebrowsing.provider.google4.updateURL" = false;
|
||||||
|
|
||||||
# Extensions
|
# Extensions
|
||||||
"extensions.pocket.enabled" = false;
|
|
||||||
"extensions.formautofill.addresses.enabled" = false;
|
"extensions.formautofill.addresses.enabled" = false;
|
||||||
"extensions.formautofill.creditCards.enabled" = false;
|
"extensions.formautofill.creditCards.enabled" = false;
|
||||||
"extensions.getAddons.showPane" = false;
|
"extensions.getAddons.showPane" = false;
|
||||||
"extensions.htmlaboutaddons.discover.enabled" = false;
|
"extensions.htmlaboutaddons.discover.enabled" = false;
|
||||||
"extensions.htmlaboutaddons.recommendations.enabled" = false;
|
"extensions.htmlaboutaddons.recommendations.enabled" = false;
|
||||||
|
"extensions.pocket.enabled" = false;
|
||||||
|
|
||||||
# Force extensions to work
|
# Force extensions to work
|
||||||
"extensions.autoDisableScopes" = 0;
|
"extensions.autoDisableScopes" = 0;
|
||||||
"extensions.enabledScopes" = 15;
|
"extensions.enabledScopes" = 15;
|
||||||
|
|
||||||
# Privacy
|
# Privacy
|
||||||
"privacy.resistFingerprinting" = true;
|
|
||||||
"privacy.firstparty.isolate" = true;
|
|
||||||
"privacy.fingerprintingProtection" = true;
|
|
||||||
"privacy.globalprivacycontrol.enabled" = true;
|
|
||||||
"privacy.globalprivacycontrol.functionality.enabled" = true;
|
|
||||||
"privacy.clearOnShutdown.cookies" = false;
|
"privacy.clearOnShutdown.cookies" = false;
|
||||||
"privacy.clearOnShutdown_v2.cookiesAndStorage" = false;
|
"privacy.clearOnShutdown_v2.cookiesAndStorage" = false;
|
||||||
|
"privacy.fingerprintingProtection" = true;
|
||||||
|
"privacy.firstparty.isolate" = true;
|
||||||
|
"privacy.globalprivacycontrol.enabled" = true;
|
||||||
|
"privacy.globalprivacycontrol.functionality.enabled" = true;
|
||||||
|
"privacy.resistFingerprinting" = true;
|
||||||
|
|
||||||
# Tracking URL blocking
|
# Tracking URL blocking
|
||||||
"urlclassifier.trackingSkipURLs" = "*.reddit.com, *.twitter.com, *.twimg.com, *.tiktok.com";
|
|
||||||
"urlclassifier.features.socialtracking.skipURLs" = "*.instagram.com, *.twitter.com, *.twimg.com";
|
"urlclassifier.features.socialtracking.skipURLs" = "*.instagram.com, *.twitter.com, *.twimg.com";
|
||||||
|
"urlclassifier.trackingSkipURLs" = "*.reddit.com, *.twitter.com, *.twimg.com, *.tiktok.com";
|
||||||
|
|
||||||
# Network tracking
|
# Network tracking
|
||||||
"browser.contentblocking.category" = "strict";
|
"browser.contentblocking.category" = "strict";
|
||||||
"network.cookie.cookieBehavior" = 1;
|
"network.cookie.cookieBehavior" = 1;
|
||||||
"network.cookie.sameSite.noneRequiresSecure" = true;
|
|
||||||
"network.http.referer.XOriginPolicy" = 2;
|
"network.http.referer.XOriginPolicy" = 2;
|
||||||
"network.http.referer.XOriginTrimmingPolicy" = 2;
|
"network.http.referer.XOriginTrimmingPolicy" = 2;
|
||||||
"network.http.referer.trimmingPolicy" = 2;
|
"network.http.referer.trimmingPolicy" = 2;
|
||||||
|
@ -209,40 +203,28 @@
|
||||||
"services.sync.engine.addresses.available" = false;
|
"services.sync.engine.addresses.available" = false;
|
||||||
"svg.context-properties.content.enabled" = true;
|
"svg.context-properties.content.enabled" = true;
|
||||||
};
|
};
|
||||||
in {
|
|
||||||
Main = {
|
userChrome = ''
|
||||||
id = 0;
|
:root {
|
||||||
isDefault = true;
|
--tab-active-bg-color: #${config.look.colors.prime};
|
||||||
extensions = commonExtensions;
|
--tab-hover-bg-color: #${config.look.colors.accent};
|
||||||
search = commonSearch;
|
--tab-inactive-bg-color: #${config.look.colors.dark};
|
||||||
settings = commonSettings;
|
--tab-active-fg-fallback-color: #FFFFFF;
|
||||||
userChrome = ''
|
--tab-inactive-fg-fallback-color: #${config.look.colors.text};
|
||||||
${themeMain}
|
--urlbar-focused-bg-color: #${config.look.colors.dark};
|
||||||
${themeFont}
|
--urlbar-not-focused-bg-color: #${config.look.colors.dark};
|
||||||
|
--toolbar-bgcolor: #${config.look.colors.dark} !important;
|
||||||
|
--tab-font: '${config.look.fonts.main}';
|
||||||
|
--urlbar-font: '${config.look.fonts.main}';
|
||||||
${builtins.readFile ./quteFox.css}
|
${builtins.readFile ./quteFox.css}
|
||||||
'';
|
'';
|
||||||
};
|
|
||||||
Alt = {
|
|
||||||
id = 1;
|
|
||||||
extensions = commonExtensions;
|
|
||||||
search = commonSearch;
|
|
||||||
settings = commonSettings;
|
|
||||||
userChrome = ''
|
|
||||||
${themeAlt}
|
|
||||||
${themeFont}
|
|
||||||
${builtins.readFile ./quteFox.css}
|
|
||||||
'';
|
|
||||||
};
|
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
# Symlinks to Librewolf
|
# Symlinks to Librewolf
|
||||||
home = {
|
home = {
|
||||||
file = {
|
file.".librewolf".source = config.lib.file.mkOutOfStoreSymlink "${config.home.homeDirectory}/.mozilla/firefox";
|
||||||
".librewolf".source = config.lib.file.mkOutOfStoreSymlink "${config.home.homeDirectory}/.mozilla/firefox";
|
persistence."${config.xdg.userDirs.extraConfig.XDG_PERSIST_DIR}".directories = [ "browser/.mozilla/firefox/default" ];
|
||||||
".mozilla/librewolf".source = config.lib.file.mkOutOfStoreSymlink "${config.home.homeDirectory}/.mozilla/firefox";
|
|
||||||
};
|
|
||||||
persistence."${config.xdg.userDirs.extraConfig.XDG_PERSIST_DIR}".directories = [ "browser/.mozilla" ];
|
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -8,10 +8,10 @@
|
||||||
steam
|
steam
|
||||||
steam-run-free
|
steam-run-free
|
||||||
];
|
];
|
||||||
persistence."${config.xdg.userDirs.extraConfig.XDG_PERSIST_DIR}".directories = [
|
persistence."${config.xdg.userDirs.extraConfig.XDG_PERSIST_DIR}".directories = with lib; with config.home; with config.xdg; [
|
||||||
"games/.config/heroic"
|
"games/${removePrefix "${homeDirectory}/" configHome}/heroic"
|
||||||
"games/.local/share/PrismLauncher"
|
"games/${removePrefix "${homeDirectory}/" dataHome}/PrismLauncher"
|
||||||
"games/.local/share/Steam"
|
"games/${removePrefix "${homeDirectory}/" dataHome}/Steam"
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
@ -6,9 +6,9 @@
|
||||||
qbittorrent
|
qbittorrent
|
||||||
vesktop
|
vesktop
|
||||||
];
|
];
|
||||||
persistence."${config.xdg.userDirs.extraConfig.XDG_PERSIST_DIR}".directories = [
|
persistence."${config.xdg.userDirs.extraConfig.XDG_PERSIST_DIR}".directories = with lib; with config.home; with config.xdg; [
|
||||||
"data/.config/qBittorrent"
|
"data/${removePrefix "${homeDirectory}/" configHome}/qBittorrent"
|
||||||
"data/.config/vesktop"
|
"data/${removePrefix "${homeDirectory}/" configHome}/vesktop"
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -8,10 +8,10 @@
|
||||||
blender_4_4
|
blender_4_4
|
||||||
krita
|
krita
|
||||||
];
|
];
|
||||||
persistence."${config.xdg.userDirs.extraConfig.XDG_PERSIST_DIR}".directories = [
|
persistence."${config.xdg.userDirs.extraConfig.XDG_PERSIST_DIR}".directories = with lib; with config.home; with config.xdg; [
|
||||||
"data/.config/audacity"
|
"data/${removePrefix "${homeDirectory}/" configHome}/audacity"
|
||||||
"data/.config/blender"
|
"data/${removePrefix "${homeDirectory}/" configHome}/blender"
|
||||||
"data/.local/share/krita"
|
"data/${removePrefix "${homeDirectory}/" dataHome}/krita"
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -11,13 +11,12 @@
|
||||||
|
|
||||||
shellAliases.seneca = "ssh jhampton1@matrix.senecapolytechnic.ca";
|
shellAliases.seneca = "ssh jhampton1@matrix.senecapolytechnic.ca";
|
||||||
|
|
||||||
persistence."${config.xdg.userDirs.extraConfig.XDG_PERSIST_DIR}".directories = [
|
persistence."${config.xdg.userDirs.extraConfig.XDG_PERSIST_DIR}".directories = with lib; with config.home; with config.xdg; [
|
||||||
"school/.cache/gpclient"
|
"school/${removePrefix "${homeDirectory}/" cacheHome}/gpclient"
|
||||||
"school/.config/com.yuezk.qt"
|
"school/${removePrefix "${homeDirectory}/" configHome}/com.yuezk.qt"
|
||||||
"school/.config/remmina"
|
"school/${removePrefix "${homeDirectory}/" configHome}/remmina"
|
||||||
"school/.config/teams-for-linux"
|
"school/${removePrefix "${homeDirectory}/" configHome}/teams-for-linux"
|
||||||
"school/.vmware"
|
"school/.vmware"
|
||||||
"school/vmware"
|
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -7,6 +7,7 @@
|
||||||
./eza
|
./eza
|
||||||
./fastfetch
|
./fastfetch
|
||||||
./git
|
./git
|
||||||
|
./gpg
|
||||||
./lazygit
|
./lazygit
|
||||||
./ncmpcpp
|
./ncmpcpp
|
||||||
./neovim
|
./neovim
|
||||||
|
|
|
@ -1,97 +0,0 @@
|
||||||
{
|
|
||||||
"$schema": "https://github.com/fastfetch-cli/fastfetch/raw/dev/doc/json_schema.json",
|
|
||||||
"logo": {
|
|
||||||
"source": "xenia",
|
|
||||||
"color": {
|
|
||||||
"1": "1;97",
|
|
||||||
"2": "red",
|
|
||||||
"3": "yellow"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"display": {
|
|
||||||
"separator": " \u001b[33m ",
|
|
||||||
"color": "red"
|
|
||||||
},
|
|
||||||
"modules": [
|
|
||||||
{
|
|
||||||
"type": "custom",
|
|
||||||
"format": "\u001b[1m—————————————————————————————————————"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"type": "host",
|
|
||||||
"key": " "
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"type": "cpu",
|
|
||||||
"key": " "
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"type": "gpu",
|
|
||||||
"key": " "
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"type": "disk",
|
|
||||||
"folders": "/",
|
|
||||||
"key": " "
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"type": "memory",
|
|
||||||
"format": "{/1}{-}{/}{/2}{-}{/}{} / {}",
|
|
||||||
"key": " "
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"type": "display",
|
|
||||||
"compactType": "original",
|
|
||||||
"key": " "
|
|
||||||
},
|
|
||||||
|
|
||||||
{
|
|
||||||
"type": "custom",
|
|
||||||
"format": "\u001b[1m—————————————————————————————————————"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"type": "os",
|
|
||||||
"format": "{3} {12}",
|
|
||||||
"key": " "
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"type": "kernel",
|
|
||||||
"format": "{1} {2}",
|
|
||||||
"key": " "
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"type": "wm",
|
|
||||||
"key": " "
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"type": "shell",
|
|
||||||
"key": " "
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"type": "terminal",
|
|
||||||
"key": " "
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"type": "packages",
|
|
||||||
"key": " "
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"type": "uptime",
|
|
||||||
"key": " "
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"type": "command",
|
|
||||||
"text": "date -d @$(stat -c %W /persist) '+%a %b %d %r %Y'",
|
|
||||||
"key": " "
|
|
||||||
},
|
|
||||||
|
|
||||||
{
|
|
||||||
"type": "custom",
|
|
||||||
"format": "\u001b[1m—————————————————————————————————————"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"type": "custom",
|
|
||||||
"format": "\u001b[90m \u001b[31m \u001b[32m \u001b[33m \u001b[34m \u001b[35m \u001b[36m \u001b[37m"
|
|
||||||
}
|
|
||||||
]
|
|
||||||
}
|
|
|
@ -1,11 +1,108 @@
|
||||||
{ pkgs, ... }:
|
{ ... }:
|
||||||
{
|
{
|
||||||
programs.fastfetch.enable = true;
|
imports = [ ./smallfetch ];
|
||||||
|
|
||||||
home = {
|
programs.fastfetch = {
|
||||||
shellAliases.ff = "clear && fastfetch";
|
enable = true;
|
||||||
packages = with pkgs; [ (writeScriptBin "smallfetch" "fastfetch --config ~/.config/fastfetch/small.jsonc") ];
|
settings = {
|
||||||
|
logo = {
|
||||||
|
source = "xenia";
|
||||||
|
color = {
|
||||||
|
"1" = "1;97";
|
||||||
|
"2" = "red";
|
||||||
|
"3" = "yellow";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
display = {
|
||||||
|
separator = '' \u001b[33m '';
|
||||||
|
color = "red";
|
||||||
|
};
|
||||||
|
|
||||||
|
modules = [
|
||||||
|
{
|
||||||
|
type = "custom";
|
||||||
|
format = ''\u001b[1m—————————————————————————————————————'';
|
||||||
|
}
|
||||||
|
{
|
||||||
|
type = "host";
|
||||||
|
key = " ";
|
||||||
|
}
|
||||||
|
{
|
||||||
|
type = "cpu";
|
||||||
|
key = " ";
|
||||||
|
}
|
||||||
|
{
|
||||||
|
type = "gpu";
|
||||||
|
key = " ";
|
||||||
|
}
|
||||||
|
{
|
||||||
|
type = "disk";
|
||||||
|
folders = "/";
|
||||||
|
key = " ";
|
||||||
|
}
|
||||||
|
{
|
||||||
|
type = "memory";
|
||||||
|
format = "{/1};-}{/}{/2}{-}{/}{} / {}";
|
||||||
|
key = " ";
|
||||||
|
}
|
||||||
|
{
|
||||||
|
type = "display";
|
||||||
|
compactType = "original";
|
||||||
|
key = " ";
|
||||||
|
}
|
||||||
|
|
||||||
|
{
|
||||||
|
type = "custom";
|
||||||
|
format = ''\u001b[1m—————————————————————————————————————'';
|
||||||
|
}
|
||||||
|
{
|
||||||
|
type = "os";
|
||||||
|
format = "{3} {12}";
|
||||||
|
key = " ";
|
||||||
|
}
|
||||||
|
{
|
||||||
|
type = "kernel";
|
||||||
|
format = "{1} {2}";
|
||||||
|
key = " ";
|
||||||
|
}
|
||||||
|
{
|
||||||
|
type = "wm";
|
||||||
|
key = " ";
|
||||||
|
}
|
||||||
|
{
|
||||||
|
type = "shell";
|
||||||
|
key = " ";
|
||||||
|
}
|
||||||
|
{
|
||||||
|
type = "terminal";
|
||||||
|
key = " ";
|
||||||
|
}
|
||||||
|
{
|
||||||
|
type = "packages";
|
||||||
|
key = " ";
|
||||||
|
}
|
||||||
|
{
|
||||||
|
type = "uptime";
|
||||||
|
key = " ";
|
||||||
|
}
|
||||||
|
{
|
||||||
|
type = "command";
|
||||||
|
text = "date -d @$(stat -c %W /persist) '+%a %b %d %r %Y'";
|
||||||
|
key = " ";
|
||||||
|
}
|
||||||
|
|
||||||
|
{
|
||||||
|
type = "custom";
|
||||||
|
format = ''\u001b[1m—————————————————————————————————————'';
|
||||||
|
}
|
||||||
|
{
|
||||||
|
type = "custom";
|
||||||
|
format = ''\u001b[90m \u001b[31m \u001b[32m \u001b[33m \u001b[34m \u001b[35m \u001b[36m \u001b[37m'';
|
||||||
|
}
|
||||||
|
];
|
||||||
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
xdg.configFile."fastfetch".source = ./configs;
|
home.shellAliases.ff = "clear && fastfetch";
|
||||||
}
|
}
|
||||||
|
|
|
@ -0,0 +1,9 @@
|
||||||
|
{ pkgs, ... }:
|
||||||
|
{
|
||||||
|
home.packages = with pkgs; [
|
||||||
|
(writeScriptBin "smallfetch" ''
|
||||||
|
#!/bin/sh
|
||||||
|
fastfetch --config ${builtins.toString ./config.jsonc}
|
||||||
|
'')
|
||||||
|
];
|
||||||
|
}
|
|
@ -5,5 +5,7 @@
|
||||||
enableSshSupport = true;
|
enableSshSupport = true;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
programs.gpg.enable = true;
|
||||||
|
|
||||||
home.persistence."${config.xdg.userDirs.extraConfig.XDG_PERSIST_DIR}".directories = [ "secure/.gnupg" ];
|
home.persistence."${config.xdg.userDirs.extraConfig.XDG_PERSIST_DIR}".directories = [ "secure/.gnupg" ];
|
||||||
}
|
}
|
|
@ -2,5 +2,5 @@
|
||||||
{
|
{
|
||||||
programs.nix-index.enable = true;
|
programs.nix-index.enable = true;
|
||||||
|
|
||||||
home.persistence."${config.xdg.userDirs.extraConfig.XDG_PERSIST_DIR}".directories = [ "nix/.cache/nix-index" ];
|
home.persistence."${config.xdg.userDirs.extraConfig.XDG_PERSIST_DIR}".directories = [ "state/.cache/nix-index" ];
|
||||||
}
|
}
|
||||||
|
|
7
modules/home/programs/terminal/ssh/default.nix
Normal file
7
modules/home/programs/terminal/ssh/default.nix
Normal file
|
@ -0,0 +1,7 @@
|
||||||
|
{ ... }:
|
||||||
|
{
|
||||||
|
programs.ssh = {
|
||||||
|
enable = true;
|
||||||
|
addKeysToAgent = "yes";
|
||||||
|
};
|
||||||
|
}
|
|
@ -1,4 +1,4 @@
|
||||||
{ config, pkgs, ... }:
|
{ config, lib, pkgs, ... }:
|
||||||
{
|
{
|
||||||
programs.zsh = {
|
programs.zsh = {
|
||||||
enable = true;
|
enable = true;
|
||||||
|
@ -16,6 +16,7 @@
|
||||||
};
|
};
|
||||||
history = {
|
history = {
|
||||||
append = true;
|
append = true;
|
||||||
|
expireDuplicatesFirst = true;
|
||||||
ignoreAllDups = true;
|
ignoreAllDups = true;
|
||||||
ignoreSpace = true;
|
ignoreSpace = true;
|
||||||
path = "$ZDOTDIR/.zsh_history";
|
path = "$ZDOTDIR/.zsh_history";
|
||||||
|
@ -26,5 +27,6 @@
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
|
|
||||||
home.persistence."${config.xdg.userDirs.extraConfig.XDG_PERSIST_DIR}".directories = [ "state/.config/zsh" ];
|
home.persistence."${config.xdg.userDirs.extraConfig.XDG_PERSIST_DIR}".directories = with lib; with config.home; with config.xdg;
|
||||||
|
[ "state/${removePrefix "${homeDirectory}/" configHome}/zsh" ];
|
||||||
}
|
}
|
||||||
|
|
|
@ -2,7 +2,6 @@
|
||||||
{
|
{
|
||||||
imports = [
|
imports = [
|
||||||
./easyeffects
|
./easyeffects
|
||||||
./gpg
|
|
||||||
./mpd
|
./mpd
|
||||||
./playerctl
|
./playerctl
|
||||||
];
|
];
|
||||||
|
|
|
@ -3,22 +3,23 @@
|
||||||
imports = [ impermanence.homeManagerModules.default ];
|
imports = [ impermanence.homeManagerModules.default ];
|
||||||
|
|
||||||
home.persistence."${config.xdg.userDirs.extraConfig.XDG_PERSIST_DIR}" = {
|
home.persistence."${config.xdg.userDirs.extraConfig.XDG_PERSIST_DIR}" = {
|
||||||
|
enable = true;
|
||||||
allowOther = false;
|
allowOther = false;
|
||||||
removePrefixDirectory = true;
|
removePrefixDirectory = true;
|
||||||
directories = [
|
directories = let
|
||||||
"dirs/Keepers"
|
home = config.home.homeDirectory;
|
||||||
"dirs/Projects"
|
strip = path: lib.removePrefix "${home}/" path;
|
||||||
|
in with config.xdg.userDirs; [
|
||||||
"nix/.local/state/nix/profiles"
|
"dirs/${strip extraConfig.XDG_KEEPERS_DIR}"
|
||||||
|
"dirs/${strip extraConfig.XDG_PROJECTS_DIR}"
|
||||||
"secure/.ssh"
|
"secure/.ssh"
|
||||||
] ++ (if config.home.desktop.enable then [
|
] ++ (if config.home.desktop.enable then [
|
||||||
"dirs/Documents"
|
"dirs/${strip documents}"
|
||||||
"dirs/Games"
|
"dirs/${strip extraConfig.XDG_GAMES_DIR}"
|
||||||
"dirs/Photos"
|
"dirs/${strip pictures}"
|
||||||
"dirs/Videos"
|
"dirs/${strip videos}"
|
||||||
|
|
||||||
"secure/.pki"
|
"state/${strip config.xdg.stateHome}/wireplumber"
|
||||||
"state/.local/state/wireplumber"
|
|
||||||
] else []);
|
] else []);
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,9 +1,11 @@
|
||||||
{ ... }:
|
{ config, ... }:
|
||||||
{
|
{
|
||||||
imports = [
|
imports = [
|
||||||
./defaults
|
./defaults
|
||||||
./folders
|
./folders
|
||||||
];
|
];
|
||||||
|
|
||||||
|
xdg.enable = config.home.desktop.enable;
|
||||||
|
|
||||||
home.preferXdgDirectories = true;
|
home.preferXdgDirectories = true;
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,18 +1,21 @@
|
||||||
{ ... }:
|
{ config, ... }:
|
||||||
{
|
{
|
||||||
xdg.mimeApps.defaultApplications = {
|
xdg.mimeApps = {
|
||||||
# Media
|
enable = config.xdg.enable;
|
||||||
"image/*" = [ "imv.desktop" ];
|
defaultApplications = {
|
||||||
"image/gif" = [ "mpv.desktop" ];
|
# Media
|
||||||
"video/*" = [ "mpv.desktop" ];
|
"image/*" = [ "imv.desktop" ];
|
||||||
|
"image/gif" = [ "mpv.desktop" ];
|
||||||
|
"video/*" = [ "mpv.desktop" ];
|
||||||
|
|
||||||
# Apps
|
# Apps
|
||||||
"inode/directory" = [ "pcmanfm-qt.desktop" ];
|
"inode/directory" = [ "pcmanfm-qt.desktop" ];
|
||||||
"text/plain" = [ "nvim.desktop" ];
|
"text/plain" = [ "nvim.desktop" ];
|
||||||
|
|
||||||
# Browser
|
# Browser
|
||||||
"application/x-mswinurl" = [ "librewolf.desktop" ];
|
"application/x-mswinurl" = [ "librewolf.desktop" ];
|
||||||
"x-scheme-handler/http" = [ "librewolf.desktop" ];
|
"x-scheme-handler/http" = [ "librewolf.desktop" ];
|
||||||
"x-scheme-handler/https" = [ "librewolf.desktop" ];
|
"x-scheme-handler/https" = [ "librewolf.desktop" ];
|
||||||
|
};
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,17 +1,20 @@
|
||||||
{ config, ... }:
|
{ config, ... }:
|
||||||
{
|
{
|
||||||
xdg.userDirs = {
|
xdg.userDirs = with config.home; {
|
||||||
enable = config.home.desktop.enable;
|
enable = config.xdg.enable;
|
||||||
createDirectories = true;
|
createDirectories = true;
|
||||||
|
|
||||||
desktop = null;
|
desktop = null;
|
||||||
pictures = "${config.home.homeDirectory}/Photos";
|
|
||||||
music = null;
|
music = null;
|
||||||
|
pictures = "${homeDirectory}/Photos";
|
||||||
publicShare = null;
|
publicShare = null;
|
||||||
templates = null;
|
templates = null;
|
||||||
|
|
||||||
extraConfig = {
|
extraConfig = {
|
||||||
XDG_PERSIST_DIR = if !config.targets.genericLinux.enable then "/persist${config.home.homeDirectory}" else "${config.home.homeDirectory}/.stow";
|
XDG_GAMES_DIR = "${homeDirectory}/Games";
|
||||||
|
XDG_KEEPERS_DIR = "${homeDirectory}/Keepers";
|
||||||
|
XDG_PERSIST_DIR = if !config.targets.genericLinux.enable then "/persist${homeDirectory}" else "${homeDirectory}/.stow";
|
||||||
|
XDG_PROJECTS_DIR = "${homeDirectory}/Projects";
|
||||||
XDG_SCREENSHOTS_DIR = "${config.xdg.userDirs.pictures}/Screenshots";
|
XDG_SCREENSHOTS_DIR = "${config.xdg.userDirs.pictures}/Screenshots";
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
|
@ -1,10 +1,6 @@
|
||||||
{ config, lib, ... }:
|
{ ... }:
|
||||||
{
|
{
|
||||||
options.look.border = lib.mkOption {
|
look.border = rec {
|
||||||
type = lib.types.attrs;
|
|
||||||
};
|
|
||||||
|
|
||||||
config.look.border = rec {
|
|
||||||
int = 3;
|
int = 3;
|
||||||
string = toString int;
|
string = toString int;
|
||||||
};
|
};
|
||||||
|
|
|
@ -1,10 +1,6 @@
|
||||||
{ config, lib, ... }:
|
{ ... }:
|
||||||
{
|
{
|
||||||
options.look.colors = lib.mkOption {
|
look.colors = {
|
||||||
type = lib.types.attrs;
|
|
||||||
};
|
|
||||||
|
|
||||||
config.look.colors = {
|
|
||||||
prime = "3823C4"; #3823C4
|
prime = "3823C4"; #3823C4
|
||||||
accent = "1B1F59"; #1B1F59
|
accent = "1B1F59"; #1B1F59
|
||||||
split = "555B9E"; #555B9E
|
split = "555B9E"; #555B9E
|
||||||
|
|
|
@ -1,8 +1,12 @@
|
||||||
{ ... }:
|
{ config, lib, ... }:
|
||||||
{
|
{
|
||||||
imports = [
|
imports = [
|
||||||
./border
|
./border
|
||||||
./colors
|
./colors
|
||||||
./fonts
|
./fonts
|
||||||
];
|
];
|
||||||
|
|
||||||
|
options.look = lib.mkOption {
|
||||||
|
type = lib.types.attrs;
|
||||||
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,10 +1,6 @@
|
||||||
{ config, lib, ... }:
|
{ ... }:
|
||||||
{
|
{
|
||||||
options.look.fonts = lib.mkOption {
|
look.fonts = {
|
||||||
type = lib.types.attrs;
|
|
||||||
};
|
|
||||||
|
|
||||||
config.look.fonts = {
|
|
||||||
main = "Ubuntu";
|
main = "Ubuntu";
|
||||||
mono = "UbuntuMono Nerd Font";
|
mono = "UbuntuMono Nerd Font";
|
||||||
};
|
};
|
||||||
|
|
|
@ -1,245 +1,237 @@
|
||||||
{ config, lib, pkgs, ... }:
|
{ config, lib, pkgs, ... }:
|
||||||
{
|
{
|
||||||
programs.waybar = let
|
programs.waybar = let
|
||||||
workspaceModule = {
|
commonModules = {
|
||||||
format = "{name}";
|
"sway/workspaces" = {
|
||||||
enable-bar-scroll = true;
|
format = "{name}";
|
||||||
disable-scroll-wraparound = true;
|
enable-bar-scroll = true;
|
||||||
numeric-first = true;
|
disable-scroll-wraparound = true;
|
||||||
warp-on-scroll = false;
|
numeric-first = true;
|
||||||
};
|
warp-on-scroll = false;
|
||||||
|
|
||||||
windowModule = {
|
|
||||||
icon = true;
|
|
||||||
icon-size = 15;
|
|
||||||
all-outputs = true;
|
|
||||||
tooltip = false;
|
|
||||||
rewrite = {
|
|
||||||
"(.*) — LibreWolf" = " $1";
|
|
||||||
"LibreWolf" = " Firefox";
|
|
||||||
"(.*) - LibreWolf — Firefox" = " $1";
|
|
||||||
};
|
};
|
||||||
};
|
|
||||||
|
|
||||||
pulseModule = with pkgs; {
|
"sway/window" = {
|
||||||
format = "{icon} {volume}%";
|
icon = true;
|
||||||
format-bluetooth = "{icon} {volume}%";
|
icon-size = 15;
|
||||||
format-muted = " muted";
|
all-outputs = true;
|
||||||
format-icons = {
|
tooltip = false;
|
||||||
headphone = " ";
|
};
|
||||||
headset = " ";
|
|
||||||
default = [
|
"pulseaudio" = with pkgs; {
|
||||||
" "
|
format = "{icon} {volume}%";
|
||||||
" "
|
format-bluetooth = "{icon} {volume}%";
|
||||||
|
format-muted = " muted";
|
||||||
|
format-icons = {
|
||||||
|
headphone = " ";
|
||||||
|
headset = " ";
|
||||||
|
default = [
|
||||||
|
" "
|
||||||
|
" "
|
||||||
|
];
|
||||||
|
};
|
||||||
|
on-click = "${wireplumber}/bin/wpctl set-mute @DEFAULT_AUDIO_SINK@ toggle";
|
||||||
|
on-click-middle = "${wireplumber}/bin/wpctl set-volume @DEFAULT_AUDIO_SINK@ 100%";
|
||||||
|
on-click-right = "${wireplumber}/bin/wpctl set-volume @DEFAULT_AUDIO_SINK@ 60%";
|
||||||
|
ignored-sinks = [ "Easy Effects Sink" ];
|
||||||
|
};
|
||||||
|
|
||||||
|
"mpris" = {
|
||||||
|
player = "mpd";
|
||||||
|
format = " {title}";
|
||||||
|
format-paused = " {artist}";
|
||||||
|
format-stopped = "";
|
||||||
|
tooltip-format = lib.concatStrings [
|
||||||
|
"{title} - {artist} - {album}\n"
|
||||||
|
"{position}/{length}"
|
||||||
|
];
|
||||||
|
interval = 2;
|
||||||
|
max-length = 30;
|
||||||
|
};
|
||||||
|
|
||||||
|
"custom/notifs" = with pkgs; {
|
||||||
|
exec = pkgs.writeScript "notificationScript.sh" ''
|
||||||
|
#!/bin/sh
|
||||||
|
|
||||||
|
SED="${gnused}/bin/sed"
|
||||||
|
MAKOCTL="${mako}/bin/makoctl"
|
||||||
|
|
||||||
|
# Extract the second line after "default"
|
||||||
|
mode=$(echo "$($MAKOCTL mode)" | $SED -n '/default/{n;p}')
|
||||||
|
|
||||||
|
# Print the notification status with the tooltip
|
||||||
|
if [[ "$mode" == "do-not-disturb" ]]; then
|
||||||
|
printf '{"text":" Off","class":"disabled","tooltip":"Notifications Disabled."}'
|
||||||
|
else
|
||||||
|
printf '{"text":" On","tooltip":"Notifications Enabled."}';
|
||||||
|
fi
|
||||||
|
'';
|
||||||
|
format = "{}";
|
||||||
|
return-type = "json";
|
||||||
|
interval = 2;
|
||||||
|
on-click = "${mako}/bin/makoctl mode -t do-not-disturb";
|
||||||
|
};
|
||||||
|
|
||||||
|
"idle_inhibitor" = {
|
||||||
|
format = "{icon}";
|
||||||
|
format-icons = {
|
||||||
|
activated = " On";
|
||||||
|
deactivated = " Off";
|
||||||
|
tooltip-format-activated = "Sleep inhibited.";
|
||||||
|
tooltip-format-deactivated = "Sleep uninhibited.";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
"custom/weather" = {
|
||||||
|
exec = "${pkgs.wttrbar}/bin/wttrbar --ampm";
|
||||||
|
format = "{}°";
|
||||||
|
tooltip = true;
|
||||||
|
return-type = "json";
|
||||||
|
interval = 3600;
|
||||||
|
};
|
||||||
|
|
||||||
|
"cpu" = {
|
||||||
|
format = " {usage}%";
|
||||||
|
interval = 3;
|
||||||
|
};
|
||||||
|
|
||||||
|
"memory" = {
|
||||||
|
format = " {used}G";
|
||||||
|
tooltip = false;
|
||||||
|
interval = 3;
|
||||||
|
};
|
||||||
|
|
||||||
|
"custom/vram" = {
|
||||||
|
exec = with pkgs; pkgs.writeScript "vramScript.sh" ''
|
||||||
|
#!/bin/sh
|
||||||
|
|
||||||
|
LSPCI="${pciutils}/bin/lspci"
|
||||||
|
GREP="${gnugrep}/bin/grep"
|
||||||
|
AWK="${gawk}/bin/awk"
|
||||||
|
BC="${bc}/bin/bc"
|
||||||
|
HEAD="${uutils-coreutils-noprefix}/bin/head"
|
||||||
|
CAT="${uutils-coreutils-noprefix}/bin/cat"
|
||||||
|
NVIDIA="/run/current-system/sw/bin/nvidia-smi"
|
||||||
|
|
||||||
|
# Detect the active GPU driver
|
||||||
|
gpu_driver="$($LSPCI -k | $GREP -Eo 'in use: (nvidia|amdgpu)' | $AWK '{print $3}')"
|
||||||
|
|
||||||
|
# Exit if no supported GPU driver is in use
|
||||||
|
if [[ -z "$gpu_driver" ]]; then
|
||||||
|
exit 0
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Get VRAM usage in MB
|
||||||
|
if [[ "$gpu_driver" == "nvidia" ]]; then
|
||||||
|
vram_usage_mb="$($NVIDIA --query-gpu=memory.used --format=csv,noheader,nounits | $HEAD -n1)"
|
||||||
|
elif [[ "$gpu_driver" == "amdgpu" ]]; then
|
||||||
|
vram_bytes="$($CAT /sys/class/drm/card*/device/mem_info_vram_used 2>/dev/null | $HEAD -n1)"
|
||||||
|
vram_usage_mb="$($BC <<< "$vram_bytes / 1024 / 1024")"
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Format VRAM usage for display
|
||||||
|
if [[ "$vram_usage_mb" -lt 1024 ]]; then
|
||||||
|
vram_usage_display="''${vram_usage_mb}M"
|
||||||
|
else
|
||||||
|
vram_usage_gib="$($BC <<< "scale=2; $vram_usage_mb / 1024")"
|
||||||
|
vram_usage_display="''${vram_usage_gib}G"
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Output the VRAM usage
|
||||||
|
echo "{\"text\": \" ''${vram_usage_display}\"}"
|
||||||
|
'';
|
||||||
|
format = "{}";
|
||||||
|
return-type = "json";
|
||||||
|
interval = 3;
|
||||||
|
};
|
||||||
|
|
||||||
|
"backlight" = {
|
||||||
|
format = "{icon} {percent}%";
|
||||||
|
format-icons = [
|
||||||
|
""
|
||||||
|
""
|
||||||
|
];
|
||||||
|
tooltip = false;
|
||||||
|
};
|
||||||
|
|
||||||
|
"battery" = {
|
||||||
|
interval = 60;
|
||||||
|
states = {
|
||||||
|
warning = 30;
|
||||||
|
critical = 15;
|
||||||
|
};
|
||||||
|
format = "{icon} {capacity}%";
|
||||||
|
format-icons = [
|
||||||
|
""
|
||||||
|
""
|
||||||
|
""
|
||||||
|
""
|
||||||
|
""
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
on-click = "${wireplumber}/bin/wpctl set-mute @DEFAULT_AUDIO_SINK@ toggle";
|
|
||||||
on-click-middle = "${wireplumber}/bin/wpctl set-volume @DEFAULT_AUDIO_SINK@ 100%";
|
|
||||||
on-click-right = "${wireplumber}/bin/wpctl set-volume @DEFAULT_AUDIO_SINK@ 60%";
|
|
||||||
ignored-sinks = [ "Easy Effects Sink" ];
|
|
||||||
};
|
|
||||||
|
|
||||||
# Monitoring
|
"clock" = {
|
||||||
cpuModule = {
|
interval = 1;
|
||||||
format = " {usage}%";
|
format = "{:%a %b %d %I:%M:%S%p}";
|
||||||
interval = 3;
|
tooltip-format = "<tt><small>{calendar}</small></tt>";
|
||||||
};
|
|
||||||
|
|
||||||
ramModule = {
|
|
||||||
format = " {used}G";
|
|
||||||
tooltip = false;
|
|
||||||
interval = 3;
|
|
||||||
};
|
|
||||||
|
|
||||||
vramModule = {
|
|
||||||
exec = with pkgs; pkgs.writeScript "vramScript.sh" ''
|
|
||||||
#!/bin/sh
|
|
||||||
|
|
||||||
LSPCI="${pciutils}/bin/lspci"
|
|
||||||
GREP="${gnugrep}/bin/grep"
|
|
||||||
AWK="${gawk}/bin/awk"
|
|
||||||
BC="${bc}/bin/bc"
|
|
||||||
HEAD="${uutils-coreutils-noprefix}/bin/head"
|
|
||||||
CAT="${uutils-coreutils-noprefix}/bin/cat"
|
|
||||||
NVIDIA="/run/current-system/sw/bin/nvidia-smi"
|
|
||||||
|
|
||||||
# Detect the active GPU driver
|
|
||||||
gpu_driver="$($LSPCI -k | $GREP -Eo 'in use: (nvidia|amdgpu)' | $AWK '{print $3}')"
|
|
||||||
|
|
||||||
# Exit if no supported GPU driver is in use
|
|
||||||
if [[ -z "$gpu_driver" ]]; then
|
|
||||||
exit 0
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Get VRAM usage in MB
|
|
||||||
if [[ "$gpu_driver" == "nvidia" ]]; then
|
|
||||||
vram_usage_mb="$($NVIDIA --query-gpu=memory.used --format=csv,noheader,nounits | $HEAD -n1)"
|
|
||||||
elif [[ "$gpu_driver" == "amdgpu" ]]; then
|
|
||||||
vram_bytes="$($CAT /sys/class/drm/card*/device/mem_info_vram_used 2>/dev/null | $HEAD -n1)"
|
|
||||||
vram_usage_mb="$($BC <<< "$vram_bytes / 1024 / 1024")"
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Format VRAM usage for display
|
|
||||||
if [[ "$vram_usage_mb" -lt 1024 ]]; then
|
|
||||||
vram_usage_display="''${vram_usage_mb}M"
|
|
||||||
else
|
|
||||||
vram_usage_gib="$($BC <<< "scale=2; $vram_usage_mb / 1024")"
|
|
||||||
vram_usage_display="''${vram_usage_gib}G"
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Output the VRAM usage
|
|
||||||
echo "{\"text\": \" ''${vram_usage_display}\"}"
|
|
||||||
'';
|
|
||||||
format = "{}";
|
|
||||||
return-type = "json";
|
|
||||||
interval = 3;
|
|
||||||
};
|
|
||||||
|
|
||||||
# Clocks
|
|
||||||
clockModule = {
|
|
||||||
interval = 1;
|
|
||||||
format = "{:%a %b %d %I:%M:%S%p}";
|
|
||||||
tooltip-format = "<tt><small>{calendar}</small></tt>";
|
|
||||||
};
|
|
||||||
|
|
||||||
# Misc
|
|
||||||
trayModule.spacing = 5;
|
|
||||||
|
|
||||||
# Wireless
|
|
||||||
networkModule = {
|
|
||||||
format-ethernet = "";
|
|
||||||
format-wifi = "";
|
|
||||||
format-disconnected = "";
|
|
||||||
format-linked = "";
|
|
||||||
tooltip-format-ethernet = lib.concatStrings [
|
|
||||||
"{ipaddr}\n"
|
|
||||||
"{ifname} "
|
|
||||||
];
|
|
||||||
tooltip-format-wifi = lib.concatStrings [
|
|
||||||
"{ipaddr}\n"
|
|
||||||
"{essid} ({signalStrength}%)"
|
|
||||||
];
|
|
||||||
tooltip-format-disconnected = "Disconnected";
|
|
||||||
};
|
|
||||||
|
|
||||||
bluetoothModule = {
|
|
||||||
format = "";
|
|
||||||
format-disabled = "";
|
|
||||||
format-no-controller = "";
|
|
||||||
tooltip-format-on = "No devices connected.";
|
|
||||||
tooltip-format-connected = lib.concatStrings [
|
|
||||||
"{num_connections} connected\n"
|
|
||||||
"{device_enumerate}"
|
|
||||||
];
|
|
||||||
tooltip-format-enumerate-connected = "{device_alias}";
|
|
||||||
tooltip-format-enumerate-connected-battery = "{device_alias} {device_battery_percentage}%";
|
|
||||||
};
|
|
||||||
|
|
||||||
scratchpadModule = {
|
|
||||||
format = " {count}";
|
|
||||||
show-empty = false;
|
|
||||||
tooltip = true;
|
|
||||||
tooltip-format = "{title}";
|
|
||||||
};
|
|
||||||
|
|
||||||
gamemodeModule = {
|
|
||||||
format = "{glyph}";
|
|
||||||
hide-not-running = true;
|
|
||||||
use-icon = true;
|
|
||||||
icon-size = 19;
|
|
||||||
icon-spacing = 0;
|
|
||||||
tooltip = true;
|
|
||||||
};
|
|
||||||
|
|
||||||
privacyModule = {
|
|
||||||
icon-spacing = 5;
|
|
||||||
icon-size = 15;
|
|
||||||
};
|
|
||||||
|
|
||||||
mprisModule = {
|
|
||||||
player = "mpd";
|
|
||||||
format = " {title}";
|
|
||||||
format-paused = " {artist}";
|
|
||||||
format-stopped = "";
|
|
||||||
tooltip-format = lib.concatStrings [
|
|
||||||
"{title} - {artist} - {album}\n"
|
|
||||||
"{position}/{length}"
|
|
||||||
];
|
|
||||||
interval = 2;
|
|
||||||
max-length = 30;
|
|
||||||
};
|
|
||||||
|
|
||||||
notificationModule = with pkgs; {
|
|
||||||
exec = pkgs.writeScript "notificationScript.sh" ''
|
|
||||||
#!/bin/sh
|
|
||||||
|
|
||||||
SED="${gnused}/bin/sed"
|
|
||||||
MAKOCTL="${mako}/bin/makoctl"
|
|
||||||
|
|
||||||
# Extract the second line after "default"
|
|
||||||
mode=$(echo "$($MAKOCTL mode)" | $SED -n '/default/{n;p}')
|
|
||||||
|
|
||||||
# Print the notification status with the tooltip
|
|
||||||
if [[ "$mode" == "do-not-disturb" ]]; then
|
|
||||||
printf '{"text":" Off","class":"disabled","tooltip":"Notifications Disabled."}'
|
|
||||||
else
|
|
||||||
printf '{"text":" On","tooltip":"Notifications Enabled."}';
|
|
||||||
fi
|
|
||||||
'';
|
|
||||||
format = "{}";
|
|
||||||
return-type = "json";
|
|
||||||
interval = 2;
|
|
||||||
on-click = "${mako}/bin/makoctl mode -t do-not-disturb";
|
|
||||||
};
|
|
||||||
|
|
||||||
idleModule = {
|
|
||||||
format = "{icon}";
|
|
||||||
format-icons = {
|
|
||||||
activated = " On";
|
|
||||||
deactivated = " Off";
|
|
||||||
tooltip-format-activated = "Sleep inhibited.";
|
|
||||||
tooltip-format-deactivated = "Sleep uninhibited.";
|
|
||||||
};
|
};
|
||||||
};
|
|
||||||
|
|
||||||
weatherModule = {
|
"sway/scratchpad" = {
|
||||||
exec = "${pkgs.wttrbar}/bin/wttrbar --ampm";
|
format = " {count}";
|
||||||
format = "{}°";
|
show-empty = false;
|
||||||
tooltip = true;
|
tooltip = true;
|
||||||
return-type = "json";
|
tooltip-format = "{title}";
|
||||||
interval = 3600;
|
};
|
||||||
};
|
|
||||||
|
"privacy" = {
|
||||||
# Laptop modules
|
icon-spacing = 5;
|
||||||
backlightModule = {
|
icon-size = 15;
|
||||||
format = "{icon} {percent}%";
|
};
|
||||||
format-icons = [
|
|
||||||
""
|
"gamemode" = {
|
||||||
""
|
format = "{glyph}";
|
||||||
];
|
hide-not-running = true;
|
||||||
tooltip = false;
|
use-icon = true;
|
||||||
};
|
icon-size = 19;
|
||||||
|
icon-spacing = 0;
|
||||||
batteryModule = {
|
tooltip = true;
|
||||||
interval = 60;
|
};
|
||||||
states = {
|
|
||||||
warning = 30;
|
"tray".spacing = 5;
|
||||||
critical = 15;
|
|
||||||
|
"bluetooth" = {
|
||||||
|
format = "";
|
||||||
|
format-disabled = "";
|
||||||
|
format-no-controller = "";
|
||||||
|
tooltip-format-on = "No devices connected.";
|
||||||
|
tooltip-format-connected = lib.concatStrings [
|
||||||
|
"{num_connections} connected\n"
|
||||||
|
"{device_enumerate}"
|
||||||
|
];
|
||||||
|
tooltip-format-enumerate-connected = "{device_alias}";
|
||||||
|
tooltip-format-enumerate-connected-battery = "{device_alias} {device_battery_percentage}%";
|
||||||
|
};
|
||||||
|
|
||||||
|
"network" = {
|
||||||
|
format-ethernet = "";
|
||||||
|
format-wifi = "";
|
||||||
|
format-disconnected = "";
|
||||||
|
format-linked = "";
|
||||||
|
tooltip-format-ethernet = lib.concatStrings [
|
||||||
|
"{ipaddr}\n"
|
||||||
|
"{ifname} "
|
||||||
|
];
|
||||||
|
tooltip-format-wifi = lib.concatStrings [
|
||||||
|
"{ipaddr}\n"
|
||||||
|
"{essid} ({signalStrength}%)"
|
||||||
|
];
|
||||||
|
tooltip-format-disconnected = "Disconnected";
|
||||||
};
|
};
|
||||||
format = "{icon} {capacity}%";
|
|
||||||
format-icons = [
|
|
||||||
""
|
|
||||||
""
|
|
||||||
""
|
|
||||||
""
|
|
||||||
""
|
|
||||||
];
|
|
||||||
};
|
};
|
||||||
in {
|
in {
|
||||||
enable = config.home.desktop.enable;
|
enable = config.home.desktop.enable;
|
||||||
systemd.enable = true;
|
systemd.enable = true;
|
||||||
settings = {
|
settings = {
|
||||||
displayPrimary = {
|
displayPrimary = commonModules // {
|
||||||
name = "bar1";
|
name = "bar1";
|
||||||
position = "top";
|
position = "top";
|
||||||
layer = "top";
|
layer = "top";
|
||||||
|
@ -272,27 +264,9 @@
|
||||||
"bluetooth"
|
"bluetooth"
|
||||||
"network"
|
"network"
|
||||||
];
|
];
|
||||||
"sway/workspaces" = workspaceModule;
|
|
||||||
"sway/window" = windowModule;
|
|
||||||
"pulseaudio" = pulseModule;
|
|
||||||
"mpris" = mprisModule;
|
|
||||||
"custom/notifs" = notificationModule;
|
|
||||||
"idle_inhibitor" = idleModule;
|
|
||||||
"custom/weather" = weatherModule;
|
|
||||||
"cpu" = cpuModule;
|
|
||||||
"memory" = ramModule;
|
|
||||||
"custom/vram" = vramModule;
|
|
||||||
"backlight" = backlightModule;
|
|
||||||
"battery" = batteryModule;
|
|
||||||
"clock" = clockModule;
|
|
||||||
"sway/scratchpad" = scratchpadModule;
|
|
||||||
"privacy" = privacyModule;
|
|
||||||
"tray" = trayModule;
|
|
||||||
"bluetooth" = bluetoothModule;
|
|
||||||
"network" = networkModule;
|
|
||||||
};
|
};
|
||||||
|
|
||||||
displaySecondary = {
|
displaySecondary = commonModules // {
|
||||||
name = "bar2";
|
name = "bar2";
|
||||||
position = "top";
|
position = "top";
|
||||||
layer = "top";
|
layer = "top";
|
||||||
|
@ -312,13 +286,6 @@
|
||||||
"custom/vram"
|
"custom/vram"
|
||||||
"clock"
|
"clock"
|
||||||
];
|
];
|
||||||
"sway/workspaces" = workspaceModule;
|
|
||||||
"sway/window" = windowModule;
|
|
||||||
"pulseaudio" = pulseModule;
|
|
||||||
"cpu" = cpuModule;
|
|
||||||
"memory" = ramModule;
|
|
||||||
"custom/vram" = vramModule;
|
|
||||||
"clock" = clockModule;
|
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -331,38 +298,21 @@
|
||||||
font-size: 15.5px;
|
font-size: 15.5px;
|
||||||
color: #${config.look.colors.text};
|
color: #${config.look.colors.text};
|
||||||
}
|
}
|
||||||
#waybar {
|
|
||||||
background: #${config.look.colors.dark};
|
#waybar { background: #${config.look.colors.dark}; }
|
||||||
}
|
#tray { padding: 0 2px 0 5px; }
|
||||||
#workspaces {
|
#network { padding: 0 10px 0 4px; }
|
||||||
padding: 0 6px 0 0;
|
#scratchpad, #privacy { margin-left: 4px; }
|
||||||
}
|
#pulseaudio { margin-right: 5px; }
|
||||||
#tray {
|
#mpris, #custom-notifs, #idle_inhibitor, #custom-weather, #cpu, #memory, #custom-vram, #backlight, #battery { margin: 0 5px 0 2px; }
|
||||||
padding: 0 2px 0 5px;
|
|
||||||
}
|
#workspaces { padding: 0 6px; }
|
||||||
#network {
|
|
||||||
padding: 0 10px 0 4px;
|
|
||||||
}
|
|
||||||
#bluetooth {
|
|
||||||
margin: 0 6px 0 4px;
|
|
||||||
font-size: 13.4px;
|
|
||||||
}
|
|
||||||
#workspaces button {
|
#workspaces button {
|
||||||
padding: 0 3px;
|
padding: 0 3px;
|
||||||
color: white;
|
color: white;
|
||||||
border-bottom: 3px solid transparent;
|
border-bottom: 3px solid transparent;
|
||||||
min-width: 20px;
|
min-width: 20px;
|
||||||
}
|
}
|
||||||
#scratchpad, #privacy {
|
|
||||||
margin-left: 4px;
|
|
||||||
}
|
|
||||||
#mpris, #custom-notifs, #idle_inhibitor, #custom-weather, #cpu, #memory, #custom-vram, #backlight, #battery {
|
|
||||||
margin: 0 5px 0 2px;
|
|
||||||
}
|
|
||||||
#pulseaudio {
|
|
||||||
margin-right: 5px;
|
|
||||||
}
|
|
||||||
|
|
||||||
#workspaces button.visible, #workspaces button.active {
|
#workspaces button.visible, #workspaces button.active {
|
||||||
border-bottom: 3px solid #${config.look.colors.prime};
|
border-bottom: 3px solid #${config.look.colors.prime};
|
||||||
background: #${config.look.colors.mid};
|
background: #${config.look.colors.mid};
|
||||||
|
@ -374,44 +324,25 @@
|
||||||
box-shadow: none;
|
box-shadow: none;
|
||||||
background: #${config.look.colors.light};
|
background: #${config.look.colors.light};
|
||||||
}
|
}
|
||||||
#mpris {
|
|
||||||
border-bottom: 3px solid #ffb066;
|
#bluetooth {
|
||||||
}
|
margin: 0 6px 0 4px;
|
||||||
#custom-notifs {
|
font-size: 13.4px;
|
||||||
border-bottom: 3px solid #3823C4;
|
|
||||||
}
|
|
||||||
#idle_inhibitor {
|
|
||||||
border-bottom: 3px solid #941efc;
|
|
||||||
}
|
|
||||||
#custom-weather {
|
|
||||||
border-bottom: 3px solid #ea60e3;
|
|
||||||
}
|
|
||||||
#cpu {
|
|
||||||
border-bottom: 3px solid #f90000;
|
|
||||||
}
|
|
||||||
#memory {
|
|
||||||
border-bottom: 3px solid #4bffdc;
|
|
||||||
}
|
|
||||||
#custom-vram {
|
|
||||||
border-bottom: 3px solid #33FF00;
|
|
||||||
}
|
|
||||||
#backlight {
|
|
||||||
border-bottom: 3px solid #5ffca3;
|
|
||||||
}
|
|
||||||
#battery {
|
|
||||||
border-bottom: 3px solid #fcfc16;
|
|
||||||
}
|
|
||||||
#clock {
|
|
||||||
border-bottom: 3px solid #0a6cf5;
|
|
||||||
margin: 0 2px 0 2px;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
#mpris.paused, #custom-notifs.disabled, #idle_inhibitor.deactivated {
|
#mpris { border-bottom: 3px solid #ffb066; }
|
||||||
color: #888;
|
#custom-notifs { border-bottom: 3px solid #3823C4; }
|
||||||
}
|
#idle_inhibitor { border-bottom: 3px solid #941efc; }
|
||||||
#pulseaudio.muted, #network.disconnected, #bluetooth.off {
|
#custom-weather { border-bottom: 3px solid #ea60e3; }
|
||||||
color: #424242;
|
#cpu { border-bottom: 3px solid #f90000; }
|
||||||
}
|
#memory { border-bottom: 3px solid #4bffdc; }
|
||||||
|
#custom-vram { border-bottom: 3px solid #33FF00; }
|
||||||
|
#backlight { border-bottom: 3px solid #5ffca3; }
|
||||||
|
#battery { border-bottom: 3px solid #fcfc16; }
|
||||||
|
#clock { border-bottom: 3px solid #0a6cf5; }
|
||||||
|
|
||||||
|
#mpris.paused, #custom-notifs.disabled, #idle_inhibitor.deactivated { color: #888; }
|
||||||
|
#pulseaudio.muted, #network.disconnected, #bluetooth.off { color: #424242; }
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -11,9 +11,8 @@
|
||||||
keybindings = {
|
keybindings = {
|
||||||
## Launchers
|
## Launchers
|
||||||
|
|
||||||
# Browser profiles
|
# Browser
|
||||||
"${primeMod}+F1" = ''exec librewolf -p Main --name MainBrowser | notify-send "Main Browser"'';
|
"${primeMod}+F1" = ''exec librewolf | notify-send "Browser"'';
|
||||||
"${primeMod}+F2" = ''exec librewolf -p Alt --name AltBrowser | notify-send "Alternate Browser"'';
|
|
||||||
|
|
||||||
# Virtual machines
|
# Virtual machines
|
||||||
"${primeMod}+F4" = ''exec virt-manager | notify-send "Virtual Machines"'';
|
"${primeMod}+F4" = ''exec virt-manager | notify-send "Virtual Machines"'';
|
||||||
|
@ -148,6 +147,7 @@
|
||||||
|
|
||||||
# Change layout
|
# Change layout
|
||||||
"${primeMod}+f" = ''fullscreen toggle'';
|
"${primeMod}+f" = ''fullscreen toggle'';
|
||||||
|
"${primeMod}+${secMod}+f" = ''fullscreen toggle global'';
|
||||||
"${primeMod}+w" = ''layout toggle split'';
|
"${primeMod}+w" = ''layout toggle split'';
|
||||||
"${primeMod}+v" = ''split v'';
|
"${primeMod}+v" = ''split v'';
|
||||||
"${primeMod}+e" = ''layout toggle tabbed stacking'';
|
"${primeMod}+e" = ''layout toggle tabbed stacking'';
|
||||||
|
|
|
@ -55,9 +55,8 @@
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
assigns = {
|
assigns = {
|
||||||
# Browsers
|
# Browser
|
||||||
"1:${config.ws.w1}" = [{ app_id = "MainBrowser"; }];
|
"1:${config.ws.w1}" = [{ app_id = "librewolf"; }];
|
||||||
"11:${config.ws.w1a}" = [{ app_id = "AltBrowser"; }];
|
|
||||||
|
|
||||||
# Communication
|
# Communication
|
||||||
"7:${config.ws.w7}" = [
|
"7:${config.ws.w7}" = [
|
||||||
|
|
|
@ -2,6 +2,13 @@
|
||||||
{
|
{
|
||||||
programs.gamemode = {
|
programs.gamemode = {
|
||||||
enable = config.system.desktop.enable;
|
enable = config.system.desktop.enable;
|
||||||
settings.general.renice = 10;
|
settings = {
|
||||||
|
general.renice = 10;
|
||||||
|
gpu = {
|
||||||
|
amd_performance_level = "high";
|
||||||
|
apply_gpu_optimisations = "accept-responsibility";
|
||||||
|
gpu_device = 0;
|
||||||
|
};
|
||||||
|
};
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue