dendritic: rewrote entire config

This commit is contained in:
2026-05-23 20:18:11 +02:00
parent a93284ff80
commit c8ee6d85fe
190 changed files with 6764 additions and 8101 deletions
-1
View File
@@ -1 +0,0 @@
This modules must be host independent.
+1
View File
@@ -0,0 +1 @@
NixOS modules and home-manager modules with their scripts for most of my Applications
+67
View File
@@ -0,0 +1,67 @@
{ inputs, ... }: {
flake.nixosModules.anki = { pkgs, ... }: {
environment.systemPackages = [
(pkgs.anki.withAddons [
(pkgs.ankiAddons.recolor.withConfig {
config = {
# we must specify all the colors or it crashes as this overwrite the whole colors set
colors = {
# ===== Foregrounds =====
FG = ["Foreground" "#ebdbb2" "#ebdbb2" ""];
FG_SUBTLE = ["Subtle FG" "#d5c4a1" "#d5c4a1" ""];
FG_FAINT = ["Faint FG" "#a89984" "#a89984" ""];
FG_DISABLED = ["Disabled FG" "#928374" "#928374" ""];
# ===== Main Background Layers =====
BG = ["Background" "#1d2021" "#1d2021" ""];
MAIN_BG = ["Main Background" "#1d2021" "#1d2021" ""];
VIEW_BG = ["View Background" "#282828" "#282828" ""];
EDITOR_BG = ["Editor Background" "#282828" "#282828" ""];
CANVAS = ["Canvas" "#282828" "#282828" ""];
CANVAS_ELEVATED = ["Elevated Canvas" "#32302f" "#32302f" ""];
# ===== Tables & Lists =====
TABLE_BG = ["Table Background" "#282828" "#282828" ""];
TABLE_ALT_BG = ["Table Alt Background" "#32302f" "#32302f" ""];
HEADER_BG = ["Header Background" "#3c3836" "#3c3836" ""];
SELECTED_BG = ["Selected Background" "#504945" "#504945" ""];
# ===== Borders =====
BORDER = ["Border" "#504945" "#504945" ""];
FAINT_BORDER = ["Faint Border" "#3c3836" "#3c3836" ""];
# ===== Buttons =====
BUTTON_GRADIENT_START = ["Button Start" "#3c3836" "#3c3836" ""];
BUTTON_GRADIENT_END = ["Button End" "#3c3836" "#3c3836" ""];
BUTTON_HOVER = ["Button Hover" "#665c54" "#665c54" ""];
# ===== Accent & Links =====
ACCENT = ["Accent" "#458588" "#458588" ""];
LINK = ["Link" "#83a598" "#83a598" ""];
LINK_HOVER = ["Link Hover" "#8ec07c" "#8ec07c" ""];
# ===== Status =====
WARNING = ["Warning" "#fe8019" "#fe8019" ""];
ERROR = ["Error" "#fb4934" "#fb4934" ""];
SUCCESS = ["Success" "#8ec07c" "#8ec07c" ""];
};
};
# version = { major = 3; minor = 1; };
# let nixpkgs handle the version
})
])
];
};
flake.homeModules.anki = { ... }: {
programs.anki = {
# we enable system wide with nixpkgs because it offers some addon configuration. We just use this for some config
#enable = true;
theme = "dark";
sync = {
autoSync = true;
autoSyncMediaMinutes = 10;
syncMedia = true;
};
};
};
}
+6
View File
@@ -0,0 +1,6 @@
{ ... }: {
# unused at the moment see ../hardware/battery.nix
flake.homeModules.batsignal = { ... }: {
services.batsignal.enable = true;
};
}
+679
View File
@@ -0,0 +1,679 @@
{ inputs, self, ...}: {
flake.nixosModules.browsers = { pkgs, pkgs-unstable, ...}: {
environment.systemPackages = with pkgs; [
chromium # used only to flash the firmware on my framework laptop 16 (keyboard.frame.work) as only chromium based browser support webHID.
pkgs-unstable.tor-browser
self.packages.custom-librewolfprofiles
(pkgs.callPackage ../../modules/scripts/librewolfprofiles.nix {}) # fzf librewolf profile selector
];
};
flake.homeModules.librewolf = { ... }: {
# adapted from https://github.com/contre95/dotfiles/blob/main/dotfiles/nixos/programs/librewolf.nix
home.sessionVariables = {
MOZ_ENABLE_WAYLAND = 1;
MOZ_USE_XINPUT2 = 1;
MOZ_DBUS_REMOTE = 1;
};
programs.librewolf = {
enable = true;
settings = {
"browser.profiles.enabled" = true;
# disabled until i find something that uses it.
"webgl.disabled" = true;
# settings = lib.mapAttrs' (n: lib.nameValuePair "pref.${n}") {
"app.update.auto" = true; # disable auto update
#"dom.security.https_only_mode" = true; # force https
"extensions.pocket.enabled" = false; # disable pocket
#"browser.quitShortcut.disabled" = true; # disable ctrl+q
"browser.download.panel.shown" = true; # show download panel
"signon.rememberSignons" = false; # disable saving passwords
"identity.fxaccounts.enabled" = false; # disable librewolf accounts
"app.shield.optoutstudies.enabled" = false; # disable shield studies
"browser.shell.checkDefaultBrowser" = false; # don't check if default browser
#"browser.bookmarks.restore_default_bookmarks" = false; # don't restore default bookmarks
# Download handling
#"browser.download.dir" = "/home/meain/down"; # default download dir
"browser.startup.page" = 3; # restore previous session
# UI changes
# "browser.uidensity" = 1; # enable dense UI
#"general.autoScroll" = true; # enable autoscroll
# "browser.compactmode.show" = true; # enable compact mode
# "browser.tabs.firefox-view" = false; # enable librewolf view
#"startup.homepage_welcome_url" =
# "https://metrics.internal.contre.io/d/cUITC74Vksd/podman-revamped?orgId=1&from=2026-02-23T19:29:26.304Z&to=2026-02-23T19:59:26.304Z&timezone=browser&var-Filters=&var-namespace=alloy&var-level=error&var-level=debug&var-level=info&var-level=warn&refresh=5s&kiosk=true"; # disable welcome page
"browser.newtabpage.enabled" = true; # disable new tab page
"full-screen-api.ignore-widgets" = true; # fullscreen within window
"browser.toolbars.bookmarks.visibility" = "newtab"; # hide bookmarks toolbar; always, never, newtab
"browser.aboutConfig.showWarning" = false; # disable warning about about:config
"media.videocontrols.picture-in-picture.video-toggle.enabled" = false; # disable picture in picture button
# Privacy
"privacy.resistFingerprinting" = true;
# "privacy.clearOnShutdown.cache" = false;
"privacy.clearOnShutdown.history" = false;
"privacy.clearHistory.cookiesAndStorage" = false;
"privacy.clearHistory.historyFormDataAndDownloads" = false;
"privacy.clearHistory.cache" = false;
"privacy.clearOnShutdown_v2.siteSettings" = false;
"privacy.clearOnShutdown_v2.cookiesAndStorage" = false;
"services.sync.prefs.sync.privacy.clearOnShutdown_v2.history" = false;
"services.sync.prefs.sync.privacy.clearOnShutdown_v2.siteSettings" = false;
"services.sync.prefs.sync.privacy.clearOnShutdown_v2.sessions" = false;
"services.sync.prefs.sync.privacy.clearOnShutdown_v2.cookies" = false;
"services.sync.prefs.sync.privacy.clearOnShutdown.history" = false;
"services.sync.prefs.sync.privacy.clearOnShutdown.siteSettings" = false;
"services.sync.prefs.sync.privacy.clearOnShutdown.sessions" = false;
"services.sync.prefs.sync.privacy.clearOnShutdown.cookies" = false;
"privacy.clearOnShutdown.cookies" = false;
"browser.discovery.enabled" = false; # disable discovery
"browser.search.suggest.enabled" = true; # disable search suggestions
"browser.contentblocking.category" = "standart"; # set tracking protection to standart to not interfer with adnauseam
"dom.private-attribution.submission.enabled" = false; # stop doing dumb stuff mozilla
"browser.protections_panel.infoMessage.seen" = true; # disable tracking protection info
# Theme
"toolkit.legacyUserProfileCustomizations.stylesheets" = true;
"svg.context-properties.content.enabled" = true;
"layout.css.color-mix.enabled" = true;
# Disable telemetry
"toolkit.telemetry.enabled" = false;
"toolkit.telemetry.unified" = false;
"browser.ping-centre.telemetry" = false;
"toolkit.telemetry.archive.enabled" = false;
"toolkit.telemetry.bhrPing.enabled" = false;
"toolkit.telemetry.updatePing.enabled" = false;
"browser.translations.automaticallyPopup" = false;
"toolkit.telemetry.hybridContent.enabled" = false;
"toolkit.telemetry.newProfilePing.enabled" = false;
"toolkit.telemetry.reportingpolicy.firstRun" = false;
"toolkit.telemetry.firstShutdownPing.enabled" = false;
"browser.newtabpage.activity-stream.telemetry" = false;
"toolkit.telemetry.shutdownPingSender.enabled" = false;
"browser.newtabpage.activity-stream.feeds.telemetry" = false;
"browser.tabs.loadInBackground" = true; # open new tab in background
"browser.tabs.loadBookmarksInTabs" = true; # open bookmarks in new tab
"browser.tabs.warnOnOpen" = false; # don't warn when opening multiple tabs
"browser.tabs.warnOnQuit" = false; # don't warn when closing multiple tabs
"browser.tabs.warnOnClose" = false; # don't warn when closing multiple tabs
"browser.tabs.loadDivertedInBackground" = false; # open new tab in background
"browser.tabs.warnOnCloseOtherTabs" = false; # don't warn when closing multiple tabs
"browser.tabs.closeWindowWithLastTab" = false; # don't close window when last tab is closed
# other
"media.autoplay.default" = 0; # enable autoplay on open
"devtools.toolbox.host" = "right"; # move devtools to right
"devtools.theme" = "dark";
# "browser.ssb.enabled" = true; # enable site specific browser
"media.rdd-vpx.enabled" = true; # enable hardware acceleration
"devtools.cache.disabled" = true; # disable caching in devtools
"media.ffmpeg.vaapi.enabled" = true; # enable hardware acceleration
# Fonts
"font.size.fixed.x-western" = 15;
"font.minimum-size.x-western" = 13;
"font.size.variable.x-western" = 15;
"font.size.monospace.x-western" = 15;
"browser.display.use_document_fonts" = 1;
"browser.link.open_newwindow.restriction" = 0;
#
# "browser.fixup.domainsuffixwhitelist.home" = true;
# "browser.fixup.domainwhitelist.internal.contre.io" = true;
"extensions.activeThemeID" = "firefox-compact-dark@mozilla.org";
# "keyword.enable" = false; # Disable search when typing unexistent TLD
};
policies = {
ExtensionSettings = {
# the extension id should be from the manifesto and not a random name.
# if you dont know it. Put a random name. It will fail. Go to about:polices#error and the error will give you the correct id.
"enhancerforyoutube@maximerf.addons.mozilla.org" = {
installation_mode = "normal_installed";
install_url = "https://addons.mozilla.org/firefox/downloads/latest/enhancer-for-youtube/latest.xpi";
};
"sponsorBlocker@ajay.app" = {
install_url = "https://addons.mozilla.org/firefox/downloads/latest/sponsorblock/latest.xpi";
installation_mode = "force_installed";
};
"adnauseam@rednoise.org" = {
install_url = "https://addons.mozilla.org/firefox/downloads/latest/adnauseam/latest.xpi";
installation_mode = "force_installed";
};
"uBlock0@raymondhill.net" = {
install_url = "https://addons.mozilla.org/firefox/downloads/latest/ublock-origin/latest.xpi";
installation_mode = "force_installed";
};
"{08d5243b-4236-4a27-984b-1ded22ce01c3}" = {
install_url = "https://addons.mozilla.org/firefox/downloads/file/3729287/gruvboxgruvboxgruvboxgruvboxgr-1.0.xpi";
installation_mode = "force_installed";
};
"trackmenot@mrl.nyu.edu" = {
install_url = "https://addons.mozilla.org/firefox/downloads/latest/trackmenot/latest.xpi";
installation_mode = "force_installed";
};
"{446900e4-71c2-419f-a6a7-df9c091e268b}" = {
install_url = "https://addons.mozilla.org/firefox/downloads/file/4749958/bitwarden_password_manager-latest.xpi";
installation_mode = "force_installed";
};
};
DisableTelemetry = true;
DisableFirefoxStudies = true;
EnableTrackingProtection = {
Value = true;
Locked = true;
Cryptomining = true;
Fingerprinting = true;
};
DisablePocket = true;
DisableAccounts = true;
DisableFirefoxScreenshots = true;
# OverrideFirstRunPage = "";
# OverridePostUpdatePage = "";
DontCheckDefaultBrowser = true;
DisplayBookmarksToolbar = "always"; # alternatives: "always" or "newtab"
DisplayMenuBar = "never"; # alternatives: "always", "never" or "default-on"
SearchBar = "unified"; # alternative: "separate"
};
profiles.work = {
id = 0;
# userChrome = builtins.readFile ./userChrome.css;
# userContent = builtins.readFile ./userChrome.css;
extensions = {
#force = true;
#settings = {
# "adnauseam@rednoise.org".settings = {
# # Core behavior
# filteringEnabled = true;
#
# hidingAds = true;
# blockingMalware = true;
# clickingAds = true;
#
# # Privacy
# disableClickingForDNT = true;
# blockSocialMediaWidgets = false;
#
# # Filter lists
# selectedFilterLists = [
# "adnauseam-filters"
# "easylist"
# "easyprivacy"
# "ublock-badware"
# "ublock-privacy"
# "ublock-unbreak"
# ];
#
# # Advanced
# advancedUserEnabled = false;
# dynamicFilteringEnabled = false;
#
# # UI
# showIconBadge = true;
# parseTextAds = true;
# eventLogging = false;
# };
# "trackmenot@mrl.nyu.edu".settings = {
# enabled = true;
# # Query behavior
# runAtStartup = true;
# useTab = false; # don't open visible tab
# showQueries = false; # don't display fake queries
# # Frequency (seconds between bursts)
# timeout = 600; # 10 minutes
# burstEnabled = true;
# burstTimeout = 20; # burst interval
# burstCount = 5;
# # Query source
# useRssFeeds = true; # use dynamic trending feeds
# useUserQueries = false; # don't mix your real queries
# useBlackList = true;
# # Search engines to generate noise for
# searchEngines = {
# google = true;
# bing = false;
# yahoo = false;
# baidu = false;
# duckduckgo = false;
# };
# # Logging
# enableLogging = false;
# };
# "sponsorBlocker@ajay.app".settings = {
# # Core behavior
# isEnabled = true;
# autoSkip = false;
# showSkipNotice = true;
# # this does not work
# # Segment categories (auto-skip behavior)
# categoryChooser = {
# Sponsor = {
# enabled = true;
# skipOption = "manualSkip";
# };
# intro = {
# enabled = true;
# actionType = 2;
# };
# outro = {
# enabled = true;
# actionType = 2;
# };
# selfpromo = {
# enabled = true;
# actionType = 2;
# };
# interaction = {
# enabled = true;
# actionType = 1; # 1 = manual skip
# };
# music_offtopic = {
# enabled = false;
# actionType = 0;
# };
# preview = {
# enabled = false;
# actionType = 0;
# };
# };
# # Privacy
# disableTelemetry = true;
# showDonationLink = false;
# # UX
# showUpsells = false;
# hideSkipButtonPlayerControls = false;
# # Advanced
# useLocalCache = true;
# trackViewCount = false;
# };
#};
};
bookmarks = {
force = true;
settings = [
{
name = "Nixos Config";
tags = ["github"];
keyword = "github";
url = "https://github.com/tomasriveral/nixos";
}
{
name = "Public AI";
tags = ["ai" "chatgpt" "apertus"];
keyword = "apertus";
url = "https://chat.publicai.co/";
}
{
name = "Signs of AI writing";
tags = ["ai" "write"];
keyword = "AI writing";
url = "https://en.wikipedia.org/wiki/Wikipedia:Signs_of_AI_writing";
}
{
name = "nixpkgs-review-gha";
tags = ["nixpkgs-review" "gha"];
keyword = "nixpkgs-review";
url = "https://github.com/tomasriveral/nixpkgs-review-gha/actions/workflows/review.yml";
}
{
name = "nixpkgs tracker";
tags = ["nixpkgs" "tracker"];
keyword = "nixpkgs tracker";
url = "https://nixpk.gs/pr-tracker.html";
}
{
name = "fahrlehrer";
tags = ["theorie" "fahrlehrer" "conduite"];
keyword = "fahrlehrer24";
url = "https://app.fahrlehrer24.ch/";
}
{
name = "cogito";
tags = ["cogito" "esprit" "critique"];
keyword = "Cogito l'Esprit critique";
url = "https://app.cogito.fr";
}
];
};
search = {
force = true;
default = "quant";
privateDefault = "qant";
order = [
"q"
"map"
"np"
"nw"
"bookmarks"
"tabs"
"history"
];
engines = {
# don't need these default ones
"amazondotcom-es".metaData.hidden = true;
"bing".metaData.hidden = true;
"ebay".metaData.hidden = true;
"metager".metaData.hidden = true; # dont work
"mojeek".metaData.hidden = true; # dont work
"seerx".metaData.hidden = true;
"perplexity".metaData.hidden = true;
"google".metaData.hidden = true;
"startpage".metaData.hidden = true;
"duckduckgo".metaData.hidden = true;
"Wikitionary" = {
urls = [
{
template = "https://fr.wiktionary.org/w/index.php?search={searchTerms}";
}
];
definedAliases = ["dict"];
};
"quant" = {
urls = [
{
template = "https://www.qwant.com/";
params = [
{
name = "q";
value = "{searchTerms}";
}
];
}
];
definedAliases = ["q"];
};
"OpenStreeetMap" = {
urls = [
{
template = "https://www.openstreetmap";
params = [
{
name = "q";
value = "{searchTerms}";
}
];
}
];
definedAliases = ["map"];
};
"Home Manager Options" = {
urls = [
{
template = "https://home-manager-options.extranix.com/";
params = [
{
name = "query";
value = "{searchTerms}";
}
];
}
];
definedAliases = ["hm"];
};
"Nix Packages" = {
urls = [
{
template = "https://search.nixos.org/packages";
params = [
{
name = "type";
value = "packages";
}
{
name = "query";
value = "{searchTerms}";
}
];
}
];
definedAliases = ["np"];
};
"Nix Wiki" = {
urls = [
{
template = "https://wiki.nixos.org/w/index.php?search={searchTerms}";
}
];
definedAliases = ["nw"];
};
"Repology" = {
urls = [
{
template = "https://repology.org/projects/?search={searchTerms}";
}
];
definedAliases = ["rp"];
};
};
};
};
profiles.other = {
id = 1;
# userChrome = builtins.readFile ./userChrome.css;
# userContent = builtins.readFile ./userChrome.css;
extensions = {
#force = false;
#settings = {
# "adnauseam@rednoise.org".settings = {
# # Core behavior
# filteringEnabled = true;
#
# hidingAds = true;
# blockingMalware = true;
# clickingAds = true;
#
# # Privacy
# disableClickingForDNT = true;
# blockSocialMediaWidgets = false;
#
# # Filter lists
# selectedFilterLists = [
# "adnauseam-filters"
# "easylist"
# "easyprivacy"
# "ublock-badware"
# "ublock-privacy"
# "ublock-unbreak"
# ];
#
# # Advanced
# advancedUserEnabled = false;
# dynamicFilteringEnabled = false;
#
# # UI
# showIconBadge = true;
# parseTextAds = true;
# eventLogging = false;
# };
# "trackmenot@mrl.nyu.edu".settings = {
# enabled = true;
# # Query behavior
# runAtStartup = true;
# useTab = false; # don't open visible tab
# showQueries = false; # don't display fake queries
# # Frequency (seconds between bursts)
# timeout = 600; # 10 minutes
# burstEnabled = true;
# burstTimeout = 20; # burst interval
# burstCount = 5;
# # Query source
# useRssFeeds = true; # use dynamic trending feeds
# useUserQueries = false; # don't mix your real queries
# useBlackList = true;
# # Search engines to generate noise for
# searchEngines = {
# google = true;
# bing = false;
# yahoo = false;
# baidu = false;
# duckduckgo = false;
# };
# # Logging
# enableLogging = false;
# };
# "sponsorBlocker@ajay.app".settings = {
# # Core behavior
# isEnabled = true;
# autoSkip = false;
# showSkipNotice = true;
# # this does not work
# # Segment categories (auto-skip behavior)
# categoryChooser = {
# Sponsor = {
# enabled = true;
# skipOption = "manualSkip";
# };
# intro = {
# enabled = true;
# actionType = 2;
# };
# outro = {
# enabled = true;
# actionType = 2;
# };
# selfpromo = {
# enabled = true;
# actionType = 2;
# };
# interaction = {
# enabled = true;
# actionType = 1; # 1 = manual skip
# };
# music_offtopic = {
# enabled = false;
# actionType = 0;
# };
# preview = {
# enabled = false;
# actionType = 0;
# };
# };
# # Privacy
# disableTelemetry = true;
# showDonationLink = false;
# # UX
# showUpsells = false;
# hideSkipButtonPlayerControls = false;
# # Advanced
# useLocalCache = true;
# trackViewCount = false;
# };
#};
};
search = {
force = true;
default = "quant";
privateDefault = "qant";
order = [
"q"
"map"
"np"
"nw"
"bookmarks"
"tabs"
"history"
];
engines = {
# don't need these default ones
"amazondotcom-es".metaData.hidden = true;
"bing".metaData.hidden = true;
"ebay".metaData.hidden = true;
"metager".metaData.hidden = true; # dont work
"mojeek".metaData.hidden = true; # dont work
"seerx".metaData.hidden = true;
"perplexity".metaData.hidden = true;
"google".metaData.hidden = true;
"startpage".metaData.hidden = true;
"duckduckgo".metaData.hidden = true;
"quant" = {
urls = [
{
template = "https://www.qwant.com/";
params = [
{
name = "q";
value = "{searchTerms}";
}
];
}
];
definedAliases = ["q"];
};
"OpenStreeetMap" = {
urls = [
{
template = "https://www.openstreetmap";
params = [
{
name = "q";
value = "{searchTerms}";
}
];
}
];
definedAliases = ["map"];
};
"Onche.org" = {
urls = [
{
template = "https://onche.org/forum/1/blabla-general/search?by=topic&q={searchTerms}";
}
];
definedAliases = ["on"];
};
};
};
};
};
};
flake.packages.custom-librewolfprofiles = { pkgs, ... }:
# fzf librewolf profile selector
pkgs.writeShellApplication {
name = "custom-librewolfprofiles";
runtimeInputs = with pkgs; [
zsh
fzf
];
text = ''
# List of profiles
profiles=("work" "other" "private window")
# Use fzf to select
selected=$(printf "%s\n" "''${profiles[@]}" | fzf --height 6 --reverse --prompt="Select LibreWolf profile:")
# If user cancels, exit
[[ -z "$selected" ]] && exit 0
# Launch LibreWolf detached, keeping environment
if [[ "$selected" == "private window" ]]; then
setsid librewolf --private-window --no-remote >/dev/null 2>&1 &
pkill -f "kitty.*Select LibreWolf profile"
else
setsid librewolf -P "$selected" --no-remote >/dev/null 2>&1 &
pkill -f "kitty.*Select LibreWolf profile"
fi
# Exit the kitty terminal after selection
exit
'';
};
}
+611
View File
@@ -0,0 +1,611 @@
{ self, ... }: {
flake.nixosModules.caelestia = { pkgs, ... }: {
qt.enable = true;
# to resolve this https://wiki.nixos.org/wiki/Home_Manager#I_cannot_set_GNOME_or_Gtk_themes_via_Home_Manager
programs.dconf.enable = true;
environment.systemPackages = with pkgs; [
self.packages.${pkgs.system}.qtbatticon
kdePackages.qtdeclarative # provides qmlls and other things
quickshell # we have it but adding it there solves "WARN qt.qpa.services: Failed to register with host portal QDBusError("org.freedesktop.portal.Error.Failed", "Could not register app ID: App info not found for 'org.quickshell'")"
];
};
flake.homeModules.caelestia = { ... }: let
sisyphe = ../../assets/sisyphe.gif;
pepe-music = ../../assets/pepe-music.gif;
in {
home.file.".local/state/caelestia/wallpaper/path.txt" = {
# dummy file. Does nothing. Prevent an error
enable = true;
text = "${sisyphe}";
};
home.file.".face" = {
# this is were caelestia will search for profiles pictures
source = ../../assets/sisyphePFP.png;
};
# set profile picture in ~/.face
programs.caelestia = {
enable = true;
systemd = {
enable = false; # if we launch it form here, the keybinds don't work
target = "graphical-session.target";
environment = [];
};
settings = {
# default config https://github.com/caelestia-dots/shell?tab=readme-ov-file#example-configuration
appearance = {
mediaGifSpeedAdjustment = 500;
sessionGifSpeed = 0.7;
anim = {
duration = {
scale = 1;
};
};
/*
font = {
family = {
clock = "Rubik"; # (TODO figure out those fonts)
material = "Material Symboles Rounded";
mono = "CaskaydiaCove NF";
sans = "Rubik";
};
size = {
scale = 1;
};
};
*/
padding = {
scale = 1;
};
rounding = {
scale = 1;
};
spacing = {
scale = 1;
};
transparency = {
enabled = false;
base = 0.85;
layeres = 0.4;
};
};
general = {
logo = "caelestia";
apps = {
terminal = ["kitty"]; # default foot
audio = ["pavucontrol"];
playback = ["vlc"]; # what's that?
explorer = ["dolphin"]; # default thunar
};
battery = {
wanLevels = [
{
level = 20;
title = "Low battery";
message = "You might want to plug in a charger";
icon = "battery_android_frame_2";
}
{
level = 10;
title = "Did you see the previous message?";
message = "You should probably plug in a charger <b>now</b>";
icon = "battery_android_frame_1";
}
{
level = 5;
title = "Critical battery level";
message = "PLUG THE CHARGER RIGHT NOW!!";
icon = "battery_android_alert";
critical = true;
}
];
criticalLevel = 3;
};
idle = {
lockBeforeSleep = true;
inhibitWhenAudio = true;
timeouts = [
{
timeout = 180;
idleAction = "lock";
}
{
timeout = 300;
idleAction = "dpms off"; # what's that?
returnAction = "dpms on";
}
{
timeout = 600;
idleAction = ["systemctl" "suspend-then-hibernate"];
}
];
};
};
background = {
desktopClock = {
enabled = false;
scale = 1.0;
position = "bottom-right";
shadow = {
enabled = true;
opacity = 0.7;
blur = 0.4;
};
background = {
enabled = false;
opacity = 0.7;
blur = true;
};
invertColors = false;
};
enabled = false; #default true
visualiser = {
blur = false;
enabled = false;
autohide = true;
rounding = 1;
spacing = 1;
};
};
bar = {
activeWindow = {
compact = false;
inverted = false;
showOnHover = true;
};
clock = {
background = true;
showDate = true;
showIcon = true;
};
dragThreshold = 20;
entries = [
{
id = "logo";
enabled = true;
}
{
id = "workspaces";
enabled = true;
}
{
id = "spacer";
enabled = true;
}
{
id = "activeWindow";
enabled = true;
}
{
id = "spacer";
enabled = true;
}
{
id = "tray";
enabled = true;
}
{
id = "clock";
enabled = true;
}
{
id = "statusIcon";
enabled = true;
}
{
id = "power";
enabled = true;
}
];
persistent = true;
popouts = {
activeWindow = true;
statusIcon = true;
tray = true;
};
scrollActions = {
brightness = true;
workspaces = true;
volume = true;
};
showOnHover = true;
status = {
showAudio = false;
showBattery = false; # use powerprofile daemon
showBluetooth = false;
showKbLayout = false;
showMicrophone = false;
showNetwork = false;
showWifi = true;
showLockStatus = false;
};
tray = {
background = true; # default true
compact = false;
iconSubs = [];
recolour = true;
};
workspaces = {
activeIndicator = true;
activeLabel = "󰮯";
activeTrail = false;
label = " ";
occupiedBg = false;
occpiedLabel = "󰮯";
perMonitorWorkspaces = true;
showWindows = true;
shown = 5;
specialWorkspaceIcons = [
{
name = "steam";
icon = "sports_esports";
}
];
windowIcons = [
{
regex = "steam(_app_(default|[0-9]+))?";
icon = "sports_esports";
}
];
};
excludedScreens = [""]; # default says "" those this work?
};
border = {
rounding = 25;
thickness = 10;
};
dashboard = {
enabled = true;
dragThreshold = 50;
mediaUpdateInterval = 500;
showOnHover = true;
};
launcher = {
actionsPrefix = ">";
actions = [
{
name = "Calculator";
icon = "calculate";
description = "Do simple math equations (powered by Qalc)";
command = ["autocomplete" "calc"];
enabled = false; # default true
dangerous = false;
}
{
name = "Scheme";
icon = "palette";
description = "Change the current colour scheme";
command = ["autocomplete" "scheme"];
enabled = false; # default true
dangerous = false;
}
{
name = "Wallpaper";
icon = "image";
description = "Change the current wallpaper";
command = ["autocomplete" "wallpaper"];
enabled = false; # default true
dangerous = false;
}
{
name = "Variant"; # to remove
icon = "colors";
description = "Change the current scheme variant";
command = ["autocomplete" "variant"];
enabled = true;
dangerous = false;
}
{
name = "Transparency";
icon = "opacity";
description = "Change shell transparency";
command = ["autocomplete" "transparency"];
enabled = false;
dangerous = false;
}
{
name = "Random";
icon = "casino";
description = "Switch to a random wallpaper";
command = ["caelestia" "wallpaper" "-r"];
enabled = false; # default true
dangerous = false;
}
{
name = "Light";
icon = "light_mode";
description = "Change the scheme to light mode";
command = ["setMode" "light"];
enabled = false; # default true
dangerous = false;
}
{
name = "Dark";
icon = "dark_mode";
description = "Change the scheme to dark mode";
command = ["setMode" "dark"];
enabled = false; # default true
dangerous = false;
}
{
name = "Shutdown";
icon = "power_settings_new";
description = "Shutdown the system";
command = ["systemctl" "poweroff"];
enabled = true;
dangerous = true;
}
{
name = "Reboot";
icon = "cached";
description = "Reboot the system";
command = ["systemctl" "reboot"];
enabled = true;
dangerous = true;
}
{
name = "Lock"; # does this work with ly?
icon = "lock";
description = "Log out of the current session";
command = ["loginctl" "terminate-user" ""];
enabled = true;
dangerous = true;
}
{
name = "Sleep";
icon = "bedtime";
description = "Suspend then hibernate";
command = ["systemctl" "suspend-then-hibernate"];
enabled = true;
dangerous = false;
}
{
name = "Settings";
icon = "settings";
description = "Configure the shell";
command = ["caelestia" "shell" "controlCenter" "open"];
enabled = false; # default true
dangerous = false;
}
];
dragThreshold = 50;
vimKeybinds = false; # intersting to put to true
enableDangerousActions = false; # set to true
maxShown = 7;
maxWallpapers = 9;
specialPrefix = "@";
useFuzzy = {
# should try
apps = false;
actions = false;
schemes = false;
variants = false;
wallpapers = false;
};
showOnHover = false;
favouriteApps = [];
hiddenApps = [];
};
lock = {
recolourLogo = false; # what's that
hideNotifs = false;
};
notifs = {
actionOnClick = false;
clearThreshold = 0.3;
defaultExpireTimeout = 5000;
expantThreshold = 20;
openeExpanded = false;
expire = true;
};
osd = {
# thats the slider for brightness and sound
enabled = true;
enableBrightness = true;
enableMicrophone = false;
hideDelay = 2000;
};
paths = {
mediaGif = pepe-music; # default "root:/assets/bongocat.gif"
sessionGif = sisyphe; # default "root:/assets/kurukuru.gif"
noNotifsPic = "root:/assets/dino.png";
lockNoNotifsPic = "root:/assets/dino.png";
wallpaperDir = "~/Pictures/Wallpapers";
lyricsDir = "~/Music/lyrics";
};
services = {
audioIncrement = 0.1;
brightnessIncrement = 0.1;
maxVolume = 1.0;
defaultPlayer = "Spotify";
gpuType = "";
#playerAliases: [ { "from": "com.github.th_ch.youtube_music", "to": "YT Music" } ]; # how to put this into nix language?
weatherLocation = "Lausanne";
useFahrenheit = false;
useFahrenheitPerformance = false;
useTwelveHourClock = false;
smartScheme = false; # default true
visualisersBars = 45;
};
session = {
dragThreshold = 30; # what does dragThreshold do?
enabled = true;
vimKeybinds = false; # maybe set to true?
icons = {
logout = "logout";
shutdown = "power_settings_new";
hibernate = "downloading"; # find a better icon
reboot = "cached";
};
commands = {
logout = ["hyprctl" "dispatch exit"];
shutdown = ["systemctl" "poweroff"];
hibernate = ["systemctl" "hibernate"];
reboot = ["systemctl" "reboot"];
};
};
sidebar = {
dragThreshold = 80;
enabled = true;
};
# is there a way to get some system info?
utilities = {
enabled = true;
maxToasts = 4; # toats are like notification but on the botto left
toasts = {
audioInputChanged = true;
audioOutputChanged = true;
capsLockChanged = true;
chargingChanged = true;
configLoaded = true;
dndChanged = true;
gameModeChanged = true;
kbLayoutChanged = true;
kbLimit = true;
numLockChanged = true;
vpnChanged = true;
nowPlaying = false;
};
};
vpn = {
enabled = false; # default true
provider = [
{
# default example-configuration
name = "wireguard";
interface = "your-connection-name";
displayName = "wireguard (Your VPN)";
enabled = false;
}
];
};
quickToggles = [
{
id = "wifi";
enabled = true;
}
{
id = "bluetooth";
enabled = true;
}
{
id = "mic";
enabled = true;
}
{
id = "settings";
enabled = true; # should desactivate
}
{
id = "gameMode";
enabled = true; # should remap my performance mode
}
{
id = "dnd"; #do not disturb
enabled = true;
}
{
id = "vpn";
enabled = false; # default true;
}
];
};
cli = {
# default config https://github.com/caelestia-dots/cli?tab=readme-ov-file#configuring
enable = true; # Also add caelestia-cli to path
settings = {
record = {
extraArgs = [];
};
wallpaper = {
postHook = "caelestia scheme set -n gruvbox -f soft -m dark"; # sets the theme
};
theme = {
enableTerm = false; # we do it manually by adapting our kitty config
enableHypr = false; # this seems to add the splash
enableDiscord = true;
enableSpicetify = true;
enableFuzzel = true; #what's that?
enablleBtop = false; # default true
enableQt = true;
};
toggles = {
communication = {
discord = {
enable = false; # default true
match = [
{
class = "discord";
}
];
whatsapp = {
enable = true;
match = [
{
class = "whatsapp";
}
];
};
};
};
music = {
spotify = {
enable = false; # default true
match = [
{
class = "Spotify";
}
{
initialTitle = "Spotify";
}
{
initialTitle = "Spotify Free";
}
];
command = ["spicetify" "watch" "-s"];
move = true;
};
feishin = {
enable = true;
match = [
{
class = "feishin";
}
];
move = true;
};
};
sysmon = {
btop = {
enable = true;
match = [
{
class = "btop";
title = "btop";
workspace = {
name = "special:sysmon";
};
}
];
command = ["foot" "-a" "btop" "-T" "btop" "fish" "-C" "exec btop"]; # maybe switch to btm and kitty?
};
};
todo = {
todoist = {
enable = false; # default true
match = [
{
class = "Todoist";
}
];
command = ["todoist"];
move = true;
};
};
};
};
};
};
};
}
+115
View File
@@ -0,0 +1,115 @@
{ ... }: {
flake.homeModules.eza = { ... }: {
# ls replacement
# see ./zsh.nix for the alias (usefull to se default flags)
programs.eza = {
enable = true;
enableZshIntegration = true;
theme = {
# from https://github.com/eza-community/eza-themes/blob/main/themes/gruvbox-dark.yml
colourful = true;
filekinds = {
normal = {foreground = "#ebdbb2";};
directory = {foreground = "#83a598";};
symlink = {foreground = "#8ec07c";};
pipe = {foreground = "#928374";};
block_device = {foreground = "#fb4934";};
char_device = {foreground = "#fb4934";};
socket = {foreground = "#665c54";};
special = {foreground = "#d3869b";};
executable = {foreground = "#b8bb26";};
mount_point = {foreground = "#fe8019";};
};
perms = {
user_read = {foreground = "#ebdbb2";};
user_write = {foreground = "#fabd2f";};
user_execute_file = {foreground = "#b8bb26";};
user_execute_other = {foreground = "#b8bb26";};
group_read = {foreground = "#ebdbb2";};
group_write = {foreground = "#fabd2f";};
group_execute = {foreground = "#b8bb26";};
other_read = {foreground = "#bdae93";};
other_write = {foreground = "#fabd2f";};
other_execute = {foreground = "#b8bb26";};
special_user_file = {foreground = "#d3869b";};
special_other = {foreground = "#928374";};
attribute = {foreground = "#bdae93";};
};
size = {
major = {foreground = "#bdae93";};
minor = {foreground = "#8ec07c";};
number_byte = {foreground = "#ebdbb2";};
number_kilo = {foreground = "#ebdbb2";};
number_mega = {foreground = "#83a598";};
number_giga = {foreground = "#d3869b";};
number_huge = {foreground = "#d3869b";};
unit_byte = {foreground = "#bdae93";};
unit_kilo = {foreground = "#83a598";};
unit_mega = {foreground = "#d3869b";};
unit_giga = {foreground = "#d3869b";};
unit_huge = {foreground = "#fe8019";};
};
users = {
user_you = {foreground = "#ebdbb2";};
user_root = {foreground = "#fb4934";};
user_other = {foreground = "#d3869b";};
group_yours = {foreground = "#ebdbb2";};
group_other = {foreground = "#928374";};
group_root = {foreground = "#fb4934";};
};
links = {
normal = {foreground = "#8ec07c";};
multi_link_file = {foreground = "#fe8019";};
};
git = {
new = {foreground = "#b8bb26";};
modified = {foreground = "#fabd2f";};
deleted = {foreground = "#fb4934";};
renamed = {foreground = "#8ec07c";};
typechange = {foreground = "#d3869b";};
ignored = {foreground = "#928374";};
conflicted = {foreground = "#cc241d";};
};
git_repo = {
branch_main = {foreground = "#ebdbb2";};
branch_other = {foreground = "#d3869b";};
git_clean = {foreground = "#b8bb26";};
git_dirty = {foreground = "#fb4934";};
};
security_context = {
colon = {foreground = "#928374";};
user = {foreground = "#ebdbb2";};
role = {foreground = "#d3869b";};
typ = {foreground = "#665c54";};
range = {foreground = "#d3869b";};
};
file_type = {
image = {foreground = "#fabd2f";};
video = {foreground = "#fb4934";};
music = {foreground = "#b8bb26";};
lossless = {foreground = "#8ec07c";};
crypto = {foreground = "#928374";};
document = {foreground = "#ebdbb2";};
compressed = {foreground = "#d3869b";};
temp = {foreground = "#cc241d";};
compiled = {foreground = "#83a598";};
build = {foreground = "#928374";};
source = {foreground = "#83a598";};
punctuation = {foreground = "#928374";};
date = {foreground = "#fabd2f";};
inode = {foreground = "#bdae93";};
blocks = {foreground = "#a89984";};
header = {foreground = "#ebdbb2";};
octal = {foreground = "#8ec07c";};
flags = {foreground = "#d3869b";};
symlink_path = {foreground = "#8ec07c";};
control_char = {foreground = "#83a598";};
broken_symlink = {foreground = "#fb4934";};
broken_path_overlay = {foreground = "#928374";};
};
};
};
};
}
+176
View File
@@ -0,0 +1,176 @@
{ ... }: {
flake.homeModules.fastfetch = { ... }: {
# Adapted from https://github.com/dacrab/fastfetch-config/blob/main/config.jsonc
programs.fastfetch = {
enable = true;
settings = {
logo = {
type = "none";
#source = "nixos";
};
modules = [
# ───────────── Hardware ─────────────
{
type = "custom";
format = " Hardware ";
outputColor = "blue";
}
{
type = "title";
key = " PC";
keyColor = "green";
}
{
type = "host";
key = " 󰇅 Laptop";
keyColor = "green";
}
{
type = "display";
key = " 󰍹 Display";
keyColor = "green";
}
{
type = "cpu";
key = " 󰍛 CPU";
showPeCoreCount = true;
format = "{1}";
keyColor = "green";
}
{
type = "gpu";
key = " 󰍛 GPU";
keyColor = "green";
}
{
type = "memory";
key = " 󰍛 Memory";
keyColor = "green";
}
{
type = "custom";
format = "";
outputColor = "blue";
}
# ───────────── Software ─────────────
{
type = "custom";
format = " Software ";
outputColor = "blue";
}
{
type = "os";
key = " OS";
keyColor = "cyan";
}
{
type = "kernel";
key = " Kernel";
keyColor = "cyan";
}
{
type = "packages";
key = " 󰏖 Packages";
keyColor = "cyan";
}
{
type = "shell";
key = " Shell";
keyColor = "cyan";
}
{
type = "terminal";
key = " Terminal";
keyColor = "cyan";
}
{
type = "command";
key = " OS Age";
keyColor = "cyan";
text = ''
birth_install=$(stat -c %W /)
current=$(date +%s)
time_progression=$((current - birth_install))
days_difference=$((time_progression / 86400))
echo $days_difference days
'';
}
{
type = "uptime";
key = " Uptime";
keyColor = "cyan";
}
{
type = "de";
key = " DE";
keyColor = "blue";
}
{
type = "wm";
key = " WM";
keyColor = "magenta";
}
{
type = "gpu";
key = " 󰍛 GPU Driver";
format = "{3}";
keyColor = "magenta";
}
{
type = "brightness";
key = " 󰃟 Brightness";
keyColor = "magenta";
}
{
type = "version";
key = " FastFetch";
keyColor = "magenta";
}
{
type = "custom";
format = "";
outputColor = "blue";
}
#{
# type = "custom";
# format = ''
# {#0} {#1} {#2} {#3} {#4} {#5} {#6} {#7}
# '';
#} #for some reason dont work
{
type = "colors";
symbol = "diamond";
}
"break"
];
};
};
};
}
+9
View File
@@ -0,0 +1,9 @@
{ ... }: {
flake.nixosModules.games = {pkgs, ...}: {
environment.systemPackages = with pkgs; [
supertux # fuck mario
supertuxkart # fuck mariokart
# my favorite italian plumber is free software
];
};
}
+14
View File
@@ -0,0 +1,14 @@
{ ... }: {
flake.homeModules.git = { ... }: {
programs.git = {
enable = true;
settings = {
init.defaultBranch = "main";
};
};
programs.gh = {
enable = true;
gitCredentialHelper.enable = true;
};
};
}
+14
View File
@@ -0,0 +1,14 @@
{ ... }: {
flake.homeModules.gtk = {pkgs, ...}: {
# gtk config
gtk.theme = {
enable = true;
Gruvbox-GTK-Theme-BL-MB = {
enable = true;
name = "Gruvbox-GTK-Theme-BL-MB";
package = pkgs.gruvbox-gtk-theme;
};
};
# to resolve this https://wiki.nixos.org/wiki/Home_Manager#I_cannot_set_GNOME_or_Gtk_themes_via_Home_Manager
};
}
+23
View File
@@ -0,0 +1,23 @@
{ ... }: {
# this was in my home-manager config, but looks like more
flake.nixosModules.hypridle = { ... }: {
services.hypridle = {
enable = true;
settings = {
general = {
lock_cmd = "notify-send 'lock!'"; # dbus/sysd lock command (loginctl lock-session)
unlock_cmd = "notify-send 'unlock!'"; # same as above, but unlock
before_sleep_cmd = "notify-send 'Zzz'"; # command ran before sleep
after_sleep_cmd = "notify-send 'Awake!"; # command ran after sleep
ignore_dbus_inhibit = false; # whether to ignore dbus-sent idle-inhibit requests (used by e.g. firefox or steam)
ignore_systemd_inhibit = false; # whether to ignore systemd-inhibit --what=idle inhibitors
};
listener = {
timeout = 500; # in seconds
on-timeout = "notify-send 'You are idle!'"; # command to run when timeout has passed
on-resume = "notify-send 'Welcome back!'"; # command to run when activity is detected after timeout has fired.
};
};
};
};
}
+498
View File
@@ -0,0 +1,498 @@
{ self, ... }: {
flake.nixosModules.hyprland = { pkgs, pkgs-unstable, ... }: {
environment.systemPackages = with pkgs; [
swww #wallpaper daemon
gruvbox-gtk-theme
hyprcursor
capitaine-cursors-themed # cursor theme
papirus-icon-theme
papirus-folders
self.packages.${pkgs.system}.custom-wallpaper
self.packages.${pkgs.system}.custom-dontkillsteam # kill app (if not steam or tomato-c
self.packages.${pkgs.system}.custom-killall # kill all windows except focused window
xdg-utils
];
# enable hyprland WM
programs.hyprland = {
enable = true;
package = pkgs-unstable.hyprland; # we use the unstable branch to get the latest features
withUWSM = true;
xwayland.enable = true;
};
xdg.portal = {
enable = true;
extraPortals = [
pkgs.xdg-desktop-portal-wlr
pkgs.xdg-desktop-portal-gtk
];
};
# removes uxterm
services.xserver.excludePackages = [pkgs.xterm];
# Enable the X11 windowing system.
services.xserver.enable = true;
};
flake.homeModules.hyprland-laptop = { ... }: {
wayland.windowManager.hyprland.settings = {
exec-once = [
"qtbatticon" # custom battery tray
];
monitor = [
"eDP-1, highres@highrr, 0x0, 1"
];
};
};
flake.homeModules.hyprland = {pkgs-unstable, ...}: let
wallpaper = ../../assets/wallpaper1.jpg;
in {
#refer to https://wiki.hypr.land/Nix/Hyprland-on-Home-Manager/
wayland.windowManager.hyprland.enable = true;
wayland.windowManager.hyprland.package = pkgs-unstable.hyprland;
#hint Electron apps to use on wayland;
home.sessionVariables.NIXOS_OZONE_WL = "1";
wayland.windowManager.hyprland.plugins = [
#pkgs-unstable.hyprlandPlugins.hyprspace # currently broken
#pkgs-unstable.hyprlandPlugins.hypr-dynamic-cursors # currently broken
];
wayland.windowManager.hyprland.settings = {
"$mod" = "SUPER";
"$term" = "kitty";
"$editor" = "nvim";
"$notes" = "kitty --class \"custom-obsidianvaults\" --name \"Select Obsidian vault\" --hold custom-obsidianvaults";
"$file" = "dolphin";
"$browser" = "kitty --class \"custom-librewolfprofiles\" --name \"Select LibreWolf profile\" --hold custom-librewolfprofiles";
# ▄▀█ █▄░█ █ █▀▄▀█ ▄▀█ ▀█▀ █ █▀█ █▄░█
# █▀█ █░▀█ █ █░▀░█ █▀█ ░█░ █ █▄█ █░▀█
animations = {
enabled = true;
bezier = [
"wind, 0.05, 0.9, 0.1, 1.05"
"winIn, 0.1, 1.1, 0.1, 1.1"
"winOut, 0.3, -0.3, 0, 1"
"liner, 1, 1, 1, 1"
];
animation = [
"windows, 1, 6, wind, slide"
"windowsIn, 1, 6, winIn, slide"
"windowsOut, 1, 5, winOut, slide"
"windowsMove, 1, 5, wind, slide"
"border, 1, 1, liner"
"borderangle, 1, 30, liner, loop"
"fade, 1, 10, default"
"workspaces, 1, 5, wind"
];
};
# █▀▀ █▄░█ █░█
# ██▄ █░▀█ ▀▄▀
# See https://wiki.hyprland.org/Configuring/Environment-variables/
env = [
"PATH, $PATH:$scrPath"
"XDG_CURRENT_DESKTOP,Hyprland"
"XDG_SESSION_TYPE,wayland"
"XDG_SESSION_DESKTOP,Hyprland"
"QT_QPA_PLATFORM,wayland;xcb"
"QT_QPAPLATFORMTHEME,qt6ct"
"QT_WAYLAND_DISABLE_WINDOWDECORATION,1"
"MOZ_ENABLE_WAYLAND,1"
"GDK_SCALE,1"
];
# █ █▄░█ █▀█ █░█ ▀█▀
# █ █░▀█ █▀▀ █▄█ ░█░
input = {
kb_layout = ["ch"];
follow_mouse = 1;
sensitivity = 0;
force_no_accel = 1;
};
# █▄▀ █▀▀ █▄█ █▄▄ █ █▄░█ █▀▄ █ █▄░█ █▀▀ █▀
# █░█ ██▄ ░█░ █▄█ █ █░▀█ █▄▀ █ █░▀█ █▄█ ▄█
# caelestia shell drawers toggle dashboard
# caelestia shell drawers toggle utilities
bind = [
#hyprland/utility keybindings
"$mod, W, togglefloating"
"$mod, G, togglegroup"
"Alt, Return, fullscreen"
"$mod, Left, movefocus, l"
"$mod, Right, movefocus, r"
"$mod, Up, movefocus, u"
"$mod, Down, movefocus, d"
"Alt, Tab, movefocus, d"
"$mod, 1, workspace, 1"
"$mod, 2, workspace, 2"
"$mod, 3, workspace, 3"
"$mod, 4, workspace, 4"
"$mod, 5, workspace, 5"
"$mod, 6, workspace, 6"
"$mod, 7, workspace, 7"
"$mod, 8, workspace, 8"
"$mod, 9, workspace, 9"
"$mod, 0, workspace, 10"
"$mod+Ctrl, Right, workspace, r+1"
"$mod+Ctrl, Left, workspace, r-1"
"$mod+Ctrl, Doown, workspace, empty"
"$mod+Shift, 1, movetoworkspace, 1"
"$mod+Shift, 2, movetoworkspace, 2"
"$mod+Shift, 3, movetoworkspace, 3"
"$mod+Shift, 4, movetoworkspace, 4"
"$mod+Shift, 5, movetoworkspace, 5"
"$mod+Shift, 6, movetoworkspace, 6"
"$mod+Shift, 7, movetoworkspace, 7"
"$mod+Shift, 8, movetoworkspace, 8"
"$mod+Shift, 9, movetoworkspace, 9"
"$mod+Shift, 0, movetoworkspace, 10"
"$mod+Ctrl+Alt, Right, movetoworkspace, r+1"
"$mod+Ctrl+Alt, Left, movetoworkspace, r-1"
#"$mod, Backspace, exec, wlogout -b 4 -T 600 -B 600"
"$mod, Backspace, exec, caelestia shell drawers toggle session"
"$mod+Shift+Ctrl, Left, movewindow, l"
"$mod+Shift+Ctrl, Right, movewindow, r"
"$mod+Shift+Ctrl, Up, movewindow, u"
"$mod+Shift+Ctrl, Down, movewindow, d"
"$mod, mouse_down, workspace, e+1"
"$mod, mouse_up, workspace, e-1"
"$mod, V, exec, cliphist list | rofi -dmenu| cliphist decode | wl-copy" # copy paste
"$mod, B, exec, hyprkeys -bkr | rofi -dmenu"
#"$mod, A, tagwindow, noborder" # used to not apply image border
"$mod, S, togglespecialworkspace,"
"Alt+$mod, S, movetoworkspace, special"
# for the scrolling layout
"$mod, A, layoutmsg, move -col"
"$mod, D, layoutmsg, move +col"
#apps keybindings
"$mod, T, exec, $term"
"$mod, E, exec, $file"
"$mod, F, exec, $browser"
"$mod, N, exec, $notes"
#"$mod+Shift, A, exec, rofi -show drun"
"$mod+Shift, A, exec, caelestia shell drawers toggle launcher"
"$mod, Q, exec, custom-dontkillsteam"
#"Ctrl+Alt, W, exec, pkill waybar || waybar"
"Ctrl+Alt, W, exec, caelestia shell drawers toggle sidebar"
#"$mod, L, exec, swaylock -eFLK -i ${wallpaper}"
"$mod, L, exec, caelestia shell lock lock"
#"$mod, F11, exec, hyprshot -m window"
", F11, exec, caelestia screenshot"
#"$mod_SHIFT, S, exec, hyprshot -m region --clipboard only"
# "$mod_SHIFT, S, exec, qs ipc call screenshot toggle"
"$mod_SHIFT, S, exec, caelestia shell picker open"
# framework 16 rgb macropad
"Ctrl+$mod, 6, exec, custom-killall" # pos 1 1 killall apps except focused one
#"Ctrl+Alt, 7, exec, custom-performance" # pos 2 1 start performance mode
"Ctrl+Alt, 7, exec, caelestia shell gameMode toggle"
# reloads the autostart programs # pos 3 1
# we passed to caelestia-shell and stoped using that
/*
"Ctrl+$mod, 4, exec, sleep 1 && kitty -o font_size=16 -e sh -c 'custom-weather'"
"Ctrl+$mod, 4, exec, sleep 1 && kitty -o font_size=11 -e sh -c 'custom-cowsay'"
"Ctrl+$mod, 4, exec, kitty -e 'custom-launch'"
"Ctrl+$mod, 4, exec, sleep 1 && kitty -o font_size=5 -e btm --theme gruvbox --disable-click --disable_advanced_kill --enable_cache_memory -g -R -T "
"Ctrl+$mod, 4, exec, sleep 1 && kitty -o font_size=1 -e sh -c 'cmatrix -br'"
#"Ctrl+Alt, 1, exec, swaync-client -t" # pos 4 1 notification center
"Ctrl+Alt, 1, exec, qs ipc call notifications toggle"
*/
"Ctrl+Alt, 1, exec, caelestia shell drawers toggle sidebar"
"Ctrl+$mod, 4, exec, caelestia shell notifs toggleDnd"
"Ctrl+$mod, 3, exec, pavucontrol" # pos 1 2 audiocontrol
"Ctrl+Shift+Alt, 0, exec, kitty --hold --class \"custom-changeAudioOutput\" --name \"Select audio output\" zsh -c \"custom-changeAudioOutput\"" # pos 2 2 change audio output fzf
"Ctrl+$mod, 5, exec, gnome-characters" # pos 3 2 special chars
"Ctrl+Alt, 8, exec, hyprpicker | tee >(wl-copy) | cliphist store" # pos 4 2 colorpicker
"Ctrl+Alt, 0, exec, custom-tomato" # pos 1 3 pomodoro app
"Ctrl+Alt, 2, exec, custom-bottom" # pos 2 3 btm (like htop but cleaner)
"Ctrl+Alt, 9, exec, anki"
# if hyprexpo plugin enabled bind = $mainMod, Space, hyprexpo:expo, toggle
# maybe exec sudo framework-tools-tui
#plugins keybindings
#"$mod, SPACE, overview:toggle, "
];
binde = [
"$mod+Shift, Right, resizeactive, 30 0"
"$mod+Shift, Left, resizeactive, -30, 0"
"$mod+Shift, Up, resizeactive, 0 -30"
"$mod+Shift, Down, resizeactive,m 0 30"
];
bindl = [
", F1, exec, pactl set-sink-mute @DEFAULT_SINK@ toggle" #toggle audio mute
", F5, exec, playerctl play-pause" # media F4-F6
", F4, exec, playerctl previous"
", F6, exec, playerctl next"
];
bindel = [
", F2, exec, pactl set-sink-volume @DEFAULT_SINK@ -10%" # decrease volume
", F3, exec, pactl set-sink-volume @DEFAULT_SINK@ +10%" # increase volume
", F7, exec, brightnessctl s 10%-" # decrease brightness
", F8, exec, brightnessctl s +10%" # increase brightness
];
bindm = [
"$mod, mouse:272, movewindow"
"$mod, mouse:273, resizewindow"
"$mod, Z, movewindow"
"$mod, X, resizewindow"
];
# █░░ ▄▀█ █░█ █▄░█ █▀▀ █░█
# █▄▄ █▀█ █▄█ █░▀█ █▄▄ █▀█
exec-once = [
"dbus-update-activation-environment --systemd WAYLAND_DISPLAY XDG_CURRENT_DESKTOP" # for XDPH
"dbus-update-activation-environment --systemd --all" # for XDPH
"systemctl --user import-environment WAYLAND_DISPLAY XDG_CURRENT_DESKTOP" # for XDPH
"systemctl --user start xdg-desktop-portal-wlr.service"
"blueman-applet" # systray app for Bluetooth
"udiskie --no-automount --smart-tray" # front-end that allows to manage removable media
"nm-applet --indicator" # systray app for Network/wifi
#setups clipboard
"rm -rf ~/.cache/cliphist/ && wl-paste --type text --watch cliphist store & wl-paste --type image --watch cliphist store"
#"wl-paste --type text --watch cliphist store" # clipboard store text data
#"wl-paste --type image --watch cliphist store" # clipboard store image data
"custom-batterynotify"
"custom-batterywarning"
#"birdtray" # thunderbird tray app # curently broken
#wallpapers/b
"swww img ${wallpaper}"
"swww-daemon"
"sleep 1 && custom-wallpaper"
"custom-checkKdrive && custom-mountkdrive" # checks if the remote works and mount it
#"waybar"
"custom-gitnotify"
"custom-checkMatrix" # checks if matrix-commander-rs is connected which is important for other stuff
#"custom-obsidianbackup" # backups the obsidian notes to kdrive and to a timed hidden dir (~/.Notes.backup/)
#"QS-notifycache" # builds the cache that will be used for the notification history
"sleep 4 & caelestia-shell" #works better if it sleeps a bit before
/*
We stopped using that ######################### maybe we should desactivate those scripts
# login autostart
#######################
"[workspace 1 silent] sleep 1 && kitty -o font_size=16 -e sh -c 'custom-weather'"
"[workspace 1 silent] sleep 1 && kitty -o font_size=11 -e sh -c 'custom-cowsay'"
"[workspace 1 silent] kitty -e 'custom-launch'"
"[workspace 1 silent] sleep 1 && kitty -o font_size=5 -e btm --theme gruvbox --disable-click --disable_advanced_kill --enable_cache_memory -g -R -T "
"[workspace 1 silent] sleep 1 && kitty -o font_size=1 -e sh -c 'cmatrix -br'"
######################
######################
*/
];
splash = true; # remove default background on startup
# gestures (also keybindings)
gesture = [
"3, right, move, +col"
"3, left, move, -col"
];
# █░░ ▄▀█ █▄█ █▀█ █░█ ▀█▀ █▀
# █▄▄ █▀█ ░█░ █▄█ █▄█ ░█░ ▄█
dwindle = {
preserve_split = true;
};
scrolling = {
column_width = 0.45;
};
# █▀▄▀█ █ █▀ █▀▀
# █░▀░█ █ ▄█ █▄▄
misc = {
vrr = 0;
force_default_wallpaper = 0;
};
xwayland = {
force_zero_scaling = true;
};
# █▀▄▀█ █▀█ █▄░█ █ ▀█▀ █▀█ █▀█
# █░▀░█ █▄█ █#░▀█ █ ░█░ █▄█ █▀▄
monitor = [
#",preferred, auto, auto"
"HDMI-A-1, highres2highrr, auto-left, 1"
];
# _______ ___ __ __ _______ ___ __ _ _______
#| || | | | | || || | | | | || |
#| _ || | | | | || ___|| | | |_| || _____|
#| |_| || | | |_| || | __ | | | || |_____
#| ___|| |___ | || || || | | _ ||_____ |
#| | | || || |_| || | | | | | _____| |
#|___| |_______||_______||_______||___| |_| |__||_______|
#
"plugin:dynamic-cursors" = {
enabled = true;
threshold = 2;
mode = "rotate";
rotate = {
# length in px of the simulated stick used to rotate the cursor
# most realistic if this is your actual cursor size
length = 20;
offset = 0;
};
shake = {
enabled = true;
# use nearest-neighbour (pixelated) scaling when shaking
# may look weird when effects are enabled
nearest = true;
threshold = 4;
# magnification level immediately after shake start
base = 4.0;
# magnification increase per second when continuing to shake
speed = 4.0;
# how much the speed is influenced by the current shake intensitiy
influence = 0.0;
# maximal magnification the cursor can reach
# values below 1 disable the limit (e.g. 0)
limit = 0.0;
# time in millseconds the cursor will stay magnified after a shake has ended
timeout = 2000;
# show cursor behaviour `tilt`, `rotate`, etc. while shaking
effects = true;
# enable ipc events for shake
ipc = false;
};
};
"plugin:overview" = {
disableGestures = true;
showEmptyWorkspace = true;
workspaceActiveBorder = "rgb(ab7746)";
disableBlur = true;
};
#####################################################
#####################################################
# theme
decoration = {
dim_special = 0.3;
rounding = 18;
blur = {
special = true;
enabled = true;
size = 4;
passes = 2;
new_optimizations = true;
ignore_opacity = true;
};
};
general = {
gaps_in = 5;
gaps_out = 15;
border_size = 4;
"col.active_border" = "rgba(ca6702ff) rgba(ecd3a0ff) 45deg";
"col.inactive_border" = "rgba(f1dca7d9) rgba(ffe1a8d9) 45deg";
layout = "dwindle";
resize_on_border = true;
};
group = {
"col.border_active" = "rgba(ca6702ff) rgba(ecd3a0ff) 45deg";
"col.border_inactive" = "rgba(f1dca7d9) rgba(ffe1a8d9) 45deg";
"col.border_locked_active" = "rgba(ca6702ff) rgba(ecd3a0ff) 45deg";
"col.border_locked_inactive" = "rgba(f1dca7d9) rgba(ffe1a8d9) 45deg";
};
####################################################
##################################################
# /$$ /$$ /$$
#| $$ /$ | $$ | $$
#| $$ /$$$| $$ /$$$$$$ /$$$$$$ | $$ /$$ /$$$$$$$ /$$$$$$ /$$$$$$ /$$$$$$$ /$$$$$$
#| $$/$$ $$ $$ /$$__ $$ /$$__ $$| $$ /$$/ /$$_____/ /$$__ $$ |____ $$ /$$_____/ /$$__ $$
#| $$$$_ $$$$| $$ \ $$| $$ \__/| $$$$$$/ | $$$$$$ | $$ \ $$ /$$$$$$$| $$ | $$$$$$$$
#| $$$/ \ $$$| $$ | $$| $$ | $$_ $$ \____ $$| $$ | $$ /$$__ $$| $$ | $$_____/
#| $$/ \ $$| $$$$$$/| $$ | $$ \ $$ /$$$$$$$/| $$$$$$$/| $$$$$$$| $$$$$$$| $$$$$$$
#|__/ \__/ \______/ |__/ |__/ \__/|_______/ | $$____/ \_______/ \_______/ \_______/
# | $$
# | $$
# |__/
# see https://wiki.hypr.land/Configuring/Workspace-Rules/
workspace = [
"1, layout:master"
"2, layout:scrolling, layoutopt:direction:right"
"name:special, layout:scrolling"
# used for smart gaps along some windowrules
#"w[tv1], gapsout:1, gapsin:1"
#"f[1], gapsout:1, gapsin:1"
];
# █░█░█ █ █▄░█ █▀▄ █▀█ █░█░█   █▀█ █░█ █░░ █▀▀ █▀
# ▀▄▀▄▀ █ █░▀█ █▄▀ █▄█ ▀▄▀▄▀   █▀▄ █▄█ █▄▄ ██▄ ▄█
windowrule = [
"opacity 0.90 0.90, match:class ^(firefox)$"
"opacity 0.90 0.90, match:class ^(Brave-browser)$"
"opacity 0.80 0.80, match:class ^(code-oss)$"
"opacity 0.80 0.80, match:class ^(Code)$"
"opacity 0.80 0.80, match:class ^(code-url-handler)$"
"opacity 0.80 0.80, match:class ^(code-insiders-url-handler)$"
"opacity 0.75 0.75, match:class ^(kitty)$"
"opacity 0.80 0.80, match:class ^(org.kde.dolphin)$"
"opacity 0.80 0.80, float on, match:class ^(org.kde.ark)$"
"opacity 0.80 0.80, float on, match:class ^(nwg-look)$"
"opacity 0.80 0.80, float on, match:class ^(qt5ct)$"
"opacity 0.80 0.80, float on, match:class ^(qt6ct)$"
"opacity 0.80 0.80, float on, match:class ^(kvantummanager)$"
"opacity 0.80 0.70, float on, match:class ^(org.pulseaudio.pavucontrol)$"
"opacity 0.80 0.70, float on, match:class ^(blueman-manager)$"
"opacity 0.80 0.70, float on, match:class ^(nm-applet)$"
"opacity 0.80 0.70, float on, match:class ^(nm-connection-editor)$"
"opacity 0.80 0.70, float on, match:class ^(org.kde.polkit-kde-authentication-agent-1)$"
"opacity 0.80 0.70, match:class ^(polkit-gnome-authentication-agent-1)$"
"opacity 0.80 0.70, match:class ^(org.freedesktop.impl.portal.desktop.gtk)$"
"opacity 0.80 0.70, match:class ^(org.freedesktop.impl.portal.desktop.hyprland)$"
"opacity 0.70 0.70, match:class ^([Ss]team)$"
"opacity 0.70 0.70, match:class ^(steamwebhelper)$"
"opacity 0.70 0.70, match:class ^(Spotify)$"
"opacity 0.70 0.70, match:initial_title ^(Spotify Free)$"
"opacity 0.90 0.90, float on, match:class ^(com.github.rafostar.Clapper)$"
"opacity 0.80 0.80, match:class ^(com.github.tchx84.Flatseal)$"
"opacity 0.80 0.80, match:class ^(hu.kramo.Cartridges)$"
"opacity 0.80 0.80, match:class ^(com.obsproject.Studio)$"
"opacity 0.80 0.80, match:class ^(gnome-boxes)$"
"opacity 0.80 0.80, match:class ^(discord)$"
"opacity 0.80 0.80, match:class ^(WebCord)$"
"opacity 0.80 0.80, match:class ^(ArmCord)$"
"opacity 0.80 0.80, float on, match:class ^(app.drey.Warp)$"
"opacity 0.80 0.80, float on, match:class ^(net.davidotek.pupgui2)$"
"opacity 0.80 0.80, float on, match:class ^(yad)$"
"opacity 0.80 0.80, float on, match:class ^(Signal)$"
"opacity 0.80 0.80, float on, match:class ^(io.github.alainm23.planify)$"
"opacity 0.80 0.80, float on, match:class ^(io.gitlab.theevilskeleton.Upscaler)$"
"opacity 0.80 0.80, float on, match:class ^(com.github.unrud.VideoDownloader)$"
"opacity 0.80 0.80, float on, match:class ^(io.gitlab.adhami3310.Impression)$"
"opacity 0.80 0.80, float on, match:class ^(io.missioncenter.MissionCenter)$"
"opacity 0.80 0.80, match:class ^(io.github.flattool.Warehouse)$"
"float on, match:class ^(org.kde.dolphin)$, match:title ^(Progress Dialog Dolphin)$"
"float on, match:class ^(org.kde.dolphin)$, match:title ^(Copying Dolphin)$"
"float on, match:class ^(firefox)$, match:title ^(Picture-in-Picture)$"
"float on, match:class ^(firefox)$, match:title ^(Library)$"
"float on, match:class ^(kitty)$, match:title ^(top)$"
"float on, match:class ^(kitty)$, match:title ^(btop)$"
"float on, match:class ^(kitty)$, match:title ^(htop)$"
"float on, match:class ^(vlc)$"
"float on, match:class ^(eog)$"
"float on, size 400 225, match:class ^(custom-librewolfprofiles)$"
"float on, size 1050 200, match:class ^(custom-changeAudioOutput)$"
"float on, size 400 175, match:class ^(custom-obsidianvaults)$"
"float on, size 600 600, match:initial_class ^(custom-pomodoro)$"
"float on, size 1500 800, match:initial_class ^(custom-bottom)$"
# smart gaps/border is ugly with caelestia-shell
#"border_size 2, match:float 0, match:workspace w[tv1]"
#"rounding 1, match:float 0, match:workspace w[tv1]"
#"border_size 2, match:float 0, match:workspace f[1]"
#"rounding 1, match:float 0, match:workspace f[1]"
];
# add a float for tomato when in kitty
#"plugin:imgborders:noimgborders, tag:noborder"
layerrule = [
"blur on, ignore_alpha 0, match:namespace rofi"
"blur on, ignore_alpha 0, match:namespace notifications"
"blur on, ignore_alpha 0, match:namespace swaync-notification-window"
"blur on, ignore_alpha 0, match:namespace swaync-control-center"
"blur on, match:namespace logout_dialog"
];
};
};
}
+101
View File
@@ -0,0 +1,101 @@
{ self, ...}: {
# -----------------------------------------------------
# Here are a bunch of scripts that interact with hyprland
# Some are still used. Some are broken. Some are deprecated. But I do still keep them in case I want to go back to old tools
# -----------------------------------------------------
# kills the app, but when it's steam or custom-pomodoro
flake.packages.custom-dontkillsteam = { pkgs, ... }:
pkgs.writeShellApplication {
name = "custom-dontkillsteam";
runtimeInputs = with pkgs; [
hyprland
jq
];
text = ''
class=$(hyprctl activewindow -j | jq -r ".class")
if [[ "$class" == "Steam" || "$class" == "custom-pomodoro" ]]; then
hyprctl dispatch movetoworkspacesilent special
else
hyprctl dispatch killactive ""
fi
'';
};
flake.packages.custom-killall = { pkgs, pkgs-unstable, ...}:
pkgs.writeShellApplication {
name = "custom-killall";
runtimeInputs = with pkgs; [
pkgs-unstable.hyprland
jq
];
text = ''
active_workspace_id=$(hyprctl activeworkspace -j | jq -r '.id')
hyprctl clients -j |
jq -r ".[]
| select(.workspace.id==''${active_workspace_id})
| select(.focusHistoryID!=0)
| .pid" |
xargs -r kill
'';
};
flake.packages.custom-wallpaper = { pkgs, ... }:
let
wallpaper1 = ../../assets/wallpaper1.jpg;
wallpaper2 = ../../assets/wallpaper2.jpg;
wallpaper3 = ../../assets/wallpaper3.jpg;
wallpaper4 = ../../assets/wallpaper4.jpg;
wallpaper5 = ../../assets/wallpaper5.jpg;
in
pkgs.writeShellApplication {
name = "custom-wallpaper";
runtimeInputs = with pkgs; [
socat
swww
];
text = ''
handle() {
case $1 in
workspace*)
str=$1
i=$((''${#str}-1))
workspace="''${str:$i:1}"
case $workspace in
1 | 6)
swww img -t none ${wallpaper1}
;;
2 | 7)
swww img -t none ${wallpaper2}
;;
3 | 8)
swww img -t none ${wallpaper3}
;;
4 | 9)
swww img -t none ${wallpaper4}
;;
5 | 10 | 0)
swww img -t none ${wallpaper5}
;;
esac
;;
esac
}
socat -U - UNIX-CONNECT:"$XDG_RUNTIME_DIR"/hypr/"$HYPRLAND_INSTANCE_SIGNATURE"/.socket2.sock | while read -r line; do handle "$line"; done
'';
};
flake.packages.custom-launch = { pkgs, ... }:
pkgs.writeShellApplication {
# used for the terminal autostart. Needs to get cleared and recall fastfetch so that the bar from oh-my-zsh get resized
# unused
name = "custom-launch";
runtimeInputs = with pkgs; [
zsh
];
text = ''
sleep 2
clear
zsh
'';
};
}
+70
View File
@@ -0,0 +1,70 @@
{ self, ... }: {
flake.nixosModules.kdrive = { pkgs-unstable, ... }: {
environment.systemPackages = with pkgs-unstable; [
rclone
self.packages.${pkgs.system}.custom-checkKdrive
self.packages.${pkgs.system}.custom-mountkdrive
];
# removes rclone error
programs.fuse = {
userAllowOther = true;
enable = true;
};
};
flake.packages.custom-checkKdrive = { pkgs, ... }:
pkgs.writeShellApplication {
name = "custom-checkKdrive";
runtimeInputs = with pkgs; [
rclone
matrix-commander-rs
libnotify
];
text = ''
# waits for an internet connection. It pings both Google DNS and Cloudfare dns in case one of them is down
until ping -c1 -W1 1.1.1.1 >/dev/null 2>&1 || \
ping -c1 -W1 8.8.8.8 >/dev/null 2>&1
do
sleep 1
done
set +e
output=$(rclone lsd kdrive: 2>&1)
status=$?
set -e
if [ $status -eq 0 ]; then
echo "kdrive OK"
else
echo "kdrive rclone failed with error: $output"
notify-send "rclone kdrive failed" "$output"
matrix-commander-rs --verbose -m "rclone kdrive failed.<br>Error: <pre>$output</pre><br><a href=\"https://matrix.to/#/@notificationbot_0000:matrix.org\">@notificationbot_0000</a>" \
--html \
-r "\!7j-78_02dHROeLj4Ns8F12eo4IiZGv4zNsQ_1-WlyIU"
fi
'';
};
flake.packages.custom-mountkdrive = { pkgs, ... }:
pkgs.writeShellApplication {
name = "custom-mountkdrive";
runtimeInputs = with pkgs; [
rclone
libnotify
];
text = ''
REMOTE_NAME="kdrive"
MOUNT_POINT="$HOME/kdrive"
if rclone listremotes | rg "^''${REMOTE_NAME}:"; then
echo "Mounting ''${REMOTE_NAME}..."
rclone mount "''${REMOTE_NAME}:" "$MOUNT_POINT" --vfs-cache-mode writes --allow-non-empty &
else
notify-send "rclone mount failed" \
"Remote ''${REMOTE_NAME} not found.\nConfigure rclone and create the dir ~/kdrive/ or comment out the exec line in hyprland.nix."
echo "Remote ''${REMOTE_NAME} not found. Configure rclone or comment out the exec line in hyprland.nix."
fi
'';
};
}
+123
View File
@@ -0,0 +1,123 @@
{ ... }: {
flake.homeModules.kitty = { ... }: {
programs.kitty = {
enable = true;
#font.name = nerd-fonts._0xproto;
#font.size = "10";
## new config (matches with caelestia
## old condfig
extraConfig = ''
font_size 14
bold_font auto
italic_font auto
bold_italic_font auto
window_padding_width 25
# --- Core ---
foreground #ece0d9
background #18120e
selection_foreground #18120e
selection_background #ece0d9
cursor #ffb878
cursor_text_color #18120e
# --- Tabs ---
active_tab_foreground #18120e
active_tab_background #5c412a
inactive_tab_foreground #d6c3b5
inactive_tab_background #241e1a
# --- Black / Gray ---
color0 #353433
color8 #b29f91
# --- Red ---
color1 #e17300
color9 #ff8a20
# --- Green ---
color2 #ffc071
color10 #ffd6a8
# --- Yellow ---
color3 #ffe0c6
color11 #fff2e8
# --- Blue ---
color4 #b9ab66
color12 #d7be91
# --- Magenta ---
color5 #ed9562
color13 #fcad7e
# --- Cyan ---
color6 #f4c16d
color14 #ffd497
# --- White ---
color7 #ebd4c1
color15 #FFFFFF
'';
/*
extraConfig = ''
# font nerd-fonts._0xproto # this key dont work and causes errors
font_size 14
bold_font auto
italic_font auto
bold_italic_font auto
window_padding_width 25
foreground #FFFFFF
background #1B1D1C
selection_foreground #1B1D1C
selection_background #FFFFFF
cursor #C3AC76
cursor_text_color #0F1010
active_tab_foreground #1B1D1C
active_tab_background #6B5540
inactive_tab_foreground #6B5540
inactive_tab_background #1B1D1C
# black
color0 #29523D
color8 #578F73
# red
#color1 #FFF0CC
#color9 #F0DBAA
# we need actual red colors
color1 #CC241D
color9 #9D0006
# green
color2 #FFEECC
color10 #F0D9AA
# yellow
color3 #FFE5CC
color11 #F0CCAA
# blue
color4 #9AE6C0
color12 #9AE6C0
# magenta
color5 #E6CC9A
color13 #E6CC9A
# cyan
color6 #E6BF9A
color14 #E6BF9A
# white
color7 #FFF0CC
color15 #F0DBAA
'';
*/
};
};
}
+96
View File
@@ -0,0 +1,96 @@
{ ... }: {
flake.nixosModules.ly = { ... }: {
# a minimal ly config as the big config (ly.nix) didnt worked
services.displayManager.ly = {
enable = true;
settings = {
# Core animation
animation = "none"; # none or doom or matrix or gameoflife or a dur file
# Ly supports 24-bit true color with styling, which means each color is a 32-bit value.
# The format is 0xSSRRGGBB, where SS is the styling, RR is red, GG is green, and BB is blue.
# Here are the possible styling options:
# TB_BOLD 0x01000000
# TB_UNDERLINE 0x02000000
# TB_REVERSE 0x04000000
# TB_ITALIC 0x08000000
# TB_BLINK 0x10000000
# TB_HI_BLACK 0x20000000
# TB_BRIGHT 0x40000000
# TB_DIM 0x80000000
# Programmatically, you'd apply them using the bitwise OR operator (|), but because Ly's
# configuration doesn't support using it, you have to manually compute the color value.
# Note that, if you want to use the default color value of the terminal, you can use the
# special value 0x00000000. This means that, if you want to use black, you *must* use
# the styling option TB_HI_BLACK (the RGB values are ignored when using this option).
# Basic TUI settings
clear_password = true;
default_input = "password";
fg = "0x01cd6400";
full_color = true;
hide_borders = false;
hide_key_hints = false;
hide_keyboard_locks = true;
hide_version_string = false;
input_len = 34;
lang = "en";
numlock = false;
save = true;
service_name = "ly";
bigclock = "en";
clock = "%H:%M";
colormix_col1 = "0x08E85D04";
colormix_col2 = "0x08FABD2F";
colormix_col3 = "0x08FE8019";
# Box appearance
#border_fg = "0x00FFFFFF";
blank_box = true;
box_title = "tomasr@nixos";
#margin_box_h = 2;
#margin_box_v = 1;
#text_in_center = false;
# Animation: Conways Game of Life (optional, comment out for minimal setup)
gameoflife_fg = "0x40FFFFFF";
gameoflife_frame_delay = 3;
gameoflife_entropy_interval = 10;
gameoflife_initial_density = 0.666;
# Optional commands (leave null or comment if unused)
hibernate_cmd = null;
inactivity_cmd = null;
login_cmd = "start-hyprland";
#logout_cmd = null;
sleep_cmd = null;
# System commands keys
shutdown_cmd = "/sbin/shutdown $PLATFORM_SHUTDOWN_ARG now";
shutdown_key = "F1";
restart_key = "F2";
sleep_key = "F3";
hibernate_key = "F4";
# top bar
session_log = null;
initial_info_text = null; #
# Custom sessions
#custom_sessions = "$CONFIG_DIRECTORY/ly/custom-sessions";
#waylandsessions = "$PREFIX_DIRECTORY/share/wayland-sessions";
#xsessions = "$PREFIX_DIRECTORY/share/xsessions";
# Xorg settings (only needed if using X)
#x_cmd = "$PREFIX_DIRECTORY/bin/X";
#x_vt = null;
#xauth_cmd = "$PREFIX_DIRECTORY/bin/xauth";
#xinitrc = "~/.xinitrc";
# Setup / startup scripts
#setup_cmd = "$CONFIG_DIRECTORY/ly/setup.sh";
#start_cmd = "$CONFIG_DIRECTORY/ly/startup.sh";
};
};
};
}
+42
View File
@@ -0,0 +1,42 @@
{ inputs, ... }: {
flake.hostModules.micro = { pkgs-unstable, ... }: {
programs.micro = {
enable = true;
package = pkgs-unstable.micro-full;
settings = {
};
};
home.file.".config/micro/plug/vivify" = {
enable = true;
source = inputs.microPlugins-vivify;
recursive = true;
force = true;
};
home.file.".config/micro/init.lua" = {
enable = true;
force = true;
text = ''
local buffer = import("micro/buffer")
local shell = import("micro/shell")
function vivifyOpen(buf)
local cursor = buf:GetActiveCursor()
local line = cursor.Loc.Y + 1
shell.ExecCommand("viv", string.format("%s:%d", buf.AbsPath, line))
end
function onBufferOpen(buf)
if os.getenv("MICRO_VIVIFY") ~= "1" then
return
end
-- only run for real files (not help/log/etc)
if buf.Type.Kind == buffer.BTDefault then
vivifyOpen(buf)
end
end
'';
};
};
}
+15
View File
@@ -0,0 +1,15 @@
{ ... }: {
flake.nixosModules.mullvad = {pkgs-unstable, ...}: {
services.mullvad-vpn = {
enable = true;
package = pkgs-unstable.mullvad-vpn;
};
};
flake.homeModules.mullvad = {pkgs-unstable, ...}: {
programs.mullvad-vpn = {
# gui
enable = true;
package = pkgs-unstable.mullvad-vpn;
};
};
}
+501
View File
@@ -0,0 +1,501 @@
{ ... }: {
flake.homeModules.neovim = {pkgs-unstable, ...}: {
programs.neovim = {
enable = true;
vimAlias = false;
viAlias = false;
package = pkgs-unstable.neovim-unwrapped; # required for unwrapped version
plugins = [
pkgs-unstable.vimPlugins.vivify-vim
pkgs-unstable.vimPlugins.vimtex
pkgs-unstable.vimPlugins.zoxide-vim
#pkgs-unstable.vimPlugins.gruvbox
pkgs-unstable.vimPlugins.gruvbox-nvim
pkgs-unstable.vimPlugins.neovim-sensible
pkgs-unstable.vimPlugins.nvim-web-devicons
pkgs-unstable.vimPlugins.nvim-tree-lua
pkgs-unstable.vimPlugins.nvim-surround
pkgs-unstable.vimPlugins.floaterm
pkgs-unstable.vimPlugins.nvim-lspconfig
pkgs-unstable.vimPlugins.cmp-nvim-lsp
pkgs-unstable.vimPlugins.cmp-nvim-lsp-signature-help
pkgs-unstable.vimPlugins.cmp-under-comparator
pkgs-unstable.vimPlugins.cmp-buffer
pkgs-unstable.vimPlugins.cmp-path
pkgs-unstable.vimPlugins.cmp-cmdline
pkgs-unstable.vimPlugins.nvim-cmp
pkgs-unstable.vimPlugins.cmp-vsnip
pkgs-unstable.vimPlugins.vim-vsnip
pkgs-unstable.vimPlugins.dashboard-nvim
pkgs-unstable.vimPlugins.lualine-nvim
pkgs-unstable.vimPlugins.vim-nix
pkgs-unstable.vimPlugins.plenary-nvim
pkgs-unstable.vimPlugins.blink-ripgrep-nvim
pkgs-unstable.vimPlugins.nvim-treesitter
pkgs-unstable.vimPlugins.nvim-treesitter-parsers.rasi
pkgs-unstable.vimPlugins.nvim-treesitter-parsers.regex
pkgs-unstable.vimPlugins.nvim-treesitter-parsers.udev
pkgs-unstable.vimPlugins.nvim-treesitter-parsers.zsh
pkgs-unstable.vimPlugins.nvim-treesitter-parsers.c
pkgs-unstable.vimPlugins.nvim-treesitter-parsers.bibtex
pkgs-unstable.vimPlugins.nvim-treesitter-parsers.bash
pkgs-unstable.vimPlugins.nvim-treesitter-parsers.gitignore
pkgs-unstable.vimPlugins.nvim-treesitter-parsers.comment
pkgs-unstable.vimPlugins.nvim-treesitter-parsers.json
pkgs-unstable.vimPlugins.nvim-treesitter-parsers.hyprlang
pkgs-unstable.vimPlugins.nvim-treesitter-parsers.lua
pkgs-unstable.vimPlugins.nvim-treesitter-parsers.latex
pkgs-unstable.vimPlugins.nvim-treesitter-parsers.kitty
pkgs-unstable.vimPlugins.nvim-treesitter-parsers.markdown
pkgs-unstable.vimPlugins.nvim-treesitter-parsers.nix
pkgs-unstable.vimPlugins.nvim-treesitter-parsers.printf
pkgs-unstable.vimPlugins.nvim-treesitter-parsers.python
pkgs-unstable.vimPlugins.telescope-nvim
pkgs-unstable.vimPlugins.nvim-scrollbar
pkgs-unstable.vimPlugins.promise-async
pkgs-unstable.vimPlugins.nvim-ufo
pkgs-unstable.vimPlugins.cheatsheet-nvim
pkgs-unstable.vimPlugins.popup-nvim
pkgs-unstable.vimPlugins.vim-visual-multi
pkgs-unstable.vimPlugins.fugit2-nvim
pkgs-unstable.vimPlugins.nvim-lastplace
pkgs-unstable.vimPlugins.runner-nvim # terminal
pkgs-unstable.vimPlugins.better-diagnostic-virtual-text
pkgs-unstable.vimPlugins.garbage-day-nvim
];
extraLuaConfig = ''
local vim = vim
-- =========================
-- LEADER & KEY DISABLE
-- =========================
vim.g.mapleader = ' '
vim.g.maplocalleader = ' '
vim.keymap.set({'n', 'v'}, '<Space>', '<Nop>', { desc = 'Leader key, disable default behavior' })
vim.keymap.set('n', 'q', '<Nop>', { desc = 'Disable macro recording' })
vim.keymap.set('n', 'gg', '<Nop>', { desc = 'Disable g motion' })
vim.keymap.set('n', 'gG', '<Nop>', { desc = 'Disable g motion' })
vim.keymap.set('n', 'g0', '<Nop>', { desc = 'Disable g motion' })
vim.keymap.set('n', 'g^', '<Nop>', { desc = 'Disable g motion' })
vim.keymap.set('n', 'g$', '<Nop>', { desc = 'Disable g motion' })
vim.keymap.set('n', 'gj', '<Nop>', { desc = 'Disable g motion' })
vim.keymap.set('n', 'gk', '<Nop>', { desc = 'Disable g motion' })
vim.keymap.set('n', 'g~', '<Nop>', { desc = 'Disable g motion' })
vim.keymap.set('n', 'gu', '<Nop>', { desc = 'Disable g motion' })
vim.keymap.set('n', 'gU', '<Nop>', { desc = 'Disable g motion' })
vim.keymap.set('n', 'g=', '<Nop>', { desc = 'Disable g motion' })
vim.keymap.set('n', 'gq', '<Nop>', { desc = 'Disable g motion' })
vim.keymap.set('n', 'g@', '<Nop>', { desc = 'Disable g motion' })
vim.keymap.set('n', 'g?', '<Nop>', { desc = 'Disable g motion' })
vim.keymap.set('n', 'gC', '<Nop>', { desc = 'Disable g motion' })
vim.keymap.set('n', 'gD', '<Nop>', { desc = 'Disable g motion' })
vim.keymap.set('n', 'gx', '<Nop>', { desc = 'Disable g motion' })
vim.keymap.set('n', 'gr', '<Nop>', { desc = 'Disable g motion' })
vim.keymap.set('n', 'g[', '<Nop>', { desc = 'Disable g motion' })
vim.keymap.set('n', 'g]', '<Nop>', { desc = 'Disable g motion' })
vim.keymap.set('n', 'g;', '<Nop>', { desc = 'Disable g motion' })
vim.keymap.set('n', 'g,', '<Nop>', { desc = 'Disable g motion' })
-- =========================
-- GENERAL OPTIONS
-- =========================
vim.g.have_nerd_font = true
vim.opt.relativenumber = false
vim.opt.number = true
vim.opt.mouse = 'a'
vim.opt.showmode = false
vim.schedule(function()
vim.opt.clipboard = 'unnamedplus'
end)
vim.opt.breakindent = true
vim.opt.undofile = true
vim.opt.ignorecase = true
vim.opt.smartcase = true
vim.opt.signcolumn = 'yes'
vim.opt.updatetime = 250
vim.opt.timeoutlen = 300
vim.opt.splitright = true
vim.opt.splitbelow = true
vim.opt.list = true
vim.opt.listchars = { tab = '» ', trail = '·', nbsp = '' }
vim.opt.expandtab = true
vim.opt.smartindent = true
vim.opt.tabstop = 4
vim.opt.shiftwidth = 4
vim.opt.inccommand = 'split'
vim.opt.cursorline = true
vim.opt.scrolloff = 10
-- =========================
-- BASIC KEYMAPS
-- =========================
vim.keymap.set('n', '<Esc>', '<cmd>nohlsearch<CR>')
vim.keymap.set('t', '<Esc><Esc>', '<C-\\><C-n>', { desc = 'Exit terminal mode' })
-- Disable arrow keys in normal mode
vim.keymap.set('n', '<left>', '<cmd>echo "Use h to move!!"<CR>')
vim.keymap.set('n', '<right>', '<cmd>echo "Use l to move!!"<CR>')
vim.keymap.set('n', '<up>', '<cmd>echo "Use k to move!!"<CR>')
vim.keymap.set('n', '<down>', '<cmd>echo "Use j to move!!"<CR>')
-- Window navigation
vim.keymap.set('n', '<C-Left>', '<C-w><C-h>', { desc = 'Move focus to the left window' })
vim.keymap.set('n', '<C-Right>', '<C-w><C-l>', { desc = 'Move focus to the right window' })
vim.keymap.set('n', '<C-Down>', '<C-w><C-j>', { desc = 'Move focus to the lower window' })
vim.keymap.set('n', '<C-Up>', '<C-w><C-k>', { desc = 'Move focus to the upper window' })
-- Cheatsheet
vim.keymap.set("n","§", "<cmd>Cheatsheet<CR>")
require("cheatsheet").setup({
bundled_cheatsheets = { enabled = { "default" } },
bundled_plugin_cheatsheets = { disabled = { "gitsigns.nvim" } }
})
-- Highlight yanked text
vim.api.nvim_create_autocmd('TextYankPost', {
desc = 'Highlight on yank',
group = vim.api.nvim_create_augroup('kickstart-highlight-yank', { clear = true }),
callback = function() vim.highlight.on_yank() end,
})
-- ========================
-- terminal
-- =======================
require("runner-nvim").setup({
position = 'right', -- position of the terminal window when using the shell_handler
-- can be: top, left, right, bottom
-- will be overwritten when using the telescope mapping to open horizontally or vertically
width = 80, -- width of window when position is left or right
height = 10, -- height of window when position is top or bottom
handlers = {
lua = function(bufnr)
vim.print('Running lua file in buffer ' .. bufnr)
-- Run the file here
end
}
})
vim.keymap.set("n", "<leader><leader>", function() require("runner-nvim").run() end)
-- =========================
-- SCROLLBAR
-- =========================
require("scrollbar").setup()
-- =========================
-- UFO FOLDING
-- =========================
vim.o.foldcolumn = '1'
vim.o.foldlevel = 99
vim.o.foldlevelstart = 99
vim.o.foldenable = true
vim.keymap.set('n', '<leader>1', "<cmd>foldopen<CR>")
vim.keymap.set('n', '<leader>2', "<cmd>foldclose<CR>")
require('ufo').setup({
provider_selector = function() return {'treesitter', 'indent'} end
})
-- =========================
-- treesitter
-- ========================
require('nvim-treesitter').setup({
ensure_installed = {},
highlight = {
enable = true,
additional_vim_regex_highlighting = false,
},
indent = { enable = true },
})
-- =========================
-- NVIM-TREE
-- =========================
vim.g.loaded_netrw = 1
vim.g.loaded_netrwPlugin = 1
require("nvim-tree").setup({
sort = { sorter = "case_sensitive" },
view = { width = 30 },
renderer = { group_empty = true },
filters = { dotfiles = true },
})
-- =========================
-- CMP CONFIGURATION
-- =========================
local cmp = require'cmp'
cmp.setup({
snippet = { expand = function(args) vim.fn["vsnip#anonymous"](args.body) end },
mapping = cmp.mapping.preset.insert({
['<C-b>'] = cmp.mapping.scroll_docs(-4),
['<C-f>'] = cmp.mapping.scroll_docs(4),
['<C-Space>'] = cmp.mapping.complete(),
['<C-e>'] = cmp.mapping.abort(),
['<CR>'] = cmp.mapping.confirm({ select = true }),
}),
sources = cmp.config.sources({ { name = 'nvim_lsp' }, { name = 'vsnip' } }, { { name = 'buffer' } }),
})
cmp.setup.cmdline({ '/', '?' }, { mapping = cmp.mapping.preset.cmdline(), sources = { { name = 'buffer' } } })
cmp.setup.cmdline(':', { mapping = cmp.mapping.preset.cmdline(), sources = cmp.config.sources({ { name = 'path' } }, { { name = 'cmdline' } }), matching = { disallow_symbol_nonprefix_matching = false } })
-- =========================
-- LSP CONFIGURATION
-- =========================
local capabilities = require('cmp_nvim_lsp').default_capabilities()
-- Diagnostics
vim.keymap.set("n", "<leader>e4", function() vim.diagnostic.jump({ prev=true, count = 1 }) end, { desc = "Previous diagnostic" })
vim.keymap.set("n", "<leader>e5", function() vim.diagnostic.jump({ prev=false, count = 1 }) end, { desc = "Next diagnostic" })
vim.keymap.set("n", "<leader>e1", vim.diagnostic.open_float, { desc = "Show diagnostic" })
vim.keymap.set("n", "<leader>e3", vim.diagnostic.setloclist, { desc = "Diagnostic list" })
vim.keymap.set("n", "<leader>e2", vim.lsp.buf.code_action, { desc = "Show correction" })
vim.keymap.set("n", "<leader>e<Tab>", function()
local clients = vim.lsp.get_clients({ name = "ltex" })
if #clients > 0 then
-- Stop LTeX
for _, client in ipairs(clients) do
client.stop()
end
print("LTeX OFF")
else
-- Start LTeX
vim.cmd("LspStart ltex")
print("LTeX ON")
end
end, { desc = "Toggle LTeX" })
vim.diagnostic.config({
update_in_insert = false, -- i don't get any new error when in insert
})
require("better-diagnostic-virtual-text").setup({
ui = {
wrap_line_after = false, -- wrap the line after this length to avoid the virtual text is too long
left_kept_space = 3, --- the number of spaces kept on the left side of the virtual text, make sure it enough to custom for each line
right_kept_space = 3, --- the number of spaces kept on the right side of the virtual text, make sure it enough to custom for each line
arrow = " ",
up_arrow = " ",
down_arrow = " ",
above = false, -- the virtual text will be displayed above the line
},
priority = 2003, -- the priority of virtual text
inline = false,
})
-- LSP functionality
vim.keymap.set("n", "<leader>g1", vim.lsp.buf.hover, { desc = "Hover documentation" })
vim.keymap.set("n", "<leader>g2", vim.lsp.buf.definition, { desc = "Go to definition" })
vim.keymap.set("n", "<leader>g3", vim.lsp.buf.declaration, { desc = "Go to declaration" })
vim.keymap.set("n", "<leader>g4", vim.lsp.buf.implementation, { desc = "Go to implementation" })
vim.keymap.set("n", "<leader>g5", vim.lsp.buf.references, { desc = "Show references" })
-- LSP server setup
vim.lsp.config("lua_ls", { cmd = { "lua-language-server" }, filetypes = { "lua" }, root_dir = vim.fs.dirname, on_attach = on_attach })
vim.lsp.config("clangd", {
cmd = { "clangd", "--header-insertion=never" },
filetypes = { "c","cpp","objc","objcpp" },
on_attach = on_attach ,
init_options = {
clangdFileStatus = true,
usePlaceholders = true,
completeUnimported = false, -- this adds a bunch of #include even thought they are #included in another header file
headerInsertion = false,
headerInsertionDecorators = false,
addDependencyHeaders = false,
semanticHighlighting = true}
})
vim.lsp.config("nixd", {
cmd = { "nixd" },
filetypes = { "nix" },
on_attach = on_attach,
})
vim.lsp.config("pylsp", {
cmd = { "pylsp" },
filetypes = { "python" },
on_attach = on_attach,
settings = {
pylsp = {
plugins = {
pylsp_mypy = { enabled = true },
jedi_completion = { fuzzy = true }
}
}
}
})
vim.lsp.config("texlab", { cmd = { "texlab" }, filetypes = { "tex" }, on_attach = on_attach })
vim.lsp.config("ltex", {
cmd = { "ltex-ls-plus" },
filetypes = { "markdown", "text", "tex", "plaintex" },
on_attach = on_attach,
settings = {
ltex = {
language = "fr",
enabled = {
"markdown",
"text",
"tex",
"plaintex",
},
completionEnabled = true,
diagnosticSeverity = "information",
additionalRules = {
enablePickyRules = false,
motherTongue = "fr",
},
dictionary = {
["fr"] = {
"icelle",
"icelui",
"iceux",
"maldoror",
"evariste",
"galois",
"arno",
"dessacrer",
},
},
},
},
})
vim.lsp.enable({ "lua_ls", "clangd", "pylsp", "texlab", "nixd", "ltex"})
-- =========================
-- DASHBOARD
-- =========================
require('dashboard').setup {
theme = 'hyper',
config = {
header = {
" ... ... . ",
" .=*8888n..\"%888: @88> ",
" X ?8888f '8888 u. ... .. %8P .. . : ",
" 88x. '8888X 8888> .u ...ue888b :~\"\"888h.:^\"888: . .888: x888 x888. ",
"'8888k 8888X '\"*8h. ud8888. 888R Y888r 8X `8888X 8888> .@88u ~`8888~'888X`?888f` ",
" \"8888 X888X .xH8 :888'8888. 888R I888> X888n. 8888X ?888> '\"888E` X888 888X '888> ",
" `8\" X888!:888X d888 '88%\" 888R I888> '88888 8888X ?**h. 888E X888 888X '888> ",
" =~` X888 X888X 8888.+\" 888R I888> `*88 8888~ x88x. 888E X888 888X '888> ",
" :h. X8*` !888X 8888L u8888cJ888 ..<\" 88*` 88888X 888E X888 888X '888> ",
" X888xX\" '8888..: '8888c. .+ \"*888*P\" ..XC. `*8888k 888& \"*88%\"\"*88\" '888!` ",
":~`888f '*888*\" \"88888% 'Y\" :888888H. `%88> R888\" `~ \" `\"` ",
" \"\" `\"` \"YP' < `\"888888: X\" \"\" ",
" %888888x.-` ",
" \"\"**\"\" ",
"",
""
},
shortcut = { { desc = " Open File Tree", group = "", key = 't', action = 'NvimTreeOpen' } },
packages = { enable = false },
project = { enable = true, limit = 8, icon = ' New file', action = 'Telescope find_files cwd=' },
mru = { limit = 10, icon = ' History' },
footer = {},
}
}
-- jumps cursor when was last cursor last time
require("nvim-lastplace").setup({
-- Filetypes to ignore
ignore_filetypes = {
"gitcommit", "gitrebase", "svn", "hgcommit", "xxd", "COMMIT_EDITMSG"
},
-- Buffer types to ignore
ignore_buftypes = {
"quickfix", "nofile", "help", "terminal"
},
-- Center cursor after jumping
center_on_jump = true,
-- Only jump if target line is not visible
jump_only_if_not_visible = false,
-- Minimum lines required to enable jumping
min_lines = 10,
-- Maximum line to jump to (0 = no limit)
max_line = 0,
-- Open folds after jumping
open_folds = true,
-- Enable debug messages
debug = false,
})
-- ======================
-- gruvbox
-- ======================
require("gruvbox").setup({
terminal_colors = false, -- add neovim terminal colors
undercurl = true,
underline = true,
bold = true,
italic = {
strings = false,
emphasis = true,
comments = true,
operators = false,
folds = true,
},
strikethrough = true,
invert_selection = false,
invert_signs = false,
invert_tabline = false,
inverse = true, -- invert background for search, diffs, statuslines and errors
contrast = "hard", -- can be "hard", "soft" or empty string
palette_overrides = { -- for overrides see https://github.com/ellisonleao/gruvbox.nvim/blob/main/lua/gruvbox.lua
dark0_hard = "#241F17"
},
overrides = {
String = {fg = "#FFB878", italic = false},
FoldColumn = {fg = faded_orange, bg = dark0_hard}
},
dim_inactive = false,
transparent_mode = false,
})
vim.opt.termguicolors = false
vim.o.background = "dark"
vim.cmd("colorscheme gruvbox")
-- =========================
-- LUALINE
-- =========================
require('lualine').setup { options = { theme = "gruvbox_dark" } }
--==================0
-- Some utils
--==================
vim.keymap.set('n', '<leader>r1', '<cmd>Fugit2<CR>', { desc = 'Open git helper' })
vim.keymap.set("n", "t", function()
local line = vim.api.nvim_get_current_line()
local result = vim.fn.system({ "custom-syllabes" }, line)
print(vim.trim(result))
end, { desc = "Count syllables (current line)" })
-- =========================
-- telescope
-- =======================
local builtin = require('telescope.builtin')
vim.keymap.set('n', '<leader>f1', builtin.find_files, { desc = 'Telescope find files' })
vim.keymap.set('n', '<leader>f2', builtin.live_grep, { desc = 'Telescope live grep' })
vim.keymap.set('n', '<leader>f3', builtin.buffers, { desc = 'Telescope buffers' })
vim.keymap.set('n', '<leader>f4', builtin.help_tags, { desc = 'Telescope help tags' })
-- Disable relative numbers even if plugins override
vim.api.nvim_create_autocmd("VimEnter", { callback = function() vim.opt.colorcolumn = ""; vim.opt.relativenumber = false end })
'';
};
};
}
+126
View File
@@ -0,0 +1,126 @@
{ ... }: {
# obsidian is unused -> see my project https://github.com/tomasriveral/NoteWrapper
flake.homeModules.obsidian = { ... }: {
programs.obsidian = {
enable = true;
vaults = {
miscellanious = {
enable = true;
target = "/Documents/Notes/miscellanious";
};
work = {
enable = true;
target = "/Documents/Notes/work";
};
};
defaultSettings = {
appearance.theme = "gruvbox";
extraFiles = {
".obsidian/themes/gruvbox/manifest.json" = ../../other/obsidian-theme/manifest.json;
".obsidian/themes/gruvbox/obsidian.css" = ../../other/obsidian-theme/obsidian.css;
".obsidian/themes/gruvbox/theme.css" = ../../other/obsidian-theme/theme.css;
};
};
};
};
flake.packages.custom-obsidianbackup = {pkgs, ...}:
pkgs.writeShellApplication {
name = "custom-obsidianbackup";
runtimeInputs = with pkgs; [
rclone
libnotify
rsync
];
text = ''
#!/usr/bin/env bash
SOURCE_DIR="$HOME/Documents/Notes"
DEST_DIR="$HOME/kdrive/Notes"
BACKUP_DIR="$HOME/.Notes.backup"
mkdir -p "$DEST_DIR"
mkdir -p "$BACKUP_DIR"
while true; do
# Timestamp for this run
TIMESTAMP=$(date +%Y-%m-%d_%H-%M)
TIMESTAMPED_BACKUP="$BACKUP_DIR/$TIMESTAMP"
mkdir -p "$TIMESTAMPED_BACKUP"
echo "[$(date)] Starting Obsidian backup..."
# Check rclone mount
status=$(rclone about kdrive: 2>&1 || true)
if [[ "$status" =~ .*CRITICAL.* ]]; then
echo "[$(date)] rclone failed:"
echo "$status"
notify-send -u critical "rclone failed" \
"rclone might be broken or you need to deactivate this script in HomeManager."
else
# Run rsync with verbose debugging
echo "[$(date)] Running rsync..."
rsync -Lavh --progress --update --backup --backup-dir="$TIMESTAMPED_BACKUP" \
--exclude='.obsidian/cache/**' \
"$SOURCE_DIR/" "$DEST_DIR/"
echo "[$(date)] Backup completed for this run."
fi
# Safely remove backups older than 30 days
if [[ -d "$BACKUP_DIR" && "$BACKUP_DIR" == "$HOME/.Notes.backup" ]]; then
echo "[$(date)] Cleaning old backups..."
find "$BACKUP_DIR/" -mindepth 1 -maxdepth 1 -type d -mtime +30 -exec rm -rf {} \;
else
echo "[$(date)] Backup directory not safe. Skipping cleanup."
fi
# Wait 1 hour
echo "[$(date)] Sleeping for 1 hour..."
sleep 3600
done
'';
};
# this might be broken after dendritic nix. As it searched for the obsidian.nix to get list of vaults
flake.packages.custom-obsidianvaults = {pkgs, ...}:
pkgs.writeShellApplication {
name = "custom-obsidianvaults";
runtimeInputs = with pkgs; [
zsh
fzf
ripgrep
];
text = ''
# Path to your obsidian.nix
obsidian_nix="$HOME/nixos/modules/home-manager/obsidian.nix"
# Extract vault names without line numbers and colors
mapfile -t vaults < <(rg -N --color=never -Po 'vaults\.\K[[:alnum:]_]+' "$obsidian_nix")
# Let user select a vault with fzf
selected=$(printf "%s\n" "''${vaults[@]}" \
| fzf --height 6 --reverse --prompt="Select Obsidian vault:")
# Exit if user cancels
[[ -z "$selected" ]] && exit 0
# Remove any stray ANSI codes (optional)
selected=$(echo "$selected" | sed -r 's/\x1B\[[0-9;]*[mK]//g')
# Find the target path of the selected vault
vault_path=$(rg -N --color=never -A2 "vaults.$selected" "$obsidian_nix" \
| rg 'target =' | sed -E 's/.*"([^"]+)".*/\1/')
# Expand ~ if present
vault_path="''${vault_path/#\~/$HOME}"
# Launch Obsidian with the selected vault using URI
[[ -n "$vault_path" ]] && setsid xdg-open "obsidian://open?vault=$selected" >/dev/null 2>&1 &
# Exit the kitty terminal after selection
pkill -f "kitty.*Select Obsidian vault"
exit
'';
};
}
+9
View File
@@ -0,0 +1,9 @@
{ ... }: {
flake.homeModules.oh-my-posh = { ... }: {
programs.oh-my-posh = {
enable = true;
enableZshIntegration = true;
useTheme = "gruvbox";
};
};
}
+125
View File
@@ -0,0 +1,125 @@
{ ... }:
{
flake.homeModules.quickshell = { ... }: {
# pulled from https://codeberg.org/zacoons/rivendell-hyprdots
# replaced by caelestia-shell
qt.enable = true;
programs.quickshell = {
systemd.enable = true;
enable = true;
};
home.file.".config/quickshell" = {
source = ../../other/quickshell;
recursive = true;
};
};
flake.packages.QS-notifycache = {writeShellApplication, ...}:
# creates and maintains cache file for the notification history
writeShellApplication {
name = "QS-notifycache";
text = ''
CACHE="$HOME/.cache/notify_history"
# Create or erase existing cache
mkdir -p "$(dirname "$CACHE")"
: > "$CACHE" # truncate file
echo "Notification history initialized at $(date)" >> "$CACHE"
'';
};
flake.packages.QS-notifyhistory = {writeShellApplication, ...}:
writeShellApplication {
name = "QS-notifyhistory";
text = ''
app="$1"
title="$2"
body="$3"
date="$(date +%T)"
urgency="$4"
case "$urgency" in
0) urgency_text="low";;
1) urgency_text="normal";;
2) urgency_text="critical";;
*) urgency_text="unknown";;
esac
{
echo "$app"
echo "$title"
echo "$body"
echo "$date"
echo "$urgency_text"
} >> "$HOME/.cache/notify_history"
'';
};
flake.packages.QS-sysinfo = { pkgs, ... }:
pkgs.writeShellApplication {
name = "QS-sysinfo";
runtimeInputs = with pkgs; [
ripgrep
gawkInteractive
iproute2
coreutils
procps
upower
];
text = ''
# Pad CPU, MEM, DISK to 2 chars (right-aligned)
cpu=$(awk '/^cpu /{printf("%.0f", ($2+$4)*100/($2+$4+$5))}' /proc/stat)
cpu=$(printf "%2s" "$cpu")
sum=0
count=0
for f in /sys/class/hwmon/hwmon*/temp*_input; do
if [ -r "$f" ]; then
val=$(cat "$f" 2>/dev/null) || continue
sum=$((sum + val))
count=$((count + 1))
fi
done
temp=$(( sum / count / 1000 ))
sum=0
count=0
for f in /sys/class/hwmon/hwmon*/fan*_input; do
if [ -r "$f" ]; then
val=$(cat "$f" 2>/dev/null) || continue
sum=$((sum + val))
count=$((count + 1))
fi
done
fan=$(( sum / count ))
fan=$(printf "%4s" "$fan")
mem=$(free | awk '/Mem:/ {printf("%.0f",$3/$2*100)}')
mem=$(printf "%2s" "$mem")
disk=$(df / | awk 'NR==2 {gsub("%",""); print $5}')
disk=$(printf "%2s" "$disk")
# Pad POWER to 5 chars (XX.XX)
power=$(upower -b | awk -F: '/energy-rate/ {gsub(/^[ \t]+/, "", $2); split($2,a," "); printf("%.2f", a[1])}')
power=$(printf "%5s" "$power")
# network calculations
iface=$(ip route get 1.1.1.1 | awk '{print $5; exit}')
rx1=$(cat "/sys/class/net/$iface/statistics/rx_bytes")
tx1=$(cat "/sys/class/net/$iface/statistics/tx_bytes")
sleep 1
rx2=$(cat "/sys/class/net/$iface/statistics/rx_bytes")
tx2=$(cat "/sys/class/net/$iface/statistics/tx_bytes")
down_speed=$(( (rx2 - rx1) / 1024 ))
up_speed=$(( (tx2 - tx1) / 1024 ))
# Output JSON
echo "{\"cpu\":\"$cpu\",\"temp\":\"$temp\",\"fan\":\"$fan\",\"mem\":\"$mem\",\"disk\":\"$disk\",\"power\":\"$power\",\"down\":\"$down_speed\",\"up\":\"$up_speed\"}"
'';
};
}
+16
View File
@@ -0,0 +1,16 @@
{ ... }: {
flake.homeModules.ripgrep = { ... }: {
programs.ripgrep = {
enable = true;
arguments = [
"-S"
"-."
"-p"
"-n"
];
};
programs.ripgrep-all = {
enable = true;
};
};
}
+8
View File
@@ -0,0 +1,8 @@
{ ... }: {
flake.homeModules.rofi = { ... }: {
programs.rofi = {
enable = true;
theme = "gruvbox-dark-hard";
};
};
}
+31
View File
@@ -0,0 +1,31 @@
{ ... }: {
flake.homeModules.sbb-tui = { pkgs-unstable, ... }: {
home.packages = [
pkgs-unstable.sbb-tui
];
home.file.".config/sbb-tui/config.yaml" = {
enable = true;
# Gruvbox (from https://github.com/Necrom4/sbb-tui/blob/master/docs/themes.md)
text = ''
ui:
nerdfont: true
theme:
text: "#EBDBB2"
textMuted: "#928374"
error: "#FB4934"
warning: "#FB4934"
borderFocused: "#FABD2F"
borderUnfocused: "#504945"
badgeKeyFg: "#282828"
badgeKeyBg: "#FABD2F"
badgeVehicleFg: "#EBDBB2"
badgeVehicleBg: "#458588"
badgeModelFg: "#282828"
badgeModelBg: "#FB4934"
badgeCompanyFg: "#282828"
badgeCompanyBg: "#EBDBB2"
logo: "#EBDBB2"
'';
};
};
}
+27
View File
@@ -0,0 +1,27 @@
{ ... }: {
flake.homeModules.ssh = { ... }: {
programs.ssh = {
enable = true;
enableDefaultConfig = false; # will be removed in the futur. Removes evaluation warning
matchBlocks."*" = {
# equivalent to the default config
forwardAgent = false;
addKeysToAgent = "no";
compression = false;
serverAliveInterval = 0;
serverAliveCountMax = 3;
hashKnownHosts = false;
userKnownHostsFile = "~/.ssh/known_hosts";
controlMaster = "no";
controlPath = "~/.ssh/master-%r@%n:%p";
controlPersist = "no";
};
};
services.ssh-agent.enable = true;
home.file.".ssh/config".text = ''
Host *
AddKeysToAgent yes
IdentityFile ~/.ssh/id_ed25519
'';
};
}
+44
View File
@@ -0,0 +1,44 @@
{ ... }: {
# replaced by caelestia
flake.homeModules.swaync = { ... }: {
services.swaync = {
enable = true;
};
};
flake.homeModules.swaylock = { ... }: {
programs.swaylock = {
enable = true;
settings = {
color = "1e1e2e";
bs-hl-color = "f5e0dc";
caps-lock-bs-hl-color = "f5e0dc";
caps-lock-key-hl-color = "a6e3a1";
inside-color = "00000000";
inside-clear-color = "00000000";
inside-caps-lock-color = "00000000";
inside-ver-color = "00000000";
inside-wrong-color = "00000000";
key-hl-color = "a6e3a1";
layout-bg-color = "00000000";
layout-border-color = "00000000";
layout-text-color = "cdd6f4";
line-color = "00000000";
line-clear-color = "00000000";
line-caps-lock-color = "00000000";
line-ver-color = "00000000";
line-wrong-color = "00000000";
ring-color = "b4befe";
ring-clear-color = "f5e0dc";
ring-caps-lock-color = "fab387";
ring-ver-color = "89b4fa";
ring-wrong-color = "eba0ac";
separator-color = "00000000";
text-color = "cdd6f4";
text-clear-color = "f5e0dc";
text-caps-lock-color = "fab387";
text-ver-color = "89b4fa";
text-wrong-color = "eba0ac";
};
};
};
}
+10
View File
@@ -0,0 +1,10 @@
{ ... }: {
flake.homeModules.thunderbird = { ... }: {
programs.thunderbird = {
enable = true;
profiles.tomasr = {
isDefault = true;
};
};
};
}
+28
View File
@@ -0,0 +1,28 @@
{ ... }: {
flake.homeModules.vivify = {pkgs-unstable, ...}: {
home.file.".config/vivify/config.json" = {
enable = true;
text = ''
{
"browserOptions": {
"name": "qutebrowser",
"arguments": ["-T"]
}
}'';
};
home.packages = [
pkgs-unstable.vivify
];
programs.qutebrowser = {
enable = true;
settings = {
auto_save.session = false;
changelog_after_upgrade = "never";
content.cookies.accept = "never";
};
extraConfig = ''
config.bind('<Ctrl-L>', 'yank url ;; message-info "URL copied"')
'';
};
};
}
+716
View File
@@ -0,0 +1,716 @@
{ ... }:
{
flake.homeModules.waybar = { ... }: {
# replaced by caelestia
programs.waybar = {
enable = true;
settings = [
{
layer = "top";
position = "left";
margin = "5 2 5 0";
reload_style_on_change = true;
modules-left = [
"hyprland/workspaces"
"group/info"
"group/power"
];
modules-center = [
];
modules-right = [
"hyprland/window"
"group/brightness"
"group/sound"
"group/connection"
"group/together"
"tray"
"battery"
];
# groups settings are organized by alphabetical order
"group/audio" = {
orientation = "inherit";
drawer = {
transition-duration = 500;
transition-left-to-right = false;
};
modules = [
"pulseaudio"
"pulseaudio#mic"
"pulseaudio/slider"
];
};
"group/bluetooth" = {
orientation = "inherit";
drawer = {
transition-duration = 500;
transition-left-to-right = true;
};
modules = [
"bluetooth"
"bluetooth#status"
];
};
"group/brightness" = {
orientation = "inherit";
drawer = {
transition-duration = 500;
transition-left-to-right = false;
};
modules = [
"backlight"
"backlight/slider"
];
};
"group/connection" = {
orientation = "inherit";
modules = ["group/network"];
};
"group/gcpu" = {
orientation = "inherit";
modules = [
"custom/cpu-icon"
"temperature"
"cpu"
];
};
"group/info" = {
orientation = "inherit";
modules = [
"group/gcpu"
"memory"
"disk"
];
};
"group/network" = {
orientation = "inherit";
drawer = {
transition-duration = 500;
transition-left-to-right = true;
};
modules = [
"network"
"network#speed"
];
};
"group/power" = {
orientation = "inherit";
modules = [
"battery#w"
"battery#powerdraw"
];
};
"group/sound" = {
orientation = "inherit";
modules = [
"group/audio"
"custom/notification"
];
};
"group/together" = {
orientation = "inherit";
modules = [
"group/utils"
"clock"
];
};
"group/utils" = {
orientation = "inherit";
drawer = {
transition-duration = 500;
transition-left-to-right = true;
};
modules = [
"custom/weather"
"custom/colorpicker"
];
};
# modules settings are organized by alphabetical order
backlight = {
device = "intel_backlight"; # my laptop is amd and it works
format = "{icon}";
format-icons = [
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
];
on-scroll-down = "brightnessctl s 5%-";
on-scroll-up = "brightness s +5%";
tooltip = true;
tooltip-format = "Brightness: {percent}%";
smooth-scrolling-threshold = 1;
};
"backlight/slider" = {
min = 5;
max = 100;
orientation = "vertical";
device = "intel_backlight";
};
battery = {
#rotate = 90;
interval = 30;
states = {
good = 95;
warning = 20;
critical = 15;
};
format = "{icon} {capacity}";
format-charging = "<b>{icon} {capacity}% </b>";
format-full = "<span color='#82A55F'><b>{icon}</b></span>";
format-icons = [
"󰁻"
"󰁼"
"󰁾"
"󰂀"
"󰂂"
"󰁹"
];
tooltip-format = "{timeTo} {capacity} %";
};
"battery#powerdraw" = {
rotate = 90;
interval = 10;
format = "{power:.0001f}";
};
"battery#w" = {
rotate = 90;
interval = 100000;
format = "W";
};
bluetooth = {
format-on = "";
format-off = "󰂲";
format-disabled = "";
format-connected = "<b></b>";
tooltip-format = "{controller_alias}\t{controller_address}\n\n{num_connections} connected";
tooltip-format-connected = "{controller_alias}\t{controller_address}\n\n{num_connections} connected\n\n{device_enumerate}";
tooltip-format-enumerate-connected = "{device_alias}\t{device_address}";
tooltip-format-enumerate-connected-battery = "{device_alias}\t{device_address}\t{device_battery_percentage}%";
};
"bluetooth#status" = {
format-on = "";
format-off = "";
format-disabled = "";
format-connected = "<b>{num_connections}</b>";
format-connected-battery = "<small><b>{device_battery_percentage}%</b></small>";
tooltip-format = "{controller_alias}\t{controller_address}\n\n{num_connections} connected";
tooltip-format-connected = "{controller_alias}\t{controller_address}\n\n{num_connections} connected\n\n{device_enumerate}";
tooltip-format-enumerate-connected = "{device_alias}\t{device_address}";
tooltip-format-enumerate-connected-battery = "{device_alias}\t{device_address}\t{device_battery_percentage}%";
};
clock = {
format = "{:%H\n%M}";
tooltip-format = "<tt><small>{calendar}</small></tt>";
calendar = {
mode = "month";
mode-mon-col = 3;
weeks-pos = "right";
on-scroll = 1;
on-click-right = "mode";
format = {
today = "<span color='#d65d0e'><b><u>{}</u></b></span>";
};
};
};
cpu = {
format = "<b>{usage}%</b>";
};
"custom/colorpicker" = {
format = "";
on-click = "hyprpicker | tee >(wl-copy) | cliphist store";
};
"custom/cpu-icon" = {
format = "󰻠";
tooltip = false;
};
"custom/mark" = {
format = "";
tooltip = false;
};
"custom/weather" = {
format = "{}";
interval = 3600;
exec = "custom-weatherwaybar";
return-type = "json";
};
disk = {
interval = 600;
format = "<b> 󰋊 \n{percentage_used}󱉸</b>";
path = "/"; #maybe we should subtract ~/kdrive if it is counted
};
"hyprland/window" = {
format = "{class}";
rotate = 90;
};
"hyprland/workspaces" = {
format = "{icon}";
format-icons = {
"1" = "";
"2" = "";
"3" = "";
"4" = "";
"5" = "";
"6" = "";
"7" = "";
"8" = "";
"9" = "";
"10" = "";
"active" = "";
"default" = "";
};
persistent-workspaces = {
"*" = [1 2 3 4 5 6 7 8 9 10];
};
};
idle_inhibitor = {
format = "{icon}";
tooltip-format-activated = "Idle Inhibitor is active";
tooltip-format-deactivated = "Idle Inhibitor is not active";
format-icons = {
activated = "󰔡";
deactivated = "󰔢";
};
};
memory = {
format = "<b> \n{:2}󱉸</b>";
};
network = {
format = "{icon}";
format-icons = {
wifi = ["󰤨"];
ethernet = ["󰈀"];
disconnected = ["󰖪"];
};
format-wifi = "󰤨";
format-ethernet = "󰈀";
format-disconnected = "󰖪";
format-linked = "󰈁";
tooltip = false;
};
"network#speed" = {
format = " {bandwidthDownBits} ";
rotate = 90;
interval = 5;
tooltip-format = "{ipaddr}";
tooltip-format-wifi = "{essid} ({signalStrength}%) \n{ipaddr} | {frequency} MHz{icon} ";
tooltip-format-ethernet = "{ifname} 󰈀 \n{ipaddr} | {frequency} MHz{icon} ";
tooltip-format-disconnected = "Not Connected to any type of Network";
tooltip = true;
};
power-profiles-daemon = {
format = "{icon}";
tooltip-format = "Power profile: {profile}\nDriver: {driver}";
tooltip = true;
format-icons = {
default = "";
performance = "<span color='#B37F34'><small></small></span>";
balanced = "<span><small> </small></span>";
power-saver = "<span color='#a6e3a1'><small></small></span>";
};
};
pulseaudio = {
format = "{icon}";
format-bluetooth = "{icon}";
tooltip-format = "{volume}% {icon} | {desc}";
format-muted = "󰖁";
format-icons = {
headphones = "󰋌";
handsfree = "󰋌";
headset = "󰋌";
phone = "";
portable = "";
car = " ";
default = [
"󰕿"
"󰖀"
"󰕾"
];
};
on-click = "volume mute";
on-click-middle = "pavucontrol";
on-scroll-up = "pactl set-sink-volume @DEFAULT_SINK@ +5%";
on-scroll-down = "pactl set-sink-volume @DEFAULT_SINK@ -5%";
smooth-scrolling-threshold = 1;
};
"pulseaudio#mic" = {
format = "{format_source}";
format-source = "";
format-source-muted = "";
tooltip-format = "{volume}% {format_source}";
on-click = "pactl set-source-mute 0 toggle";
on-scroll-down = "pactl set-source-volume 0 -1%";
on-scroll-up = "pactl set-source-volume 0 +1%";
};
"pulseaudio/slider" = {
min = 0;
max = 140;
orientation = "vertical";
};
temperature = {
format = "{temperatureC}°C";
format-critical = "{temperatureC}°C";
interval = 10;
};
tray = {
icon-size = 18;
spacing = 10;
};
}
]; # home-manager wants the whole config as a list of bars
style = ''
@define-color foreground #c5c5c5;
@define-color background #191919;
@define-color cursor #c5c5c5;
@define-color color0 #191919;
@define-color color1 #3a3632;
@define-color color2 #582c1e;
@define-color color3 #423f39;
@define-color color4 #50473c;
@define-color color5 #634723;
@define-color color6 #BAA470;
@define-color color7 #8c8c8c;
@define-color color8 #525252;
@define-color color9 #4e4843;
@define-color color10 #763b28;
@define-color color11 #59554c;
@define-color color12 #6b5f51;
@define-color color13 #855f2f;
@define-color color14 #796d62;
@define-color color15 #c5c5c5;
@define-color active @color6;
* {
font-size: 23px;
font-family: "0xProto Nerd Font";
min-width: 8px;
min-height: 0px;
border: none;
border-radius: 0;
box-shadow: none;
text-shadow: none;
padding: 0px;
margin: 0px;
}
window#waybar {
transition-property: background-color;
transition-duration: 0.5s;
border-radius: 8px;
border: 2px solid @active;
background: @background;
background: alpha(@background, 0.7);
color: lighter(@active);
}
menu,
tooltip {
border-radius: 8px;
padding: 2px;
border: 1px solid lighter(@active);
background: alpha(@background, 0.6);
color: lighter(@active);
}
menu label,
tooltip label {
font-size: 20px;
color: lighter(@active);
}
#submap,
#tray>.needs-attention {
animation-name: blink-active;
animation-duration: 1s;
animation-timing-function: linear;
animation-iteration-count: infinite;
animation-direction: alternate;
}
.modules-right {
margin: 0px 6px 6px 6px;
border-radius: 4px;
background: alpha(@background, 0.4);
color: lighter(@active);
}
.modules-left {
transition-property: background-color;
transition-duration: 0.5s;
margin: 6px 6px 6px 6px;
border-radius: 4px;
background: alpha(@background, 0.4);
color: lighter(@active);
}
#gcpu,
#custom-github,
#memory,
#disk,
#together,
#submap,
#custom-weather {
font-size: 17px;
}
#custom-recorder,
#connection,
#cnoti,
#brightness,
#power,
#custom-updates,
#tray,
#audio,
#privacy,
#sound {
border-radius: 4px;
margin: 2px 2px 4px 2px;
background: alpha(darker(@active), 0.3);
}
#custom-notifications {
padding-left: 4px;
}
#custom-hotspot,
#custom-github,
#custom-notifications {
font-size: 20px;
}
#custom-hotspot {
padding-right: 2px;
}
#custom-vpn,
#custom-hotspot {
background: alpha(darker(@active), 0.3);
}
#privacy-item {
padding: 6px 0px 6px 6px;
}
#gcpu {
padding: 8px 0px 8px 0px;
}
#custom-cpu-icon {
font-size: 36px;
}
#custom-cputemp,
#temperature {
font-size: 17px;
}
#disk,
#memory,
#cpu {
font-size: 20px;
font-weight: bold;
}
#custom-github {
padding-top: 2px;
padding-right: 4px;
}
#custom-dmark {
color: alpha(@foreground, 0.3);
}
#submap {
margin-bottom: 0px;
}
#hyprland.window {
margin-left: 20px;
}
#workspaces {
margin: 0px 2px;
padding: 4px 0px 0px 0px;
border-radius: 8px;
}
#workspaces button {
transition-property: background-color;
transition-duration: 0.5s;
color: @foreground;
background: transparent;
border-radius: 4px;
color: alpha(@foreground, 0.3);
}
#workspaces button.urgent {
font-weight: bold;
color: @foreground;
}
#workspaces button.active {
padding: 4px 2px;
background: alpha(@active, 0.4);
color: lighter(@active);
border-radius: 4px;
}
#network.wifi {
padding-right: 4px;
}
#submap {
min-width: 0px;
margin: 4px 6px 4px 6px;
}
#tray {
padding: 0px 0px 0px 0px;
}
#bluetooth {
padding-top: 2px;
}
#window {
border-radius: 8px;
padding: 4px 14px;
margin: 4px 2px 4px 2px;
}
#battery {
font-size: 17px;
border-radius: 8px;
padding: 4px 0px;
margin: 4px 2px 4px 2px;
}
#battery.discharging.warning {
animation-name: blink-yellow;
animation-duration: 1s;
animation-timing-function: linear;
animation-iteration-count: infinite;
animation-direction: alternate;
}
#battery.discharging.critical {
animation-name: blink-red;
animation-duration: 1s;
animation-timing-function: linear;
animation-iteration-count: infinite;
animation-direction: alternate;
}
#battery.powerdraw {
font-size: 17px;
padding: 0;
margin-right: -20px;
margin-left: -20px;
}
#battery.w {
font-size: 17px;
padding: 0;
margin-left: -20px;
margin-right: -20px;
}
#clock {
font-weight: bold;
padding: 4px 2px 2px 2px;
}
#pulseaudio.mic {
border-radius: 4px;
color: @background;
background: alpha(darker(@foreground), 0.6);
padding-left: 4px;
}
#backlight-slider slider,
#pulseaudio-slider slider {
background-color: transparent;
box-shadow: none;
}
#backlight-slider trough,
#pulseaudio-slider trough {
margin-top: 4px;
min-width: 6px;
min-height: 60px;
border-radius: 8px;
background-color: alpha(@background, 0.6);
}
#backlight-slider highlight,
#pulseaudio-slider highlight {
border-radius: 8px;
background-color: lighter(@active);
}
#bluetooth.discoverable,
#bluetooth.discovering,
#bluetooth.pairable {
border-radius: 8px;
animation-name: blink-active;
animation-duration: 1s;
animation-timing-function: linear;
animation-iteration-count: infinite;
animation-direction: alternate;
}
@keyframes blink-active {
to {
background-color: @active;
color: @foreground;
}
}
@keyframes blink-red {
to {
background-color: #c64d4f;
color: @foreground;
}
}
@keyframes blink-yellow {
to {
background-color: #cf9022;
color: @foreground;
}
}
'';
};
};
flake.packages.custom-weatherwaybar = { pkgs, ... }:
pkgs.writeShellApplication {
name = "custom-weatherwaybar";
runtimeInputs = with pkgs; [
curl
];
text = ''
PATTERN="C"
PATTERN2=" "
TEXT1="''$(curl -s "https://wttr.in/?format=%c")"
TEXT1=''${TEXT1/$PATTERN2/}
TEXT2="''$(curl -s "https://wttr.in/?format=%t")"
TEXT2=''${TEXT2/$PATTERN/}
TEXT3="''$(curl -s "https://wttr.in/?format=%f")"
TEXT3=''${TEXT3/$PATTERN/}
printf '{"text":" %s\\n %s\\n %s", "tooltip": false, "class": "weather"}\\n' \
"$TEXT1" "$TEXT2" "$TEXT3"
'';
};
}
+118
View File
@@ -0,0 +1,118 @@
{ ... }: {
# replaced by wlogout
flake.homeModules.wlogout = { ... }: let
wallpaper = ../../assets/wallpaper1.jpg;
lock = ../../assets/lock.png;
lock-hover = ../../assets/lock-hover.png;
shutdown = ../../assets/power.png;
shutdown-hover = ../../assets/power-hover.png;
logout = ../../assets/logout.png;
logout-hover = ../../assets/logout-hover.png;
reboot = ../../assets/restart.png;
reboot-hover = ../../assets/restart-hover.png;
in {
programs.wlogout = {
enable = true;
layout = [
{
label = "lock";
action = "swaylock -eFLfk -i ${wallpaper}";
text = " Lock (L) ";
keybind = "l";
}
{
label = "reboot";
action = "systemctl reboot";
text = " Reboot (R) ";
keybind = "r";
}
{
label = "shutdown";
action = "systemctl poweroff";
text = "Shutdown (S)";
keybind = "s";
}
{
label = "logout";
action = "loginctl terminate-session $(loginctl show-session $(loginctl | grep $USER | awk '{print $1}') -p Id --value)";
text = " Logout (E) ";
keybind = "e";
}
];
style = ''
window {
font-family: OxProto Nerd Font;
font-size: 14pt;
color: #000000; /* text */
background-color: rgba(40, 40, 40, 0.76);
}
button {
background-repeat: no-repeat;
background-position: center;
background-size: 50%;
border-style: solid;
border-radius: 4px;
border-width: 2px;
border-color: #ebdbb2;
background-color: rgba(40, 40, 40, 0.76);
margin: 10px;
transition:
box-shadow 0.3s ease-in-out,
background-color 0.3s ease-in-out;
}
button:hover {
background-color: rgba(250, 137, 26, 0.3);
color: #282828;
}
button:focus {
background-color: #ebdbb2;
color: #282828;
}
#lock {
background-image: image(url("${lock}"));
}
#lock:focus {
background-image: image(url("${lock-hover}"));
}
#lock:hover {
background-image: image(url("${lock-hover}"));
}
#logout {
background-image: image(url("${logout}"));
}
#logout:focus {
background-image: image(url("${logout-hover}"));
}
#logout:hover {
background-image: image(url("${logout-hover}"));
}
#shutdown {
background-image: image(url("${shutdown}"));
}
#shutdown:focus {
background-image: image(url("${shutdown-hover}"));
}
#shutdown:hover {
background-image: image(url("${shutdown-hover}"));
}
#reboot {
background-image: image(url("${reboot}"));
}
#reboot:focus {
background-image: image(url("${reboot-hover}"));
}
#reboot:hover {
background-image: image(url("${reboot-hover}"));
}
'';
};
};
}
+8
View File
@@ -0,0 +1,8 @@
{ ... }: {
flake.homeModules.zoxide = { ... }: {
programs.zoxide = {
enable = true;
enableZshIntegration = true;
};
};
}
+88
View File
@@ -0,0 +1,88 @@
{ self, ... }: {
flake.homeModules.zsh-laptop = { ... }: {
programs.zsh = {
shellAliases = {
snrt = "git -C ~/nixos add -A && time sudo nixos-rebuild test --flake ~/nixos/#laptop && pkill shell || true && pkill caelestia-shell || true && caelestia-shell -n > /dev/null 2>&1 & disown";
snrs = "git -C ~/nixos add -A && time sudo nixos-rebuild switch --flake ~/nixos/#laptop && pkill shell || true && pkill caelestia-shell || true && caelestia-shell -n > /dev/null 2>&1 & disown";
};
};
};
flake.homeModules.zsh = {pkgs, ...}: {
home.packages = [
self.packages.${pkgs.system}.dejaManuallyDerived
];
programs.zsh = {
enable = true;
autosuggestion.enable = false; # zsh-autocomplete is replaced by deja
initContent = ''
# Safe cat that uses colorize plugin ccat
custom-cat() {
if [[ -t 1 ]]; then
ccat "$@"
else
command cat "$@"
fi
}
custom-eza() { # behaves differently if we just call it or if we pipe initContent
if [[ -t 1 ]]; then
eza -hlF -aa --color=always --hyperlink --group-directories-first --show-symlinks --icons=always --git --no-permissions "$@"
else
command eza "$@"
fi
}
eval "$(direnv hook zsh)"
eval "$(deja init zsh)"
export PATH="$PATH:$HOME/NoteWrapper" # some project im coding
fastfetch''\n'';
shellAliases = {
".." = "z ..";
grep = "rg";
ll = "custom-eza"; # if there is a special ls just use the big eza
la = "custom-eza";
l = "custom-eza";
eza = "custom-eza";
ls = "\\eza -a"; # ls -> normal ls. eza gives more info
tree = "\\eza -hlTF --color=always --hyperlink --group-directories-first --show-symlinks --icons=always --git --no-permissions";
cat = "custom-cat";
pomodoro = "custom-tomato";
librewolf = "kitty --class \"custom-librewolfprofiles\" --name \"Select LibreWolf profile\" --hold custom-librewolfprofiles";
manix = "custom-manix";
man = "custom-man";
mplayer = "mplayer -volume 5";
# these are to create the developpement shell
cenv = "nix-shell -p zsh gcc raylib libx11 libGL";
# i always write nvim wrong :(
nbim = "nvim";
nivm = "nvim";
bivm = "nvim";
nibm = "nvim";
vikm = "nvim";
nvimm = "nvim";
nnvim = "nvim";
nvvim = "nvim";
nviim = "nvim";
};
};
};
flake.homeModules.oh-my-zsh = { ... }: {
programs.zsh.oh-my-zsh = {
enable = true;
theme = "jonathan";
plugins = [
"aliases"
"alias-finder"
"colored-man-pages"
"colorize"
"command-not-found"
"dirhistory"
"fzf"
"git"
"rclone"
"safe-paste"
"sudo"
];
};
};
}
+450
View File
@@ -0,0 +1,450 @@
{ ... }: {
flake.nixosModules.battery-laptop = {
lib,
config,
...
}:
# https://discourse.nixos.org/t/what-is-the-best-option-for-power-management/63406/2
# we just activate tlp unconditonally
#let
# cfg = config.custom;
#hasBattery =
# lib.any (x: lib.strings.hasPrefix "BAT" x)
# (builtins.attrNames (builtins.readDir "/sys/class/power_supply"));
#in
{
# options.custom = {
# battery.enable = lib.mkOption {
# default = hasBattery;
# description = "Enable better battery support";
# type = lib.types.bool;
# };
# };
# config = lib.mkIf cfg.battery.enable {
powerManagement.powertop.enable = true; # enable powertop auto tuning on startup.
# Acording to https://community.frame.work/t/solved-keys-stick-and-repeat-after-being-released/51153/12
# Some powertop bug is responsable for the problem of the random keypress being stuck
# fix: from https://git.gabbie.blue/blue/nixconf/src/commit/2d1bc6dad4684c019b6b3e894408e76e2734806c/hosts/gabbielaptop/configuration.nix#L68
powerManagement.powertop.postStart = ''
${lib.getExe' config.systemd.package "udevadm"} trigger -c bind -s usb -a idVendor=32ac -a idProduct=0018
# Retrigger macropad udev rules
${lib.getExe' config.systemd.package "udevadm"} trigger -c bind -s usb -a idVendor=32ac -a idProduct=0013
'';
services.system76-scheduler.settings.cfsProfiles.enable = true; # Better scheduling for CPU cycles - thanks System76!!!
services.thermald.enable = true; # Enable thermald, the temperature management daemon. (only necessary if on Intel CPUs)
services.power-profiles-daemon.enable = false; # Disable GNOMEs power management
services.tlp = {
enable = true; # Enable TLP (better than gnomes internal power manager)
settings = {
CPU_BOOST_ON_AC = 1;
CPU_BOOST_ON_BAT = 1;
CPU_HWP_DYN_BOOST_ON_AC = 1;
CPU_HWP_DYN_BOOST_ON_BAT = 1;
CPU_SCALING_GOVERNOR_ON_AC = "performance";
CPU_SCALING_GOVERNOR_ON_BAT = "powersave";
CPU_ENERGY_PERF_POLICY_ON_AC = "performance";
CPU_ENERGY_PERF_POLICY_ON_BAT = "balance_power";
PLATFORM_PROFILE_ON_AC = "performance";
PLATFORM_PROFILE_ON_BAT = "balanced";
START_CHARGE_THRESH_BAT1 = 75;
STOP_CHARGE_THRESH_BAT1 = 85;
};
};
# };
};
flake.packages.batteryNotify = { pkgs, ... }: let
NotifySound = ../../assets/battery_notify.mp3;
in
pkgs.writeShellApplication {
# taken and adapted https://github.com/miniMinn24/Battery_Notify with MIT License
name = "custom-batterynotify";
runtimeInputs = with pkgs; [
mplayer
brightnessctl
];
text = ''
# Delay for startup
sleep 5
# Change your sound path here
playsound() {
mplayer ${NotifySound}
}
adjustBrightness() {
local adjustment="$1"
brightnessctl set "$adjustment"
}
sendNotification() {
local title="$1"
local message="$2"
notify-send -h string:x-canonical-private-synchronous:sys-notify -e -u low "$title" "$message"
}
# Runs full time in background
x=0
while true; do
Battery_Status="$(\cat /sys/class/power_supply/BAT*/status)"
Battery_Capacity=$(\cat /sys/class/power_supply/BAT*/capacity)
case "$Battery_Status" in
"Discharging")
if [ $x -eq 1 ]; then
sendNotification "Discharging" "Remains: <b>''${Battery_Capacity}%</b>"
adjustBrightness "15%-"
playsound
x=0
fi
;;
"Charging")
if [ $x -eq 0 ]; then
sendNotification "Charging" "Current: <b>''${Battery_Capacity}%</b>"
adjustBrightness "15%+"
playsound
x=1
fi
;;
"Full")
if [ $x -eq 0 ]; then
sendNotification "Fully Charged" "Noice: <b>''${Battery_Capacity}%</b>"
playsound
x=1
fi
;;
esac
sleep 1
done
'';
};
flake.packages.batteryWarning = { pkgs, ...}: let
NotifySound = ../../assets/battery_notify.mp3;
in
pkgs.writeShellApplication {
# taken and adapted https://github.com/miniMinn24/Battery_Notify with MIT License
name = "custom-batterywarning";
runtimeInputs = with pkgs; [
mplayer
brightnessctl
];
text = ''
# Delay for startup
sleep 5
playsound() {
mplayer ${NotifySound}
}
while true; do
Battery_Status="$(cat /sys/class/power_supply/BAT*/status)"
Battery_Capacity="$(cat /sys/class/power_supply/BAT*/capacity)"
if [ "$Battery_Status" == "Discharging" ]; then
if [ "$Battery_Capacity" -le 20 ] && [ "$Battery_Capacity" -ge 10 ]; then
notify-send -e -u critical "Battery Low!" "Power running out: <b>''${Battery_Capacity}%</b>"
playsound
sleep 180
elif [ "$Battery_Capacity" -lt 10 ]; then
notify-send -e -u critical "Battery Low!" "<b>Save your works</b> before immediate shutdown."
playsound
sleep 180
fi
else
sleep 120
fi
done
'';
};
flake.packages.qtbatticon = { pkgs, ... }:
# because cbatticon, batticonplus and other things didn't work.
# chatGpt did this.
# https://chatgpt.com/c/69da11b3-ba24-8331-b7b0-a58a72e69d42
# at your risk and perils
# click on the icon to get a notification with state, percentage and wattage
pkgs.stdenv.mkDerivation {
pname = "qtbatticon";
version = "1.0";
src = pkgs.writeTextFile {
name = "qtbatticon.cpp";
text = ''
#include <QApplication>
#include <QSystemTrayIcon>
#include <QTimer>
#include <QFile>
#include <QTextStream>
#include <QIcon>
#include <QString>
#include <QDebug>
#include <cstdlib>
QString readFile(const QString &path) {
QFile f(path);
if (!f.open(QIODevice::ReadOnly)) return "";
QTextStream in(&f);
return in.readAll().trimmed();
}
int readInt(const QString &path) {
return readFile(path).toInt();
}
double readDouble(const QString &path) {
QFile f(path);
if (!f.open(QIODevice::ReadOnly)) return 0;
QTextStream in(&f);
return in.readAll().trimmed().toDouble();
}
int toStep(int capacity) {
return (capacity / 10) * 10;
}
QString pad3(int n) {
return QString("%1").arg(n, 3, 10, QChar('0'));
}
double getPowerW(const QString &batPath) {
double current_uA = readDouble(batPath + "/current_now");
double voltage_uV = readDouble(batPath + "/voltage_now");
if (current_uA > 0 && voltage_uV > 0) {
return (current_uA * voltage_uV) / 1e12;
}
return -1;
}
QIcon batteryIcon(int capacity, bool charging) {
int step = toStep(capacity);
QString num = pad3(step);
QString base = "/run/current-system/sw/share/icons/Papirus/24x24/panel/";
QString file;
if (charging) {
file = base + "battery-" + num + "-charging.svg";
} else {
file = base + "battery-" + num + ".svg";
}
QIcon icon(file);
if (icon.isNull()) {
qDebug() << "FAILED icon:" << file;
icon = QIcon(base + "battery-100.svg");
}
return icon;
}
void sendNotification(const QString &title, const QString &body) {
QString cmd = "notify-send \"" + title + "\" \"" + body + "\"";
system(cmd.toUtf8().constData());
}
int main(int argc, char *argv[]) {
QApplication app(argc, argv);
QString batPath = "/sys/class/power_supply/BAT1";
QSystemTrayIcon tray;
auto updateIcon = [&]() {
int capacity = readInt(batPath + "/capacity");
QString status = readFile(batPath + "/status");
bool charging = status.contains("Charging");
tray.setIcon(batteryIcon(capacity, charging));
};
auto notify = [&]() {
int capacity = readInt(batPath + "/capacity");
QString status = readFile(batPath + "/status");
bool charging = status.contains("Charging");
bool discharging = status.contains("Discharging");
double power = getPowerW(batPath);
QString state;
if (charging) state = "Charging";
else if (discharging) state = "Discharging";
else state = status;
QString powerStr = (power > 0.01)
? QString::number(power, 'f', 2) + " W"
: "N/A";
QString msg =
QString("%1\n%2%\n%3")
.arg(state)
.arg(capacity)
.arg(powerStr);
sendNotification("Battery status", msg);
};
QObject::connect(&tray, &QSystemTrayIcon::activated,
[&](QSystemTrayIcon::ActivationReason r) {
if (r == QSystemTrayIcon::Trigger) {
notify();
}
});
updateIcon();
tray.setVisible(true);
QTimer timer;
QObject::connect(&timer, &QTimer::timeout, updateIcon);
timer.start(5000);
return app.exec();
}
'';
};
nativeBuildInputs = with pkgs; [
pkg-config
qt6.wrapQtAppsHook
];
buildInputs = with pkgs; [
qt6.qtbase
qt6.qtsvg
papirus-icon-theme
];
dontUnpack = true;
buildPhase = ''
g++ $src -o qtbatticon \
$(pkg-config --cflags --libs Qt6Widgets)
'';
installPhase = ''
mkdir -p $out/bin
install -m755 qtbatticon $out/bin/
'';
};
# This was replaced by caelestia shell's Game Mode
flake.packages.custom-performance = { pkgs, ...}:
pkgs.writeShellApplication {
name = "custom-performance";
runtimeInputs = with pkgs; [
hyprland
gawk
libnotify
];
text = ''
HYPRGAMEMODE=$(hyprctl getoption animations:enabled | awk 'NR==1{print $2}')
if [ "$HYPRGAMEMODE" = 1 ] ; then
hyprctl --batch "\
keyword animations:enabled 0;\
keyword animation borderangle,0; \
keyword decoration:shadow:enabled 0;\
keyword decoration:blur:enabled 0;\
keyword decoration:fullscreen_opacity 1;\
keyword general:gaps_in 0;\
keyword general:gaps_out 0;\
keyword general:border_size 1;\
keyword decoration:rounding 0"
notify-send -u critical -t 5000 "Performance mode [ON]"
exit
else
notify-send -u critical -t 5000 "Performance mode [OFF]"
hyprctl reload
exit 0
fi
'';
};
# Old script that was used for the battery. Might not work.
flake.packages.custom-olddeprecatedbatterynotify = { pkgs, ... }:
pkgs.writeShellApplication {
name = "custom-olddeprecatedbatterynotify";
runtimeInputs = with pkgs; [
libnotify # provides notify-send
systemd # provides systemctl
];
text = ''
set -euo pipefail
LOW="''${BATTERY_LOW_THRESHOLD:-20}"
CRITICAL="''${BATTERY_CRITICAL_THRESHOLD:-5}"
FULL="''${BATTERY_FULL_THRESHOLD:-95}"
INTERVAL="''${BATTERY_INTERVAL:-30}"
ACTION="''${BATTERY_CRITICAL_ACTION:-systemctl suspend}"
notify() {
notify-send -a "Battery" -u "$1" "$2" "$3"
}
get_info() {
total=0
count=0
for bat in /sys/class/power_supply/BAT*; do
[ -f "$bat/capacity" ] || continue
capacity=$(<"$bat/capacity")
status=$(<"$bat/status")
total=$((total + capacity))
count=$((count + 1))
done
[ "$count" -gt 0 ] || exit 0
percentage=$((total / count))
}
last_state=""
while true; do
get_info
if [[ "$status" == "Discharging" && "$percentage" -le "$CRITICAL" ]]; then
notify critical "Battery Critically Low" "$percentage% suspending."
$ACTION
elif [[ "$status" == "Discharging" && "$percentage" -le "$LOW" ]]; then
if [[ "$last_state" != "low" ]]; then
notify normal "Battery Low" "$percentage% remaining."
last_state="low"
fi
elif [[ "$status" != "Discharging" && "$percentage" -ge "$FULL" ]]; then
if [[ "$last_state" != "full" ]]; then
notify normal "Battery Full" "$percentage% unplug charger."
last_state="full"
fi
else
last_state=""
fi
sleep "$INTERVAL"
done
'';
};
flake.homeModules.cbatticon = { ... }: {
# don't works. some GTK error. I let it here if someday, someone is interest in this shit.
# ChatGPT half baked a replacement that works on my system.
# see qtbatticon
services.cbatticon = {
enable = true;
lowLevelPercent = 20;
criticalLevelPercent = 5;
batteryId = "BAT1";
hideNotification = true; # we use another script for battery notifications
updateIntervalSeconds = 10;
};
};
}
+8
View File
@@ -0,0 +1,8 @@
{ inputs, ...}: {
flake.nixosModule.bluetooth = {pkgs, ...}: {
hardware.bluetooth.enable = true;
environment.systemPackages = with pkgs; [
blueman # GTK-based Bluetooth Manager
];
};
}
+16
View File
@@ -0,0 +1,16 @@
{ ... }: {
flake.nixosModules.bootloader-laptop = {
inputs,
pkgs,
...
}: {
# grub theme
boot.loader.grub = {
theme = inputs.nixos-grub-themes.packages.${pkgs.system}.nixos; # if you want to use nixos grub theme
};
# Bootloader.
boot.loader.systemd-boot.enable = true;
boot.loader.efi.canTouchEfiVariables = true;
};
}
+18
View File
@@ -0,0 +1,18 @@
{ ... }: {
flake.nixosModule.disk = { pkgs, ... }: {
environment.systemPackages = with pkgs; [
gnome-disk-utility
udiskie
];
};
flake.nixosModule.disk-laptop = { ... }: {
# i found swap necessary when running nixpkgs review
swapDevices = [
{
device = "/swapfile";
size = 16384; # 16 GB
}
];
boot.kernel.sysctl."vm.swappiness" = 10;
};
}
@@ -0,0 +1,36 @@
{ ... }: {
flake.nixosModules.hardware-configuration-laptop = {
config,
lib,
modulesPath,
...
}: {
# Do not modify this file! It was generated by nixos-generate-config
# and may be overwritten by future invocations. Please make changes
# to /etc/nixos/configuration.nix instead.
imports = [
(modulesPath + "/installer/scan/not-detected.nix")
];
boot.initrd.availableKernelModules = ["nvme" "xhci_pci" "thunderbolt" "usb_storage" "usbhid" "sd_mod"];
boot.initrd.kernelModules = [];
boot.kernelModules = ["kvm-amd"];
boot.extraModulePackages = [];
fileSystems."/" = {
device = "/dev/disk/by-uuid/6aa664c2-8b23-4e20-b6e9-1806bf0f8df2";
fsType = "ext4";
};
fileSystems."/boot" = {
device = "/dev/disk/by-uuid/A59A-7AFA";
fsType = "vfat";
options = ["fmask=0077" "dmask=0077"];
};
swapDevices = [];
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
hardware.cpu.amd.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
};
}
+10
View File
@@ -0,0 +1,10 @@
{ ... }: {
flake.nixosModules.hardwareUtils-laptop = {pkgs, ...}: {
environment.systemPackages = with pkgs; [
# used for the framework 16 laptop
framework-tool
framework-tool-tui
vial # Open-source GUI and QMK fork for configuring your keyboard in real time
];
};
}
+22
View File
@@ -0,0 +1,22 @@
{ ... }: {
flake.nixosModules.udev = { ... }: {
# udev with only the necessary rules. See udev.nix to get all the rules
services.udev.extraRules = ''
# adapted from here https://wiki.nixos.org/wiki/Keychron_M6
KERNEL=="hidraw*", SUBSYSTEM=="hidraw", ATTRS{idVendor}=="32ac", MODE="0660", GROUP="users", TAG+="uaccess"
# taken from here
SUBSYSTEMS=="usb", ATTRS{idVendor}=="32ac", ATTRS{idProduct}=="0013", TAG+="uaccess"
SUBSYSTEMS=="usb", ATTRS{idVendor}=="32ac", ATTRS{idProduct}=="0018", TAG+="uaccess"
# acording to https://community.frame.work/t/solved-keys-stick-and-repeat-after-being-released/51153/12
# the random keypress stuck comes from conflict between powertop and udev
# fix from: https://git.gabbie.blue/blue/nixconf/src/commit/2d1bc6dad4684c019b6b3e894408e76e2734806c/hosts/gabbielaptop/configuration.nix#L68
# disable USB auto suspend for framework keyboard
ACTION=="bind", SUBSYSTEM=="usb", ATTR{idVendor}=="32ac", ATTR{idProduct}=="0018", TEST=="power/control", ATTR{power/control}="on"
# disable USB auto suspend for framework macropad
ACTION=="bind", SUBSYSTEM=="usb", ATTR{idVendor}=="32ac", ATTR{idProduct}=="0013", TEST=="power/control", ATTR{power/control}="on"
'';
};
}
-551
View File
@@ -1,551 +0,0 @@
# OLD Deprecated.
{
config,
pkgs,
...
}:
# same as ./neovim.nix but you vim plug.
# i tried importing my nvim config from fedora to a more nixy way but a lot of settings and plugins didnt work. Maybe i'll fix it latter
# the only difference is the we use :PlugInstall or a similar command before doing anything
{
programs.neovim = {
enable = true;
vimAlias = true;
viAlias = true;
extraLuaConfig = ''
local vim = vim
-- local Plug = vim.fn['plug#']
vim.g.mapleader ='ü'
vim.g.maplocalleader = 'ü'
-- Set to true if you have a Nerd Font installed and selected in the terminal
vim.g.have_nerd_font = true
-- [[ Setting options ]]
-- See `:help vim.opt`
-- NOTE: You can change these options as you wish!
-- For more options, you can see `:help option-list`
-- Make line numbers default
-- You can also add relative line numbers, to help with jumping.
-- Experiment for yourself to see if you like it!
-- vim.opt.relativenumber = true
-- Enable mouse mode, can be useful for resizing splits for example!
vim.opt.mouse = 'a'
-- Don't show the mode, since it's already in the status line
vim.opt.showmode = true
-- Sync clipboard between OS and Neovim.
-- Schedule the setting after `UiEnter` because it can increase startup-time.
-- Remove this option if you want your OS clipboard to remain independent.
-- See `:help 'clipboard'`
vim.schedule(function()
vim.opt.clipboard = 'unnamedplus'
end)
-- Enable break indent
vim.opt.breakindent = true
-- Save undo history
vim.opt.undofile = true
-- Case-insensitive searching UNLESS \C or one or more capital letters in the search term
vim.opt.ignorecase = true
vim.opt.smartcase = true
-- Keep signcolumn on by default
vim.opt.signcolumn = 'yes'
-- Decrease update time
vim.opt.updatetime = 250
-- Decrease mapped sequence wait time
-- Displays which-key popup sooner
vim.opt.timeoutlen = 300
-- Configure how new splits should be opened
vim.opt.splitright = true
vim.opt.splitbelow = true
-- Sets how neovim will display certain whitespace characters in the editor.
-- See `:help 'list'`
-- and `:help 'listchars'`
vim.opt.list = true
vim.opt.listchars = { tab = '» ', trail = '·', nbsp = '' }
-- indentation settings - added by me
-- refere to https://stackoverflow.com/questions/51995128/setting-autoindentation-to-spaces-in-neovim for more information
vim.opt.expandtab = true
vim.opt.smartindent = true
vim.opt.tabstop = 4
vim.opt.shiftwidth = 4
-- Preview substitutions live, as you type!
vim.opt.inccommand = 'split'
-- Show which line your cursor is on
vim.opt.cursorline = true
-- Minimal number of screen lines to keep above and below the cursor.
vim.opt.scrolloff = 10
-- [[ Basic Keymaps ]]
-- See `:help vim.keymap.set()`
-- Clear highlights on search when pressing <Esc> in normal mode
-- See `:help hlsearch`
vim.keymap.set('n', '<Esc>', '<cmd>nohlsearch<CR>')
-- Diagnostic keymaps
vim.keymap.set('n', '<leader>q', vim.diagnostic.setloclist, { desc = 'Open diagnostic [Q]uickfix list' })
-- Exit terminal mode in the builtin terminal with a shortcut that is a bit easier
-- for people to discover. Otherwise, you normally need to press <C-\><C-n>, which
-- is not what someone will guess without a bit more experience.
--
-- NOTE: This won't work in all terminal emulators/tmux/etc. Try your own mapping
-- or just use <C-\><C-n> to exit terminal mode
vim.keymap.set('t', '<Esc><Esc>', '<C-\\><C-n>', { desc = 'Exit terminal mode' })
-- TIP: Disable arrow keys in normal mode
-- vim.keymap.set('n', '<left>', '<cmd>echo "Use h to move!!"<CR>')
-- vim.keymap.set('n', '<right>', '<cmd>echo "Use l to move!!"<CR>')
-- vim.keymap.set('n', '<up>', '<cmd>echo "Use k to move!!"<CR>')
-- vim.keymap.set('n', '<down>', '<cmd>echo "Use j to move!!"<CR>')
-- Keybinds to make split navigation easier.
-- Use CTRL+<hjkl> to switch between windows
--
-- See `:help wincmd` for a list of all window commands
vim.keymap.set('n', '<C-Left>', '<C-w><C-h>', { desc = 'Move focus to the left window' })
vim.keymap.set('n', '<C-Right>', '<C-w><C-l>', { desc = 'Move focus to the right window' })
vim.keymap.set('n', '<C-Down>', '<C-w><C-j>', { desc = 'Move focus to the lower window' })
vim.keymap.set('n', '<C-Up>', '<C-w><C-k>', { desc = 'Move focus to the upper window' })
-- jump to next error
vim.keymap.set("n", "t", vim.diagnostic.goto_prev)
vim.keymap.set("n", "z", vim.diagnostic.goto_next)
-- [[ Basic Autocommands ]]
-- See `:help lua-guide-autocommands`
-- Highlight when yanking (copying) text
-- Try it with `yap` in normal mode
-- See `:help vim.highlight.on_yank()`
vim.api.nvim_create_autocmd('TextYankPost', {
desc = 'Highlight when yanking (copying) text',
group = vim.api.nvim_create_augroup('kickstart-highlight-yank', { clear = true }),
callback = function()
vim.highlight.on_yank()
end,
})
--require("multiple-cursors").setup({
-- version = "*", -- Use the latest tagged version
-- opts = {}, -- This causes the plugin setup function to be called
-- keys = {
-- {"<C-j>", "<Cmd>MultipleCursorsAddDown<CR>", mode = {"n", "x"}, desc = "Add cursor and move down"},
-- {"<C-k>", "<Cmd>MultipleCursorsAddUp<CR>", mode = {"n", "x"}, desc = "Add cursor and move up"},
--
-- {"<C-Up>", "<Cmd>MultipleCursorsAddUp<CR>", mode = {"n", "i", "x"}, desc = "Add cursor and move up"},
-- {"<C-Down>", "<Cmd>MultipleCursorsAddDown<CR>", mode = {"n", "i", "x"}, desc = "Add cursor and move down"},
--
-- {"<C-LeftMouse>", "<Cmd>MultipleCursorsMouseAddDelete<CR>", mode = {"n", "i"}, desc = "Add or remove cursor"},
--
-- {"<Leader>m", "<Cmd>MultipleCursorsAddVisualArea<CR>", mode = {"x"}, desc = "Add cursors to the lines of the visual area"},
--
-- {"<Leader>a", "<Cmd>MultipleCursorsAddMatches<CR>", mode = {"n", "x"}, desc = "Add cursors to cword"},
-- {"<Leader>A", "<Cmd>MultipleCursorsAddMatchesV<CR>", mode = {"n", "x"}, desc = "Add cursors to cword in previous area"},
--
-- {"<Leader>d", "<Cmd>MultipleCursorsAddJumpNextMatch<CR>", mode = {"n", "x"}, desc = "Add cursor and jump to next cword"},
-- {"<Leader>D", "<Cmd>MultipleCursorsJumpNextMatch<CR>", mode = {"n", "x"}, desc = "Jump to next cword"},
--
-- {"<Leader>l", "<Cmd>MultipleCursorsLock<CR>", mode = {"n", "x"}, desc = "Lock virtual cursors"},
-- },
--})
vim.keymap.set("n","§", "<cmd>Cheatsheet<CR>")
require("cheatsheet").setup({
bundled_cheatsheets = {
-- only show the default cheatsheet
enabled = { "default" },
},
bundled_plugin_cheatsheets = {
-- show cheatsheets for all plugins except gitsigns
disabled = { "gitsigns.nvim" },
}
})
-- Can be applied to each buffer separately
local default_options = {
ui = {
wrap_line_after = false, -- wrap the line after this length to avoid the virtual text is too long
left_kept_space = 3, --- the number of spaces kept on the left side of the virtual text, make sure it enough to custom for each line
right_kept_space = 3, --- the number of spaces kept on the right side of the virtual text, make sure it enough to custom for each line
arrow = " ",
up_arrow = " ",
down_arrow = " ",
above = false, -- the virtual text will be displayed above the line
},
priority = 2003, -- the priority of virtual text
inline = true,
}
-- scrollbar
require("scrollbar").setup()
-- ufo https://github.com/kevinhwang91/nvim-ufo
vim.o.foldcolumn = '1' -- '0' is not bad
vim.o.foldlevel = 99 -- Using ufo provider need a large value, feel free to decrease the value
vim.o.foldlevelstart = 99
vim.o.foldenable = true
-- Using ufo provider need remap `zR` and `zM`. If Neovim is 0.6.1, remap yourself
vim.keymap.set('n', '1', "<cmd>foldopen<CR>")
vim.keymap.set('n', '2', "<cmd>foldclose<CR>")
vim.keymap.set('n', '3', "<cmd>openAllFold<CR>")
vim.keymap.set('n', '4', "<cmd> closeAllFold<CR>")
-- Option 3: treesitter as a main provider instead
-- (Note: the `nvim-treesitter` plugin is *not* needed.)
-- ufo uses the same query files for folding (queries/<lang>/folds.scm)
-- performance and stability are better than `foldmethod=nvim_treesitter#foldexpr()`
--vim.keymap.set('n', '1', function() require("ufo").foldopen() end, {buffer=0})
--vim.keymap.set('n', '2', function() require("ufo").foldclose() end)
-- added by myself
require('ufo').setup({
provider_selector = function(bufnr, filetype, buftype)
return {'treesitter', 'indent'}
end
})
-- Color schemes should be loaded after plug#end().
vim.o.background = "dark" -- or "light" for light mode
-- Default options:
require("gruvbox").setup({
terminal_colors = true, -- add neovim terminal colors
undercurl = true,
underline = true,
bold = true,
italic = {
strings = true,
emphasis = true,
comments = true,
operators = false,
folds = true,
},
strikethrough = true,
invert_selection = false,
invert_signs = false,
invert_tabline = false,
invert_intend_guides = false,
inverse = true, -- invert background for search, diffs, statuslines and errors
contrast = "", -- can be "hard", "soft" or empty string
palette_overrides = {},
overrides = {},
dim_inactive = false,
transparent_mode = false,
})
vim.cmd("colorscheme gruvbox")
-- nvim-tree https://github.com/nvim-tree/nvim-tree.lua
-- disable netrw at the very start of your init.lua
vim.g.loaded_netrw = 1
vim.g.loaded_netrwPlugin = 1
-- optionally enable 24-bit colour
vim.opt.termguicolors = true
-- setup with some options
require("nvim-tree").setup({
sort = {
sorter = "case_sensitive",
},
view = {
width = 30,
},
renderer = {
group_empty = true,
},
filters = {
dotfiles = true,
},
})
vim.opt.number = true
-- Uncomment for opening the navigable tree file systeme on startup of NeoVim
--vim.cmd('NvimTreeOpen')
require('md-pdf').setup({
--- Set margins around document
margins = "1.5cm",
-- tango, pygments are quite nice for white on white
highlight = "tango",
-- Generate a table of contents, on by default
toc = true,
-- Define a custom preview command, enabling hooks and other custom logic
preview_cmd = function() return 'firefox' end,
-- if true, then the markdown file is continuously converted on each write, even if the
-- file viewer closed, e.g., firefox is "closed" once the document is opened in it.
ignore_viewer_state = false,
-- Specify font, `nil` uses the default font of the theme
fonts = nil,
-- or, where all or only some options can be specified. NOTE: those that are `nil` can be left
-- out completely
fonts = {
main_font = nil,
sans_font = "DejaVuSans",
mono_font = "IosevkaTerm Nerd Font Mono",
math_font = nil,
},
-- Custom options passed to `pandoc` CLI call, can be ignored for setup
pandoc_user_args = nil,
-- or
pandoc_user_args = {
-- short
"-V KEY[:VALUE]",
-- long options
"--standalone=[true|false]",
},
--- Path to output. Needs to be always relative, e.g.: "./", "../", "./out" or simply "out", but
--- not absolute e.g.: "/"!
output_path = "",
})
-- setup mapping
vim.keymap.set("n", "<Space>,", function()
require('md-pdf').convert_md_to_pdf()
end)
-- Set up nvim-cmp.
local cmp = require'cmp'
cmp.setup({
snippet = {
-- REQUIRED - you must specify a snippet engine
expand = function(args)
vim.fn["vsnip#anonymous"](args.body) -- For `vsnip` users.
-- require('luasnip').lsp_expand(args.body) -- For `luasnip` users.
-- require('snippy').expand_snippet(args.body) -- For `snippy` users.
-- vim.fn["UltiSnips#Anon"](args.body) -- For `ultisnips` users.
-- vim.snippet.expand(args.body) -- For native neovim snippets (Neovim v0.10+)
end,
},
window = {
-- completion = cmp.config.window.bordered(),
-- documentation = cmp.config.window.bordered(),
},
mapping = cmp.mapping.preset.insert({
['<C-b>'] = cmp.mapping.scroll_docs(-4),
['<C-f>'] = cmp.mapping.scroll_docs(4),
['<C-Space>'] = cmp.mapping.complete(),
['<C-e>'] = cmp.mapping.abort(),
['<CR>'] = cmp.mapping.confirm({ select = true }), -- Accept currently selected item. Set `select` to `false` to only confirm explicitly selected items.
}),
sources = cmp.config.sources({
{ name = 'nvim_lsp' },
{ name = 'vsnip' }, -- For vsnip users.
-- { name = 'luasnip' }, -- For luasnip users.
-- { name = 'ultisnips' }, -- For ultisnips users.
-- { name = 'snippy' }, -- For snippy users.
}, {
{ name = 'buffer' },
})
})
-- To use git you need to install the plugin petertriho/cmp-git and uncomment lines below
-- Set configuration for specific filetype.
--[[ cmp.setup.filetype('gitcommit', {
sources = cmp.config.sources({
{ name = 'git' },
}, {
{ name = 'buffer' },
})
})
require("cmp_git").setup() ]]--
-- Use buffer source for `/` and `?` (if you enabled `native_menu`, this won't work anymore).
cmp.setup.cmdline({ '/', '?' }, {
mapping = cmp.mapping.preset.cmdline(),
sources = {
{ name = 'buffer' }
}
})
-- Use cmdline & path source for ':' (if you enabled `native_menu`, this won't work anymore).
cmp.setup.cmdline(':', {
mapping = cmp.mapping.preset.cmdline(),
sources = cmp.config.sources({
{ name = 'path' }
}, {
{ name = 'cmdline' }
}),
matching = { disallow_symbol_nonprefix_matching = false }
})
-- require(lspconfig) is deprecated
-- -- Set up lspconfig.
-- local capabilities = require('cmp_nvim_lsp').default_capabilities()
-- -- Replace <YOUR_LSP_SERVER> with each lsp server you've enabled.
-- require('lspconfig')['texlab'].setup {
-- capabilities = capabilities
-- }
--require'lspconfig'.clangd.setup{}
--lspconfig = require("lspconfig")
--lspconfig.pylsp.setup {
--on_attach = custom_attach,
--settings = {
-- pylsp = {
-- plugins = {
-- -- formatter options
-- black = { enabled = true },
-- autopep8 = { enabled = false },
-- yapf = { enabled = false },
-- -- linter options
-- pylint = { enabled = true, executable = "pylint" },
-- pyflakes = { enabled = false },
-- pycodestyle = { enabled = false },
-- -- type checker
-- pylsp_mypy = { enabled = true },
-- -- auto-completion options
-- jedi_completion = { fuzzy = true },
-- -- import sorting
-- pyls_isort = { enabled = true },
-- },
-- },
--},
--flags = {
-- debounce_text_changes = 200,
--},
--capabilities = capabilities,
--}
---- lua-lsp
--require'lspconfig'.lua_ls.setup{}
--
--new version
-- ============================
-- LSP CONFIGURATION (Neovim 0.11+)
-- ============================
-- Set up capabilities for nvim-cmp LSP completion
local capabilities = require('cmp_nvim_lsp').default_capabilities()
-- Optional: custom on_attach function if you have keymaps
-- local custom_attach = function(client, bufnr)
-- -- your on_attach code here
-- end
-- Utility function to simplify server setup
local function setup_lsp(server_name, opts)
vim.lsp.config(server_name, opts or {})
end
-- ======== LSP SERVERS ========
-- TeXLab
setup_lsp("texlab", {
capabilities = capabilities,
})
-- Clangd (C/C++)
setup_lsp("clangd", {
capabilities = capabilities,
})
-- Python LSP (pylsp)
setup_lsp("pylsp", {
on_attach = custom_attach,
capabilities = capabilities,
flags = {
debounce_text_changes = 200,
},
settings = {
pylsp = {
plugins = {
-- Formatter options
black = { enabled = true },
autopep8 = { enabled = false },
yapf = { enabled = false },
-- Linter options
pylint = { enabled = true, executable = "pylint" },
pyflakes = { enabled = false },
pycodestyle = { enabled = false },
-- Type checker
pylsp_mypy = { enabled = true },
-- Auto-completion options
jedi_completion = { fuzzy = true },
-- Import sorting
pyls_isort = { enabled = true },
},
},
},
})
-- Lua LSP
setup_lsp("lua_ls", {
capabilities = capabilities,
})
-- dashboard config
require('dashboard').setup {
theme = 'hyper',
config = {
header = {
" ... ... . ",
" .=*8888n..\"%888: @88> ",
" X ?8888f '8888 u. ... .. %8P .. . : ",
" 88x. '8888X 8888> .u ...ue888b :~\"\"888h.:^\"888: . .888: x888 x888. ",
"'8888k 8888X '\"*8h. ud8888. 888R Y888r 8X `8888X 8888> .@88u ~`8888~'888X`?888f` ",
" \"8888 X888X .xH8 :888'8888. 888R I888> X888n. 8888X ?888> '\"888E` X888 888X '888> ",
" `8\" X888!:888X d888 '88%\" 888R I888> '88888 8888X ?**h. 888E X888 888X '888> ",
" =~` X888 X888X 8888.+\" 888R I888> `*88 8888~ x88x. 888E X888 888X '888> ",
" :h. X8*` !888X 8888L u8888cJ888 ..<\" 88*` 88888X 888E X888 888X '888> ",
" X888xX\" '8888..: '8888c. .+ \"*888*P\" ..XC. `*8888k 888& \"*88%\"\"*88\" '888!` ",
":~`888f '*888*\" \"88888% 'Y\" :888888H. `%88> R888\" `~ \" `\"` ",
" \"\" `\"` \"YP' < `\"888888: X\" \"\" ",
" %888888x.-` ",
" \"\"**\"\" ",
"",
""
},
shortcut = {
{ desc = " Open File Tree", group = "", key = 't', action = 'NvimTreeOpen' },
-- action can be a function type
},
packages = { enable = false }, -- show how many plugins neovim loaded
-- limit how many projects list, action when you press key or enter it will run this action.
-- action can be a functino type, e.g.
-- action = func(path) vim.cmd('Telescope find_files cwd=' .. path) end
project = { enable = true, limit = 8, icon = ' New file', label = "", action = 'Telescope find_files cwd=' },
mru = { limit = 10, icon = ' History', label = "", cwd_only = false },
footer = {}, -- footer
}
}
-- lualine config https://github.com/nvim-lualine/lualine.nvim/blob/master/examples/bubbles.lua
require('lualine').setup {
options = { theme = "gruvbox_dark" },
}
local builtin = require('telescope.builtin')
vim.keymap.set('n', '<leader>ff', builtin.find_files, { desc = 'Telescope find files' })
vim.keymap.set('n', '<leader>fg', builtin.live_grep, { desc = 'Telescope live grep' })
vim.keymap.set('n', '<leader>fb', builtin.buffers, { desc = 'Telescope buffers' })
vim.keymap.set('n', '<leader>fh', builtin.help_tags, { desc = 'Telescope help tags' })
'';
};
}
-12
View File
@@ -1,12 +0,0 @@
_: {
programs.anki = {
# we enable system wide with nixpkgs because it offers some addon configuration. We just use this for some config
#enable = true;
theme = "dark";
sync = {
autoSync = true;
autoSyncMediaMinutes = 10;
syncMedia = true;
};
};
}
-5
View File
@@ -1,5 +0,0 @@
_: {
services.batsignal = {
enable = true;
};
}
-597
View File
@@ -1,597 +0,0 @@
_: let
sisyphe = ../../assets/sisyphe.gif;
pepe-music = ../../assets/pepe-music.gif;
in {
home.file.".local/state/caelestia/wallpaper/path.txt" = {
# dummy file. Does nothing. Prevent an error
enable = true;
text = "${sisyphe}";
};
home.file.".face" = {
# this is were caelestia will search for profiles pictures
source = ../../assets/sisyphePFP.png;
};
# set profile picture in ~/.face
programs.caelestia = {
enable = true;
systemd = {
enable = false; # if we launch it form here, the keybinds don't work
target = "graphical-session.target";
environment = [];
};
settings = {
# default config https://github.com/caelestia-dots/shell?tab=readme-ov-file#example-configuration
appearance = {
mediaGifSpeedAdjustment = 500;
sessionGifSpeed = 0.7;
anim = {
duration = {
scale = 1;
};
};
/*
font = {
family = {
clock = "Rubik"; # (TODO figure out those fonts)
material = "Material Symboles Rounded";
mono = "CaskaydiaCove NF";
sans = "Rubik";
};
size = {
scale = 1;
};
};
*/
padding = {
scale = 1;
};
rounding = {
scale = 1;
};
spacing = {
scale = 1;
};
transparency = {
enabled = false;
base = 0.85;
layeres = 0.4;
};
};
general = {
logo = "caelestia";
apps = {
terminal = ["kitty"]; # default foot
audio = ["pavucontrol"];
playback = ["vlc"]; # what's that?
explorer = ["dolphin"]; # default thunar
};
battery = {
wanLevels = [
{
level = 20;
title = "Low battery";
message = "You might want to plug in a charger";
icon = "battery_android_frame_2";
}
{
level = 10;
title = "Did you see the previous message?";
message = "You should probably plug in a charger <b>now</b>";
icon = "battery_android_frame_1";
}
{
level = 5;
title = "Critical battery level";
message = "PLUG THE CHARGER RIGHT NOW!!";
icon = "battery_android_alert";
critical = true;
}
];
criticalLevel = 3;
};
idle = {
lockBeforeSleep = true;
inhibitWhenAudio = true;
timeouts = [
{
timeout = 180;
idleAction = "lock";
}
{
timeout = 300;
idleAction = "dpms off"; # what's that?
returnAction = "dpms on";
}
{
timeout = 600;
idleAction = ["systemctl" "suspend-then-hibernate"];
}
];
};
};
background = {
desktopClock = {
enabled = false;
scale = 1.0;
position = "bottom-right";
shadow = {
enabled = true;
opacity = 0.7;
blur = 0.4;
};
background = {
enabled = false;
opacity = 0.7;
blur = true;
};
invertColors = false;
};
enabled = false; #default true
visualiser = {
blur = false;
enabled = false;
autohide = true;
rounding = 1;
spacing = 1;
};
};
bar = {
activeWindow = {
compact = false;
inverted = false;
showOnHover = true;
};
clock = {
background = true;
showDate = true;
showIcon = true;
};
dragThreshold = 20;
entries = [
{
id = "logo";
enabled = true;
}
{
id = "workspaces";
enabled = true;
}
{
id = "spacer";
enabled = true;
}
{
id = "activeWindow";
enabled = true;
}
{
id = "spacer";
enabled = true;
}
{
id = "tray";
enabled = true;
}
{
id = "clock";
enabled = true;
}
{
id = "statusIcon";
enabled = true;
}
{
id = "power";
enabled = true;
}
];
persistent = true;
popouts = {
activeWindow = true;
statusIcon = true;
tray = true;
};
scrollActions = {
brightness = true;
workspaces = true;
volume = true;
};
showOnHover = true;
status = {
showAudio = false;
showBattery = false; # use powerprofile daemon
showBluetooth = false;
showKbLayout = false;
showMicrophone = false;
showNetwork = false;
showWifi = true;
showLockStatus = false;
};
tray = {
background = true; # default true
compact = false;
iconSubs = [];
recolour = true;
};
workspaces = {
activeIndicator = true;
activeLabel = "󰮯";
activeTrail = false;
label = " ";
occupiedBg = false;
occpiedLabel = "󰮯";
perMonitorWorkspaces = true;
showWindows = true;
shown = 5;
specialWorkspaceIcons = [
{
name = "steam";
icon = "sports_esports";
}
];
windowIcons = [
{
regex = "steam(_app_(default|[0-9]+))?";
icon = "sports_esports";
}
];
};
excludedScreens = [""]; # default says "" those this work?
};
border = {
rounding = 25;
thickness = 10;
};
dashboard = {
enabled = true;
dragThreshold = 50;
mediaUpdateInterval = 500;
showOnHover = true;
};
launcher = {
actionsPrefix = ">";
actions = [
{
name = "Calculator";
icon = "calculate";
description = "Do simple math equations (powered by Qalc)";
command = ["autocomplete" "calc"];
enabled = false; # default true
dangerous = false;
}
{
name = "Scheme";
icon = "palette";
description = "Change the current colour scheme";
command = ["autocomplete" "scheme"];
enabled = false; # default true
dangerous = false;
}
{
name = "Wallpaper";
icon = "image";
description = "Change the current wallpaper";
command = ["autocomplete" "wallpaper"];
enabled = false; # default true
dangerous = false;
}
{
name = "Variant"; # to remove
icon = "colors";
description = "Change the current scheme variant";
command = ["autocomplete" "variant"];
enabled = true;
dangerous = false;
}
{
name = "Transparency";
icon = "opacity";
description = "Change shell transparency";
command = ["autocomplete" "transparency"];
enabled = false;
dangerous = false;
}
{
name = "Random";
icon = "casino";
description = "Switch to a random wallpaper";
command = ["caelestia" "wallpaper" "-r"];
enabled = false; # default true
dangerous = false;
}
{
name = "Light";
icon = "light_mode";
description = "Change the scheme to light mode";
command = ["setMode" "light"];
enabled = false; # default true
dangerous = false;
}
{
name = "Dark";
icon = "dark_mode";
description = "Change the scheme to dark mode";
command = ["setMode" "dark"];
enabled = false; # default true
dangerous = false;
}
{
name = "Shutdown";
icon = "power_settings_new";
description = "Shutdown the system";
command = ["systemctl" "poweroff"];
enabled = true;
dangerous = true;
}
{
name = "Reboot";
icon = "cached";
description = "Reboot the system";
command = ["systemctl" "reboot"];
enabled = true;
dangerous = true;
}
{
name = "Lock"; # does this work with ly?
icon = "lock";
description = "Log out of the current session";
command = ["loginctl" "terminate-user" ""];
enabled = true;
dangerous = true;
}
{
name = "Sleep";
icon = "bedtime";
description = "Suspend then hibernate";
command = ["systemctl" "suspend-then-hibernate"];
enabled = true;
dangerous = false;
}
{
name = "Settings";
icon = "settings";
description = "Configure the shell";
command = ["caelestia" "shell" "controlCenter" "open"];
enabled = false; # default true
dangerous = false;
}
];
dragThreshold = 50;
vimKeybinds = false; # intersting to put to true
enableDangerousActions = false; # set to true
maxShown = 7;
maxWallpapers = 9;
specialPrefix = "@";
useFuzzy = {
# should try
apps = false;
actions = false;
schemes = false;
variants = false;
wallpapers = false;
};
showOnHover = false;
favouriteApps = [];
hiddenApps = [];
};
lock = {
recolourLogo = false; # what's that
hideNotifs = false;
};
notifs = {
actionOnClick = false;
clearThreshold = 0.3;
defaultExpireTimeout = 5000;
expantThreshold = 20;
openeExpanded = false;
expire = true;
};
osd = {
# thats the slider for brightness and sound
enabled = true;
enableBrightness = true;
enableMicrophone = false;
hideDelay = 2000;
};
paths = {
mediaGif = pepe-music; # default "root:/assets/bongocat.gif"
sessionGif = sisyphe; # default "root:/assets/kurukuru.gif"
noNotifsPic = "root:/assets/dino.png";
lockNoNotifsPic = "root:/assets/dino.png";
wallpaperDir = "~/Pictures/Wallpapers";
lyricsDir = "~/Music/lyrics";
};
services = {
audioIncrement = 0.1;
brightnessIncrement = 0.1;
maxVolume = 1.0;
defaultPlayer = "Spotify";
gpuType = "";
#playerAliases: [ { "from": "com.github.th_ch.youtube_music", "to": "YT Music" } ]; # how to put this into nix language?
weatherLocation = "Lausanne";
useFahrenheit = false;
useFahrenheitPerformance = false;
useTwelveHourClock = false;
smartScheme = false; # default true
visualisersBars = 45;
};
session = {
dragThreshold = 30; # what does dragThreshold do?
enabled = true;
vimKeybinds = false; # maybe set to true?
icons = {
logout = "logout";
shutdown = "power_settings_new";
hibernate = "downloading"; # find a better icon
reboot = "cached";
};
commands = {
logout = ["hyprctl" "dispatch exit"];
shutdown = ["systemctl" "poweroff"];
hibernate = ["systemctl" "hibernate"];
reboot = ["systemctl" "reboot"];
};
};
sidebar = {
dragThreshold = 80;
enabled = true;
};
# is there a way to get some system info?
utilities = {
enabled = true;
maxToasts = 4; # toats are like notification but on the botto left
toasts = {
audioInputChanged = true;
audioOutputChanged = true;
capsLockChanged = true;
chargingChanged = true;
configLoaded = true;
dndChanged = true;
gameModeChanged = true;
kbLayoutChanged = true;
kbLimit = true;
numLockChanged = true;
vpnChanged = true;
nowPlaying = false;
};
};
vpn = {
enabled = false; # default true
provider = [
{
# default example-configuration
name = "wireguard";
interface = "your-connection-name";
displayName = "wireguard (Your VPN)";
enabled = false;
}
];
};
quickToggles = [
{
id = "wifi";
enabled = true;
}
{
id = "bluetooth";
enabled = true;
}
{
id = "mic";
enabled = true;
}
{
id = "settings";
enabled = true; # should desactivate
}
{
id = "gameMode";
enabled = true; # should remap my performance mode
}
{
id = "dnd"; #do not disturb
enabled = true;
}
{
id = "vpn";
enabled = false; # default true;
}
];
};
cli = {
# default config https://github.com/caelestia-dots/cli?tab=readme-ov-file#configuring
enable = true; # Also add caelestia-cli to path
settings = {
record = {
extraArgs = [];
};
wallpaper = {
postHook = "caelestia scheme set -n gruvbox -f soft -m dark"; # sets the theme
};
theme = {
enableTerm = false; # we do it manually by adapting our kitty config
enableHypr = false; # this seems to add the splash
enableDiscord = true;
enableSpicetify = true;
enableFuzzel = true; #what's that?
enablleBtop = false; # default true
enableQt = true;
};
toggles = {
communication = {
discord = {
enable = false; # default true
match = [
{
class = "discord";
}
];
whatsapp = {
enable = true;
match = [
{
class = "whatsapp";
}
];
};
};
};
music = {
spotify = {
enable = false; # default true
match = [
{
class = "Spotify";
}
{
initialTitle = "Spotify";
}
{
initialTitle = "Spotify Free";
}
];
command = ["spicetify" "watch" "-s"];
move = true;
};
feishin = {
enable = true;
match = [
{
class = "feishin";
}
];
move = true;
};
};
sysmon = {
btop = {
enable = true;
match = [
{
class = "btop";
title = "btop";
workspace = {
name = "special:sysmon";
};
}
];
command = ["foot" "-a" "btop" "-T" "btop" "fish" "-C" "exec btop"]; # maybe switch to btm and kitty?
};
};
todo = {
todoist = {
enable = false; # default true
match = [
{
class = "Todoist";
}
];
command = ["todoist"];
move = true;
};
};
};
};
};
};
}
-13
View File
@@ -1,13 +0,0 @@
# don't works. some GTK error. I let it here if someday, someone is interest in this shit.
# ChatGPT half baked a replacement that works on my system.
# see ../qt/qtbatticon
_: {
services.cbatticon = {
enable = true;
lowLevelPercent = 20;
criticalLevelPercent = 5;
batteryId = "BAT1";
hideNotification = true; # we use another script for battery notifications
updateIntervalSeconds = 10;
};
}
-9
View File
@@ -1,9 +0,0 @@
{pkgs, ...}: {
home.pointerCursor = {
hyprcursor.enable = true;
enable = true;
package = pkgs.capitaine-cursors-themed;
name = "Capitaine Cursors (Gruvbox)";
size = 32;
};
}
-114
View File
@@ -1,114 +0,0 @@
_:
# ls replacement
# see ./zsh.nix for the alias (usefull to se default flags)
{
programs.eza = {
enable = true;
enableZshIntegration = true;
theme = {
# from https://github.com/eza-community/eza-themes/blob/main/themes/gruvbox-dark.yml
colourful = true;
filekinds = {
normal = {foreground = "#ebdbb2";};
directory = {foreground = "#83a598";};
symlink = {foreground = "#8ec07c";};
pipe = {foreground = "#928374";};
block_device = {foreground = "#fb4934";};
char_device = {foreground = "#fb4934";};
socket = {foreground = "#665c54";};
special = {foreground = "#d3869b";};
executable = {foreground = "#b8bb26";};
mount_point = {foreground = "#fe8019";};
};
perms = {
user_read = {foreground = "#ebdbb2";};
user_write = {foreground = "#fabd2f";};
user_execute_file = {foreground = "#b8bb26";};
user_execute_other = {foreground = "#b8bb26";};
group_read = {foreground = "#ebdbb2";};
group_write = {foreground = "#fabd2f";};
group_execute = {foreground = "#b8bb26";};
other_read = {foreground = "#bdae93";};
other_write = {foreground = "#fabd2f";};
other_execute = {foreground = "#b8bb26";};
special_user_file = {foreground = "#d3869b";};
special_other = {foreground = "#928374";};
attribute = {foreground = "#bdae93";};
};
size = {
major = {foreground = "#bdae93";};
minor = {foreground = "#8ec07c";};
number_byte = {foreground = "#ebdbb2";};
number_kilo = {foreground = "#ebdbb2";};
number_mega = {foreground = "#83a598";};
number_giga = {foreground = "#d3869b";};
number_huge = {foreground = "#d3869b";};
unit_byte = {foreground = "#bdae93";};
unit_kilo = {foreground = "#83a598";};
unit_mega = {foreground = "#d3869b";};
unit_giga = {foreground = "#d3869b";};
unit_huge = {foreground = "#fe8019";};
};
users = {
user_you = {foreground = "#ebdbb2";};
user_root = {foreground = "#fb4934";};
user_other = {foreground = "#d3869b";};
group_yours = {foreground = "#ebdbb2";};
group_other = {foreground = "#928374";};
group_root = {foreground = "#fb4934";};
};
links = {
normal = {foreground = "#8ec07c";};
multi_link_file = {foreground = "#fe8019";};
};
git = {
new = {foreground = "#b8bb26";};
modified = {foreground = "#fabd2f";};
deleted = {foreground = "#fb4934";};
renamed = {foreground = "#8ec07c";};
typechange = {foreground = "#d3869b";};
ignored = {foreground = "#928374";};
conflicted = {foreground = "#cc241d";};
};
git_repo = {
branch_main = {foreground = "#ebdbb2";};
branch_other = {foreground = "#d3869b";};
git_clean = {foreground = "#b8bb26";};
git_dirty = {foreground = "#fb4934";};
};
security_context = {
colon = {foreground = "#928374";};
user = {foreground = "#ebdbb2";};
role = {foreground = "#d3869b";};
typ = {foreground = "#665c54";};
range = {foreground = "#d3869b";};
};
file_type = {
image = {foreground = "#fabd2f";};
video = {foreground = "#fb4934";};
music = {foreground = "#b8bb26";};
lossless = {foreground = "#8ec07c";};
crypto = {foreground = "#928374";};
document = {foreground = "#ebdbb2";};
compressed = {foreground = "#d3869b";};
temp = {foreground = "#cc241d";};
compiled = {foreground = "#83a598";};
build = {foreground = "#928374";};
source = {foreground = "#83a598";};
punctuation = {foreground = "#928374";};
date = {foreground = "#fabd2f";};
inode = {foreground = "#bdae93";};
blocks = {foreground = "#a89984";};
header = {foreground = "#ebdbb2";};
octal = {foreground = "#8ec07c";};
flags = {foreground = "#d3869b";};
symlink_path = {foreground = "#8ec07c";};
control_char = {foreground = "#83a598";};
broken_symlink = {foreground = "#fb4934";};
broken_path_overlay = {foreground = "#928374";};
};
};
};
}
-174
View File
@@ -1,174 +0,0 @@
_: {
# Adapted from https://github.com/dacrab/fastfetch-config/blob/main/config.jsonc
programs.fastfetch = {
enable = true;
settings = {
logo = {
type = "none";
#source = "nixos";
};
modules = [
# ───────────── Hardware ─────────────
{
type = "custom";
format = " Hardware ";
outputColor = "blue";
}
{
type = "title";
key = " PC";
keyColor = "green";
}
{
type = "host";
key = " 󰇅 Laptop";
keyColor = "green";
}
{
type = "display";
key = " 󰍹 Display";
keyColor = "green";
}
{
type = "cpu";
key = " 󰍛 CPU";
showPeCoreCount = true;
format = "{1}";
keyColor = "green";
}
{
type = "gpu";
key = " 󰍛 GPU";
keyColor = "green";
}
{
type = "memory";
key = " 󰍛 Memory";
keyColor = "green";
}
{
type = "custom";
format = "";
outputColor = "blue";
}
# ───────────── Software ─────────────
{
type = "custom";
format = " Software ";
outputColor = "blue";
}
{
type = "os";
key = " OS";
keyColor = "cyan";
}
{
type = "kernel";
key = " Kernel";
keyColor = "cyan";
}
{
type = "packages";
key = " 󰏖 Packages";
keyColor = "cyan";
}
{
type = "shell";
key = " Shell";
keyColor = "cyan";
}
{
type = "terminal";
key = " Terminal";
keyColor = "cyan";
}
{
type = "command";
key = " OS Age";
keyColor = "cyan";
text = ''
birth_install=$(stat -c %W /)
current=$(date +%s)
time_progression=$((current - birth_install))
days_difference=$((time_progression / 86400))
echo $days_difference days
'';
}
{
type = "uptime";
key = " Uptime";
keyColor = "cyan";
}
{
type = "de";
key = " DE";
keyColor = "blue";
}
{
type = "wm";
key = " WM";
keyColor = "magenta";
}
{
type = "gpu";
key = " 󰍛 GPU Driver";
format = "{3}";
keyColor = "magenta";
}
{
type = "brightness";
key = " 󰃟 Brightness";
keyColor = "magenta";
}
{
type = "version";
key = " FastFetch";
keyColor = "magenta";
}
{
type = "custom";
format = "";
outputColor = "blue";
}
#{
# type = "custom";
# format = ''
# {#0} {#1} {#2} {#3} {#4} {#5} {#6} {#7}
# '';
#} #for some reason dont work
{
type = "colors";
symbol = "diamond";
}
"break"
];
};
};
}
-12
View File
@@ -1,12 +0,0 @@
_: {
programs.git = {
enable = true;
settings = {
init.defaultBranch = "main";
};
};
programs.gh = {
enable = true;
gitCredentialHelper.enable = true;
};
}
-12
View File
@@ -1,12 +0,0 @@
{pkgs, ...}: {
# gtk config
gtk.theme = {
enable = true;
Gruvbox-GTK-Theme-BL-MB = {
enable = true;
name = "Gruvbox-GTK-Theme-BL-MB";
package = pkgs.gruvbox-gtk-theme;
};
};
# to resolve this https://wiki.nixos.org/wiki/Home_Manager#I_cannot_set_GNOME_or_Gtk_themes_via_Home_Manager
}
-20
View File
@@ -1,20 +0,0 @@
_: {
services.hypridle = {
enable = true;
settings = {
general = {
lock_cmd = "notify-send 'lock!'"; # dbus/sysd lock command (loginctl lock-session)
unlock_cmd = "notify-send 'unlock!'"; # same as above, but unlock
before_sleep_cmd = "notify-send 'Zzz'"; # command ran before sleep
after_sleep_cmd = "notify-send 'Awake!"; # command ran after sleep
ignore_dbus_inhibit = false; # whether to ignore dbus-sent idle-inhibit requests (used by e.g. firefox or steam)
ignore_systemd_inhibit = false; # whether to ignore systemd-inhibit --what=idle inhibitors
};
listener = {
timeout = 500; # in seconds
on-timeout = "notify-send 'You are idle!'"; # command to run when timeout has passed
on-resume = "notify-send 'Welcome back!'"; # command to run when activity is detected after timeout has fired.
};
};
};
}
-452
View File
@@ -1,452 +0,0 @@
{pkgs-unstable, ...}: let
wallpaper = ../../assets/wallpaper1.jpg;
in {
#refer to https://wiki.hypr.land/Nix/Hyprland-on-Home-Manager/
wayland.windowManager.hyprland.enable = true;
wayland.windowManager.hyprland.package = pkgs-unstable.hyprland;
#hint Electron apps to use on wayland;
home.sessionVariables.NIXOS_OZONE_WL = "1";
wayland.windowManager.hyprland.plugins = [
#pkgs-unstable.hyprlandPlugins.hyprspace # currently broken
#pkgs-unstable.hyprlandPlugins.hypr-dynamic-cursors # currently broken
];
wayland.windowManager.hyprland.settings = {
"$mod" = "SUPER";
"$term" = "kitty";
"$editor" = "nvim";
"$notes" = "kitty --class \"custom-obsidianvaults\" --name \"Select Obsidian vault\" --hold custom-obsidianvaults";
"$file" = "dolphin";
"$browser" = "kitty --class \"custom-librewolfprofiles\" --name \"Select LibreWolf profile\" --hold custom-librewolfprofiles";
# ▄▀█ █▄░█ █ █▀▄▀█ ▄▀█ ▀█▀ █ █▀█ █▄░█
# █▀█ █░▀█ █ █░▀░█ █▀█ ░█░ █ █▄█ █░▀█
animations = {
enabled = true;
bezier = [
"wind, 0.05, 0.9, 0.1, 1.05"
"winIn, 0.1, 1.1, 0.1, 1.1"
"winOut, 0.3, -0.3, 0, 1"
"liner, 1, 1, 1, 1"
];
animation = [
"windows, 1, 6, wind, slide"
"windowsIn, 1, 6, winIn, slide"
"windowsOut, 1, 5, winOut, slide"
"windowsMove, 1, 5, wind, slide"
"border, 1, 1, liner"
"borderangle, 1, 30, liner, loop"
"fade, 1, 10, default"
"workspaces, 1, 5, wind"
];
};
# █▀▀ █▄░█ █░█
# ██▄ █░▀█ ▀▄▀
# See https://wiki.hyprland.org/Configuring/Environment-variables/
env = [
"PATH, $PATH:$scrPath"
"XDG_CURRENT_DESKTOP,Hyprland"
"XDG_SESSION_TYPE,wayland"
"XDG_SESSION_DESKTOP,Hyprland"
"QT_QPA_PLATFORM,wayland;xcb"
"QT_QPAPLATFORMTHEME,qt6ct"
"QT_WAYLAND_DISABLE_WINDOWDECORATION,1"
"MOZ_ENABLE_WAYLAND,1"
"GDK_SCALE,1"
];
# █ █▄░█ █▀█ █░█ ▀█▀
# █ █░▀█ █▀▀ █▄█ ░█░
input = {
kb_layout = ["ch"];
follow_mouse = 1;
sensitivity = 0;
force_no_accel = 1;
};
# █▄▀ █▀▀ █▄█ █▄▄ █ █▄░█ █▀▄ █ █▄░█ █▀▀ █▀
# █░█ ██▄ ░█░ █▄█ █ █░▀█ █▄▀ █ █░▀█ █▄█ ▄█
# caelestia shell drawers toggle dashboard
# caelestia shell drawers toggle utilities
bind = [
#hyprland/utility keybindings
"$mod, W, togglefloating"
"$mod, G, togglegroup"
"Alt, Return, fullscreen"
"$mod, Left, movefocus, l"
"$mod, Right, movefocus, r"
"$mod, Up, movefocus, u"
"$mod, Down, movefocus, d"
"Alt, Tab, movefocus, d"
"$mod, 1, workspace, 1"
"$mod, 2, workspace, 2"
"$mod, 3, workspace, 3"
"$mod, 4, workspace, 4"
"$mod, 5, workspace, 5"
"$mod, 6, workspace, 6"
"$mod, 7, workspace, 7"
"$mod, 8, workspace, 8"
"$mod, 9, workspace, 9"
"$mod, 0, workspace, 10"
"$mod+Ctrl, Right, workspace, r+1"
"$mod+Ctrl, Left, workspace, r-1"
"$mod+Ctrl, Doown, workspace, empty"
"$mod+Shift, 1, movetoworkspace, 1"
"$mod+Shift, 2, movetoworkspace, 2"
"$mod+Shift, 3, movetoworkspace, 3"
"$mod+Shift, 4, movetoworkspace, 4"
"$mod+Shift, 5, movetoworkspace, 5"
"$mod+Shift, 6, movetoworkspace, 6"
"$mod+Shift, 7, movetoworkspace, 7"
"$mod+Shift, 8, movetoworkspace, 8"
"$mod+Shift, 9, movetoworkspace, 9"
"$mod+Shift, 0, movetoworkspace, 10"
"$mod+Ctrl+Alt, Right, movetoworkspace, r+1"
"$mod+Ctrl+Alt, Left, movetoworkspace, r-1"
#"$mod, Backspace, exec, wlogout -b 4 -T 600 -B 600"
"$mod, Backspace, exec, caelestia shell drawers toggle session"
"$mod+Shift+Ctrl, Left, movewindow, l"
"$mod+Shift+Ctrl, Right, movewindow, r"
"$mod+Shift+Ctrl, Up, movewindow, u"
"$mod+Shift+Ctrl, Down, movewindow, d"
"$mod, mouse_down, workspace, e+1"
"$mod, mouse_up, workspace, e-1"
"$mod, V, exec, cliphist list | rofi -dmenu| cliphist decode | wl-copy" # copy paste
"$mod, B, exec, hyprkeys -bkr | rofi -dmenu"
#"$mod, A, tagwindow, noborder" # used to not apply image border
"$mod, S, togglespecialworkspace,"
"Alt+$mod, S, movetoworkspace, special"
# for the scrolling layout
"$mod, A, layoutmsg, move -col"
"$mod, D, layoutmsg, move +col"
#apps keybindings
"$mod, T, exec, $term"
"$mod, E, exec, $file"
"$mod, F, exec, $browser"
"$mod, N, exec, $notes"
#"$mod+Shift, A, exec, rofi -show drun"
"$mod+Shift, A, exec, caelestia shell drawers toggle launcher"
"$mod, Q, exec, custom-dontkillsteam"
#"Ctrl+Alt, W, exec, pkill waybar || waybar"
"Ctrl+Alt, W, exec, caelestia shell drawers toggle sidebar"
#"$mod, L, exec, swaylock -eFLK -i ${wallpaper}"
"$mod, L, exec, caelestia shell lock lock"
#"$mod, F11, exec, hyprshot -m window"
", F11, exec, caelestia screenshot"
#"$mod_SHIFT, S, exec, hyprshot -m region --clipboard only"
# "$mod_SHIFT, S, exec, qs ipc call screenshot toggle"
"$mod_SHIFT, S, exec, caelestia shell picker open"
# framework 16 rgb macropad
"Ctrl+$mod, 6, exec, custom-killall" # pos 1 1 killall apps except focused one
#"Ctrl+Alt, 7, exec, custom-performance" # pos 2 1 start performance mode
"Ctrl+Alt, 7, exec, caelestia shell gameMode toggle"
# reloads the autostart programs # pos 3 1
# we passed to caelestia-shell and stoped using that
/*
"Ctrl+$mod, 4, exec, sleep 1 && kitty -o font_size=16 -e sh -c 'custom-weather'"
"Ctrl+$mod, 4, exec, sleep 1 && kitty -o font_size=11 -e sh -c 'custom-cowsay'"
"Ctrl+$mod, 4, exec, kitty -e 'custom-launch'"
"Ctrl+$mod, 4, exec, sleep 1 && kitty -o font_size=5 -e btm --theme gruvbox --disable-click --disable_advanced_kill --enable_cache_memory -g -R -T "
"Ctrl+$mod, 4, exec, sleep 1 && kitty -o font_size=1 -e sh -c 'cmatrix -br'"
#"Ctrl+Alt, 1, exec, swaync-client -t" # pos 4 1 notification center
"Ctrl+Alt, 1, exec, qs ipc call notifications toggle"
*/
"Ctrl+Alt, 1, exec, caelestia shell drawers toggle sidebar"
"Ctrl+$mod, 4, exec, caelestia shell notifs toggleDnd"
"Ctrl+$mod, 3, exec, pavucontrol" # pos 1 2 audiocontrol
"Ctrl+Shift+Alt, 0, exec, kitty --hold --class \"custom-changeAudioOutput\" --name \"Select audio output\" zsh -c \"custom-changeAudioOutput\"" # pos 2 2 change audio output fzf
"Ctrl+$mod, 5, exec, gnome-characters" # pos 3 2 special chars
"Ctrl+Alt, 8, exec, hyprpicker | tee >(wl-copy) | cliphist store" # pos 4 2 colorpicker
"Ctrl+Alt, 0, exec, custom-tomato" # pos 1 3 pomodoro app
"Ctrl+Alt, 2, exec, custom-bottom" # pos 2 3 btm (like htop but cleaner)
"Ctrl+Alt, 9, exec, anki"
# if hyprexpo plugin enabled bind = $mainMod, Space, hyprexpo:expo, toggle
# maybe exec sudo framework-tools-tui
#plugins keybindings
#"$mod, SPACE, overview:toggle, "
];
binde = [
"$mod+Shift, Right, resizeactive, 30 0"
"$mod+Shift, Left, resizeactive, -30, 0"
"$mod+Shift, Up, resizeactive, 0 -30"
"$mod+Shift, Down, resizeactive,m 0 30"
];
bindl = [
", F1, exec, pactl set-sink-mute @DEFAULT_SINK@ toggle" #toggle audio mute
", F5, exec, playerctl play-pause" # media F4-F6
", F4, exec, playerctl previous"
", F6, exec, playerctl next"
];
bindel = [
", F2, exec, pactl set-sink-volume @DEFAULT_SINK@ -10%" # decrease volume
", F3, exec, pactl set-sink-volume @DEFAULT_SINK@ +10%" # increase volume
", F7, exec, brightnessctl s 10%-" # decrease brightness
", F8, exec, brightnessctl s +10%" # increase brightness
];
bindm = [
"$mod, mouse:272, movewindow"
"$mod, mouse:273, resizewindow"
"$mod, Z, movewindow"
"$mod, X, resizewindow"
];
# █░░ ▄▀█ █░█ █▄░█ █▀▀ █░█
# █▄▄ █▀█ █▄█ █░▀█ █▄▄ █▀█
exec-once = [
"dbus-update-activation-environment --systemd WAYLAND_DISPLAY XDG_CURRENT_DESKTOP" # for XDPH
"dbus-update-activation-environment --systemd --all" # for XDPH
"systemctl --user import-environment WAYLAND_DISPLAY XDG_CURRENT_DESKTOP" # for XDPH
"systemctl --user start xdg-desktop-portal-wlr.service"
"blueman-applet" # systray app for Bluetooth
"udiskie --no-automount --smart-tray" # front-end that allows to manage removable media
"nm-applet --indicator" # systray app for Network/wifi
#setups clipboard
"rm -rf ~/.cache/cliphist/ && wl-paste --type text --watch cliphist store & wl-paste --type image --watch cliphist store"
#"wl-paste --type text --watch cliphist store" # clipboard store text data
#"wl-paste --type image --watch cliphist store" # clipboard store image data
"custom-batterynotify"
"custom-batterywarning"
#"birdtray" # thunderbird tray app # curently broken
#wallpapers/b
"swww img ${wallpaper}"
"swww-daemon"
"sleep 1 && custom-wallpaper"
"custom-checkKdrive && custom-mountkdrive" # checks if the remote works and mount it
#"waybar"
"custom-gitnotify"
"custom-checkMatrix" # checks if matrix-commander-rs is connected which is important for other stuff
#"custom-obsidianbackup" # backups the obsidian notes to kdrive and to a timed hidden dir (~/.Notes.backup/)
#"QS-notifycache" # builds the cache that will be used for the notification history
"sleep 4 & caelestia-shell" #works better if it sleeps a bit before
/*
We stopped using that ######################### maybe we should desactivate those scripts
# login autostart
#######################
"[workspace 1 silent] sleep 1 && kitty -o font_size=16 -e sh -c 'custom-weather'"
"[workspace 1 silent] sleep 1 && kitty -o font_size=11 -e sh -c 'custom-cowsay'"
"[workspace 1 silent] kitty -e 'custom-launch'"
"[workspace 1 silent] sleep 1 && kitty -o font_size=5 -e btm --theme gruvbox --disable-click --disable_advanced_kill --enable_cache_memory -g -R -T "
"[workspace 1 silent] sleep 1 && kitty -o font_size=1 -e sh -c 'cmatrix -br'"
######################
######################
*/
];
splash = true; # remove default background on startup
# gestures (also keybindings)
gesture = [
"3, right, move, +col"
"3, left, move, -col"
];
# █░░ ▄▀█ █▄█ █▀█ █░█ ▀█▀ █▀
# █▄▄ █▀█ ░█░ █▄█ █▄█ ░█░ ▄█
dwindle = {
preserve_split = true;
};
scrolling = {
column_width = 0.45;
};
# █▀▄▀█ █ █▀ █▀▀
# █░▀░█ █ ▄█ █▄▄
misc = {
vrr = 0;
force_default_wallpaper = 0;
};
xwayland = {
force_zero_scaling = true;
};
# █▀▄▀█ █▀█ █▄░█ █ ▀█▀ █▀█ █▀█
# █░▀░█ █▄█ █#░▀█ █ ░█░ █▄█ █▀▄
monitor = [
#",preferred, auto, auto"
"HDMI-A-1, highres2highrr, auto-left, 1"
];
# _______ ___ __ __ _______ ___ __ _ _______
#| || | | | | || || | | | | || |
#| _ || | | | | || ___|| | | |_| || _____|
#| |_| || | | |_| || | __ | | | || |_____
#| ___|| |___ | || || || | | _ ||_____ |
#| | | || || |_| || | | | | | _____| |
#|___| |_______||_______||_______||___| |_| |__||_______|
#
"plugin:dynamic-cursors" = {
enabled = true;
threshold = 2;
mode = "rotate";
rotate = {
# length in px of the simulated stick used to rotate the cursor
# most realistic if this is your actual cursor size
length = 20;
offset = 0;
};
shake = {
enabled = true;
# use nearest-neighbour (pixelated) scaling when shaking
# may look weird when effects are enabled
nearest = true;
threshold = 4;
# magnification level immediately after shake start
base = 4.0;
# magnification increase per second when continuing to shake
speed = 4.0;
# how much the speed is influenced by the current shake intensitiy
influence = 0.0;
# maximal magnification the cursor can reach
# values below 1 disable the limit (e.g. 0)
limit = 0.0;
# time in millseconds the cursor will stay magnified after a shake has ended
timeout = 2000;
# show cursor behaviour `tilt`, `rotate`, etc. while shaking
effects = true;
# enable ipc events for shake
ipc = false;
};
};
"plugin:overview" = {
disableGestures = true;
showEmptyWorkspace = true;
workspaceActiveBorder = "rgb(ab7746)";
disableBlur = true;
};
#####################################################
#####################################################
# theme
decoration = {
dim_special = 0.3;
rounding = 18;
blur = {
special = true;
enabled = true;
size = 4;
passes = 2;
new_optimizations = true;
ignore_opacity = true;
};
};
general = {
gaps_in = 5;
gaps_out = 15;
border_size = 4;
"col.active_border" = "rgba(ca6702ff) rgba(ecd3a0ff) 45deg";
"col.inactive_border" = "rgba(f1dca7d9) rgba(ffe1a8d9) 45deg";
layout = "dwindle";
resize_on_border = true;
};
group = {
"col.border_active" = "rgba(ca6702ff) rgba(ecd3a0ff) 45deg";
"col.border_inactive" = "rgba(f1dca7d9) rgba(ffe1a8d9) 45deg";
"col.border_locked_active" = "rgba(ca6702ff) rgba(ecd3a0ff) 45deg";
"col.border_locked_inactive" = "rgba(f1dca7d9) rgba(ffe1a8d9) 45deg";
};
####################################################
##################################################
# /$$ /$$ /$$
#| $$ /$ | $$ | $$
#| $$ /$$$| $$ /$$$$$$ /$$$$$$ | $$ /$$ /$$$$$$$ /$$$$$$ /$$$$$$ /$$$$$$$ /$$$$$$
#| $$/$$ $$ $$ /$$__ $$ /$$__ $$| $$ /$$/ /$$_____/ /$$__ $$ |____ $$ /$$_____/ /$$__ $$
#| $$$$_ $$$$| $$ \ $$| $$ \__/| $$$$$$/ | $$$$$$ | $$ \ $$ /$$$$$$$| $$ | $$$$$$$$
#| $$$/ \ $$$| $$ | $$| $$ | $$_ $$ \____ $$| $$ | $$ /$$__ $$| $$ | $$_____/
#| $$/ \ $$| $$$$$$/| $$ | $$ \ $$ /$$$$$$$/| $$$$$$$/| $$$$$$$| $$$$$$$| $$$$$$$
#|__/ \__/ \______/ |__/ |__/ \__/|_______/ | $$____/ \_______/ \_______/ \_______/
# | $$
# | $$
# |__/
# see https://wiki.hypr.land/Configuring/Workspace-Rules/
workspace = [
"1, layout:master"
"2, layout:scrolling, layoutopt:direction:right"
"name:special, layout:scrolling"
# used for smart gaps along some windowrules
#"w[tv1], gapsout:1, gapsin:1"
#"f[1], gapsout:1, gapsin:1"
];
# █░█░█ █ █▄░█ █▀▄ █▀█ █░█░█   █▀█ █░█ █░░ █▀▀ █▀
# ▀▄▀▄▀ █ █░▀█ █▄▀ █▄█ ▀▄▀▄▀   █▀▄ █▄█ █▄▄ ██▄ ▄█
windowrule = [
"opacity 0.90 0.90, match:class ^(firefox)$"
"opacity 0.90 0.90, match:class ^(Brave-browser)$"
"opacity 0.80 0.80, match:class ^(code-oss)$"
"opacity 0.80 0.80, match:class ^(Code)$"
"opacity 0.80 0.80, match:class ^(code-url-handler)$"
"opacity 0.80 0.80, match:class ^(code-insiders-url-handler)$"
"opacity 0.75 0.75, match:class ^(kitty)$"
"opacity 0.80 0.80, match:class ^(org.kde.dolphin)$"
"opacity 0.80 0.80, float on, match:class ^(org.kde.ark)$"
"opacity 0.80 0.80, float on, match:class ^(nwg-look)$"
"opacity 0.80 0.80, float on, match:class ^(qt5ct)$"
"opacity 0.80 0.80, float on, match:class ^(qt6ct)$"
"opacity 0.80 0.80, float on, match:class ^(kvantummanager)$"
"opacity 0.80 0.70, float on, match:class ^(org.pulseaudio.pavucontrol)$"
"opacity 0.80 0.70, float on, match:class ^(blueman-manager)$"
"opacity 0.80 0.70, float on, match:class ^(nm-applet)$"
"opacity 0.80 0.70, float on, match:class ^(nm-connection-editor)$"
"opacity 0.80 0.70, float on, match:class ^(org.kde.polkit-kde-authentication-agent-1)$"
"opacity 0.80 0.70, match:class ^(polkit-gnome-authentication-agent-1)$"
"opacity 0.80 0.70, match:class ^(org.freedesktop.impl.portal.desktop.gtk)$"
"opacity 0.80 0.70, match:class ^(org.freedesktop.impl.portal.desktop.hyprland)$"
"opacity 0.70 0.70, match:class ^([Ss]team)$"
"opacity 0.70 0.70, match:class ^(steamwebhelper)$"
"opacity 0.70 0.70, match:class ^(Spotify)$"
"opacity 0.70 0.70, match:initial_title ^(Spotify Free)$"
"opacity 0.90 0.90, float on, match:class ^(com.github.rafostar.Clapper)$"
"opacity 0.80 0.80, match:class ^(com.github.tchx84.Flatseal)$"
"opacity 0.80 0.80, match:class ^(hu.kramo.Cartridges)$"
"opacity 0.80 0.80, match:class ^(com.obsproject.Studio)$"
"opacity 0.80 0.80, match:class ^(gnome-boxes)$"
"opacity 0.80 0.80, match:class ^(discord)$"
"opacity 0.80 0.80, match:class ^(WebCord)$"
"opacity 0.80 0.80, match:class ^(ArmCord)$"
"opacity 0.80 0.80, float on, match:class ^(app.drey.Warp)$"
"opacity 0.80 0.80, float on, match:class ^(net.davidotek.pupgui2)$"
"opacity 0.80 0.80, float on, match:class ^(yad)$"
"opacity 0.80 0.80, float on, match:class ^(Signal)$"
"opacity 0.80 0.80, float on, match:class ^(io.github.alainm23.planify)$"
"opacity 0.80 0.80, float on, match:class ^(io.gitlab.theevilskeleton.Upscaler)$"
"opacity 0.80 0.80, float on, match:class ^(com.github.unrud.VideoDownloader)$"
"opacity 0.80 0.80, float on, match:class ^(io.gitlab.adhami3310.Impression)$"
"opacity 0.80 0.80, float on, match:class ^(io.missioncenter.MissionCenter)$"
"opacity 0.80 0.80, match:class ^(io.github.flattool.Warehouse)$"
"float on, match:class ^(org.kde.dolphin)$, match:title ^(Progress Dialog Dolphin)$"
"float on, match:class ^(org.kde.dolphin)$, match:title ^(Copying Dolphin)$"
"float on, match:class ^(firefox)$, match:title ^(Picture-in-Picture)$"
"float on, match:class ^(firefox)$, match:title ^(Library)$"
"float on, match:class ^(kitty)$, match:title ^(top)$"
"float on, match:class ^(kitty)$, match:title ^(btop)$"
"float on, match:class ^(kitty)$, match:title ^(htop)$"
"float on, match:class ^(vlc)$"
"float on, match:class ^(eog)$"
"float on, size 400 225, match:class ^(custom-librewolfprofiles)$"
"float on, size 1050 200, match:class ^(custom-changeAudioOutput)$"
"float on, size 400 175, match:class ^(custom-obsidianvaults)$"
"float on, size 600 600, match:initial_class ^(custom-pomodoro)$"
"float on, size 1500 800, match:initial_class ^(custom-bottom)$"
# smart gaps/border is ugly with caelestia-shell
#"border_size 2, match:float 0, match:workspace w[tv1]"
#"rounding 1, match:float 0, match:workspace w[tv1]"
#"border_size 2, match:float 0, match:workspace f[1]"
#"rounding 1, match:float 0, match:workspace f[1]"
];
# add a float for tomato when in kitty
#"plugin:imgborders:noimgborders, tag:noborder"
layerrule = [
"blur on, ignore_alpha 0, match:namespace rofi"
"blur on, ignore_alpha 0, match:namespace notifications"
"blur on, ignore_alpha 0, match:namespace swaync-notification-window"
"blur on, ignore_alpha 0, match:namespace swaync-control-center"
"blur on, match:namespace logout_dialog"
];
};
}
-121
View File
@@ -1,121 +0,0 @@
_: {
programs.kitty = {
enable = true;
#font.name = nerd-fonts._0xproto;
#font.size = "10";
## new config (matches with caelestia
## old condfig
extraConfig = ''
font_size 14
bold_font auto
italic_font auto
bold_italic_font auto
window_padding_width 25
# --- Core ---
foreground #ece0d9
background #18120e
selection_foreground #18120e
selection_background #ece0d9
cursor #ffb878
cursor_text_color #18120e
# --- Tabs ---
active_tab_foreground #18120e
active_tab_background #5c412a
inactive_tab_foreground #d6c3b5
inactive_tab_background #241e1a
# --- Black / Gray ---
color0 #353433
color8 #b29f91
# --- Red ---
color1 #e17300
color9 #ff8a20
# --- Green ---
color2 #ffc071
color10 #ffd6a8
# --- Yellow ---
color3 #ffe0c6
color11 #fff2e8
# --- Blue ---
color4 #b9ab66
color12 #d7be91
# --- Magenta ---
color5 #ed9562
color13 #fcad7e
# --- Cyan ---
color6 #f4c16d
color14 #ffd497
# --- White ---
color7 #ebd4c1
color15 #FFFFFF
'';
/*
extraConfig = ''
# font nerd-fonts._0xproto # this key dont work and causes errors
font_size 14
bold_font auto
italic_font auto
bold_italic_font auto
window_padding_width 25
foreground #FFFFFF
background #1B1D1C
selection_foreground #1B1D1C
selection_background #FFFFFF
cursor #C3AC76
cursor_text_color #0F1010
active_tab_foreground #1B1D1C
active_tab_background #6B5540
inactive_tab_foreground #6B5540
inactive_tab_background #1B1D1C
# black
color0 #29523D
color8 #578F73
# red
#color1 #FFF0CC
#color9 #F0DBAA
# we need actual red colors
color1 #CC241D
color9 #9D0006
# green
color2 #FFEECC
color10 #F0D9AA
# yellow
color3 #FFE5CC
color11 #F0CCAA
# blue
color4 #9AE6C0
color12 #9AE6C0
# magenta
color5 #E6CC9A
color13 #E6CC9A
# cyan
color6 #E6BF9A
color14 #E6BF9A
# white
color7 #FFF0CC
color15 #F0DBAA
'';
*/
};
}
-638
View File
@@ -1,638 +0,0 @@
# adapted from https://github.com/contre95/dotfiles/blob/main/dotfiles/nixos/programs/librewolf.nix
_: {
home.sessionVariables = {
MOZ_ENABLE_WAYLAND = 1;
MOZ_USE_XINPUT2 = 1;
MOZ_DBUS_REMOTE = 1;
};
programs.librewolf = {
enable = true;
settings = {
"browser.profiles.enabled" = true;
# disabled until i find something that uses it.
"webgl.disabled" = true;
# settings = lib.mapAttrs' (n: lib.nameValuePair "pref.${n}") {
"app.update.auto" = true; # disable auto update
#"dom.security.https_only_mode" = true; # force https
"extensions.pocket.enabled" = false; # disable pocket
#"browser.quitShortcut.disabled" = true; # disable ctrl+q
"browser.download.panel.shown" = true; # show download panel
"signon.rememberSignons" = false; # disable saving passwords
"identity.fxaccounts.enabled" = false; # disable librewolf accounts
"app.shield.optoutstudies.enabled" = false; # disable shield studies
"browser.shell.checkDefaultBrowser" = false; # don't check if default browser
#"browser.bookmarks.restore_default_bookmarks" = false; # don't restore default bookmarks
# Download handling
#"browser.download.dir" = "/home/meain/down"; # default download dir
"browser.startup.page" = 3; # restore previous session
# UI changes
# "browser.uidensity" = 1; # enable dense UI
#"general.autoScroll" = true; # enable autoscroll
# "browser.compactmode.show" = true; # enable compact mode
# "browser.tabs.firefox-view" = false; # enable librewolf view
#"startup.homepage_welcome_url" =
# "https://metrics.internal.contre.io/d/cUITC74Vksd/podman-revamped?orgId=1&from=2026-02-23T19:29:26.304Z&to=2026-02-23T19:59:26.304Z&timezone=browser&var-Filters=&var-namespace=alloy&var-level=error&var-level=debug&var-level=info&var-level=warn&refresh=5s&kiosk=true"; # disable welcome page
"browser.newtabpage.enabled" = true; # disable new tab page
"full-screen-api.ignore-widgets" = true; # fullscreen within window
"browser.toolbars.bookmarks.visibility" = "newtab"; # hide bookmarks toolbar; always, never, newtab
"browser.aboutConfig.showWarning" = false; # disable warning about about:config
"media.videocontrols.picture-in-picture.video-toggle.enabled" = false; # disable picture in picture button
# Privacy
"privacy.resistFingerprinting" = true;
# "privacy.clearOnShutdown.cache" = false;
"privacy.clearOnShutdown.history" = false;
"privacy.clearHistory.cookiesAndStorage" = false;
"privacy.clearHistory.historyFormDataAndDownloads" = false;
"privacy.clearHistory.cache" = false;
"privacy.clearOnShutdown_v2.siteSettings" = false;
"privacy.clearOnShutdown_v2.cookiesAndStorage" = false;
"services.sync.prefs.sync.privacy.clearOnShutdown_v2.history" = false;
"services.sync.prefs.sync.privacy.clearOnShutdown_v2.siteSettings" = false;
"services.sync.prefs.sync.privacy.clearOnShutdown_v2.sessions" = false;
"services.sync.prefs.sync.privacy.clearOnShutdown_v2.cookies" = false;
"services.sync.prefs.sync.privacy.clearOnShutdown.history" = false;
"services.sync.prefs.sync.privacy.clearOnShutdown.siteSettings" = false;
"services.sync.prefs.sync.privacy.clearOnShutdown.sessions" = false;
"services.sync.prefs.sync.privacy.clearOnShutdown.cookies" = false;
"privacy.clearOnShutdown.cookies" = false;
"browser.discovery.enabled" = false; # disable discovery
"browser.search.suggest.enabled" = true; # disable search suggestions
"browser.contentblocking.category" = "standart"; # set tracking protection to standart to not interfer with adnauseam
"dom.private-attribution.submission.enabled" = false; # stop doing dumb stuff mozilla
"browser.protections_panel.infoMessage.seen" = true; # disable tracking protection info
# Theme
"toolkit.legacyUserProfileCustomizations.stylesheets" = true;
"svg.context-properties.content.enabled" = true;
"layout.css.color-mix.enabled" = true;
# Disable telemetry
"toolkit.telemetry.enabled" = false;
"toolkit.telemetry.unified" = false;
"browser.ping-centre.telemetry" = false;
"toolkit.telemetry.archive.enabled" = false;
"toolkit.telemetry.bhrPing.enabled" = false;
"toolkit.telemetry.updatePing.enabled" = false;
"browser.translations.automaticallyPopup" = false;
"toolkit.telemetry.hybridContent.enabled" = false;
"toolkit.telemetry.newProfilePing.enabled" = false;
"toolkit.telemetry.reportingpolicy.firstRun" = false;
"toolkit.telemetry.firstShutdownPing.enabled" = false;
"browser.newtabpage.activity-stream.telemetry" = false;
"toolkit.telemetry.shutdownPingSender.enabled" = false;
"browser.newtabpage.activity-stream.feeds.telemetry" = false;
"browser.tabs.loadInBackground" = true; # open new tab in background
"browser.tabs.loadBookmarksInTabs" = true; # open bookmarks in new tab
"browser.tabs.warnOnOpen" = false; # don't warn when opening multiple tabs
"browser.tabs.warnOnQuit" = false; # don't warn when closing multiple tabs
"browser.tabs.warnOnClose" = false; # don't warn when closing multiple tabs
"browser.tabs.loadDivertedInBackground" = false; # open new tab in background
"browser.tabs.warnOnCloseOtherTabs" = false; # don't warn when closing multiple tabs
"browser.tabs.closeWindowWithLastTab" = false; # don't close window when last tab is closed
# other
"media.autoplay.default" = 0; # enable autoplay on open
"devtools.toolbox.host" = "right"; # move devtools to right
"devtools.theme" = "dark";
# "browser.ssb.enabled" = true; # enable site specific browser
"media.rdd-vpx.enabled" = true; # enable hardware acceleration
"devtools.cache.disabled" = true; # disable caching in devtools
"media.ffmpeg.vaapi.enabled" = true; # enable hardware acceleration
# Fonts
"font.size.fixed.x-western" = 15;
"font.minimum-size.x-western" = 13;
"font.size.variable.x-western" = 15;
"font.size.monospace.x-western" = 15;
"browser.display.use_document_fonts" = 1;
"browser.link.open_newwindow.restriction" = 0;
#
# "browser.fixup.domainsuffixwhitelist.home" = true;
# "browser.fixup.domainwhitelist.internal.contre.io" = true;
"extensions.activeThemeID" = "firefox-compact-dark@mozilla.org";
# "keyword.enable" = false; # Disable search when typing unexistent TLD
};
policies = {
ExtensionSettings = {
# the extension id should be from the manifesto and not a random name.
# if you dont know it. Put a random name. It will fail. Go to about:polices#error and the error will give you the correct id.
"enhancerforyoutube@maximerf.addons.mozilla.org" = {
installation_mode = "normal_installed";
install_url = "https://addons.mozilla.org/firefox/downloads/latest/enhancer-for-youtube/latest.xpi";
};
"sponsorBlocker@ajay.app" = {
install_url = "https://addons.mozilla.org/firefox/downloads/latest/sponsorblock/latest.xpi";
installation_mode = "force_installed";
};
"adnauseam@rednoise.org" = {
install_url = "https://addons.mozilla.org/firefox/downloads/latest/adnauseam/latest.xpi";
installation_mode = "force_installed";
};
"uBlock0@raymondhill.net" = {
install_url = "https://addons.mozilla.org/firefox/downloads/latest/ublock-origin/latest.xpi";
installation_mode = "force_installed";
};
"{08d5243b-4236-4a27-984b-1ded22ce01c3}" = {
install_url = "https://addons.mozilla.org/firefox/downloads/file/3729287/gruvboxgruvboxgruvboxgruvboxgr-1.0.xpi";
installation_mode = "force_installed";
};
"trackmenot@mrl.nyu.edu" = {
install_url = "https://addons.mozilla.org/firefox/downloads/latest/trackmenot/latest.xpi";
installation_mode = "force_installed";
};
"{446900e4-71c2-419f-a6a7-df9c091e268b}" = {
install_url = "https://addons.mozilla.org/firefox/downloads/file/4749958/bitwarden_password_manager-latest.xpi";
installation_mode = "force_installed";
};
};
DisableTelemetry = true;
DisableFirefoxStudies = true;
EnableTrackingProtection = {
Value = true;
Locked = true;
Cryptomining = true;
Fingerprinting = true;
};
DisablePocket = true;
DisableAccounts = true;
DisableFirefoxScreenshots = true;
# OverrideFirstRunPage = "";
# OverridePostUpdatePage = "";
DontCheckDefaultBrowser = true;
DisplayBookmarksToolbar = "always"; # alternatives: "always" or "newtab"
DisplayMenuBar = "never"; # alternatives: "always", "never" or "default-on"
SearchBar = "unified"; # alternative: "separate"
};
profiles.work = {
id = 0;
# userChrome = builtins.readFile ./userChrome.css;
# userContent = builtins.readFile ./userChrome.css;
extensions = {
#force = true;
#settings = {
# "adnauseam@rednoise.org".settings = {
# # Core behavior
# filteringEnabled = true;
#
# hidingAds = true;
# blockingMalware = true;
# clickingAds = true;
#
# # Privacy
# disableClickingForDNT = true;
# blockSocialMediaWidgets = false;
#
# # Filter lists
# selectedFilterLists = [
# "adnauseam-filters"
# "easylist"
# "easyprivacy"
# "ublock-badware"
# "ublock-privacy"
# "ublock-unbreak"
# ];
#
# # Advanced
# advancedUserEnabled = false;
# dynamicFilteringEnabled = false;
#
# # UI
# showIconBadge = true;
# parseTextAds = true;
# eventLogging = false;
# };
# "trackmenot@mrl.nyu.edu".settings = {
# enabled = true;
# # Query behavior
# runAtStartup = true;
# useTab = false; # don't open visible tab
# showQueries = false; # don't display fake queries
# # Frequency (seconds between bursts)
# timeout = 600; # 10 minutes
# burstEnabled = true;
# burstTimeout = 20; # burst interval
# burstCount = 5;
# # Query source
# useRssFeeds = true; # use dynamic trending feeds
# useUserQueries = false; # don't mix your real queries
# useBlackList = true;
# # Search engines to generate noise for
# searchEngines = {
# google = true;
# bing = false;
# yahoo = false;
# baidu = false;
# duckduckgo = false;
# };
# # Logging
# enableLogging = false;
# };
# "sponsorBlocker@ajay.app".settings = {
# # Core behavior
# isEnabled = true;
# autoSkip = false;
# showSkipNotice = true;
# # this does not work
# # Segment categories (auto-skip behavior)
# categoryChooser = {
# Sponsor = {
# enabled = true;
# skipOption = "manualSkip";
# };
# intro = {
# enabled = true;
# actionType = 2;
# };
# outro = {
# enabled = true;
# actionType = 2;
# };
# selfpromo = {
# enabled = true;
# actionType = 2;
# };
# interaction = {
# enabled = true;
# actionType = 1; # 1 = manual skip
# };
# music_offtopic = {
# enabled = false;
# actionType = 0;
# };
# preview = {
# enabled = false;
# actionType = 0;
# };
# };
# # Privacy
# disableTelemetry = true;
# showDonationLink = false;
# # UX
# showUpsells = false;
# hideSkipButtonPlayerControls = false;
# # Advanced
# useLocalCache = true;
# trackViewCount = false;
# };
#};
};
bookmarks = {
force = true;
settings = [
{
name = "Nixos Config";
tags = ["github"];
keyword = "github";
url = "https://github.com/tomasriveral/nixos";
}
{
name = "Public AI";
tags = ["ai" "chatgpt" "apertus"];
keyword = "apertus";
url = "https://chat.publicai.co/";
}
{
name = "Signs of AI writing";
tags = ["ai" "write"];
keyword = "AI writing";
url = "https://en.wikipedia.org/wiki/Wikipedia:Signs_of_AI_writing";
}
{
name = "nixpkgs-review-gha";
tags = ["nixpkgs-review" "gha"];
keyword = "nixpkgs-review";
url = "https://github.com/tomasriveral/nixpkgs-review-gha/actions/workflows/review.yml";
}
{
name = "nixpkgs tracker";
tags = ["nixpkgs" "tracker"];
keyword = "nixpkgs tracker";
url = "https://nixpk.gs/pr-tracker.html";
}
{
name = "fahrlehrer";
tags = ["theorie" "fahrlehrer" "conduite"];
keyword = "fahrlehrer24";
url = "https://app.fahrlehrer24.ch/";
}
{
name = "cogito";
tags = ["cogito" "esprit" "critique"];
keyword = "Cogito l'Esprit critique";
url = "https://app.cogito.fr";
}
];
};
search = {
force = true;
default = "quant";
privateDefault = "qant";
order = [
"q"
"map"
"np"
"nw"
"bookmarks"
"tabs"
"history"
];
engines = {
# don't need these default ones
"amazondotcom-es".metaData.hidden = true;
"bing".metaData.hidden = true;
"ebay".metaData.hidden = true;
"metager".metaData.hidden = true; # dont work
"mojeek".metaData.hidden = true; # dont work
"seerx".metaData.hidden = true;
"perplexity".metaData.hidden = true;
"google".metaData.hidden = true;
"startpage".metaData.hidden = true;
"duckduckgo".metaData.hidden = true;
"Wikitionary" = {
urls = [
{
template = "https://fr.wiktionary.org/w/index.php?search={searchTerms}";
}
];
definedAliases = ["dict"];
};
"quant" = {
urls = [
{
template = "https://www.qwant.com/";
params = [
{
name = "q";
value = "{searchTerms}";
}
];
}
];
definedAliases = ["q"];
};
"OpenStreeetMap" = {
urls = [
{
template = "https://www.openstreetmap";
params = [
{
name = "q";
value = "{searchTerms}";
}
];
}
];
definedAliases = ["map"];
};
"Home Manager Options" = {
urls = [
{
template = "https://home-manager-options.extranix.com/";
params = [
{
name = "query";
value = "{searchTerms}";
}
];
}
];
definedAliases = ["hm"];
};
"Nix Packages" = {
urls = [
{
template = "https://search.nixos.org/packages";
params = [
{
name = "type";
value = "packages";
}
{
name = "query";
value = "{searchTerms}";
}
];
}
];
definedAliases = ["np"];
};
"Nix Wiki" = {
urls = [
{
template = "https://wiki.nixos.org/w/index.php?search={searchTerms}";
}
];
definedAliases = ["nw"];
};
"Repology" = {
urls = [
{
template = "https://repology.org/projects/?search={searchTerms}";
}
];
definedAliases = ["rp"];
};
};
};
};
profiles.other = {
id = 1;
# userChrome = builtins.readFile ./userChrome.css;
# userContent = builtins.readFile ./userChrome.css;
extensions = {
#force = false;
#settings = {
# "adnauseam@rednoise.org".settings = {
# # Core behavior
# filteringEnabled = true;
#
# hidingAds = true;
# blockingMalware = true;
# clickingAds = true;
#
# # Privacy
# disableClickingForDNT = true;
# blockSocialMediaWidgets = false;
#
# # Filter lists
# selectedFilterLists = [
# "adnauseam-filters"
# "easylist"
# "easyprivacy"
# "ublock-badware"
# "ublock-privacy"
# "ublock-unbreak"
# ];
#
# # Advanced
# advancedUserEnabled = false;
# dynamicFilteringEnabled = false;
#
# # UI
# showIconBadge = true;
# parseTextAds = true;
# eventLogging = false;
# };
# "trackmenot@mrl.nyu.edu".settings = {
# enabled = true;
# # Query behavior
# runAtStartup = true;
# useTab = false; # don't open visible tab
# showQueries = false; # don't display fake queries
# # Frequency (seconds between bursts)
# timeout = 600; # 10 minutes
# burstEnabled = true;
# burstTimeout = 20; # burst interval
# burstCount = 5;
# # Query source
# useRssFeeds = true; # use dynamic trending feeds
# useUserQueries = false; # don't mix your real queries
# useBlackList = true;
# # Search engines to generate noise for
# searchEngines = {
# google = true;
# bing = false;
# yahoo = false;
# baidu = false;
# duckduckgo = false;
# };
# # Logging
# enableLogging = false;
# };
# "sponsorBlocker@ajay.app".settings = {
# # Core behavior
# isEnabled = true;
# autoSkip = false;
# showSkipNotice = true;
# # this does not work
# # Segment categories (auto-skip behavior)
# categoryChooser = {
# Sponsor = {
# enabled = true;
# skipOption = "manualSkip";
# };
# intro = {
# enabled = true;
# actionType = 2;
# };
# outro = {
# enabled = true;
# actionType = 2;
# };
# selfpromo = {
# enabled = true;
# actionType = 2;
# };
# interaction = {
# enabled = true;
# actionType = 1; # 1 = manual skip
# };
# music_offtopic = {
# enabled = false;
# actionType = 0;
# };
# preview = {
# enabled = false;
# actionType = 0;
# };
# };
# # Privacy
# disableTelemetry = true;
# showDonationLink = false;
# # UX
# showUpsells = false;
# hideSkipButtonPlayerControls = false;
# # Advanced
# useLocalCache = true;
# trackViewCount = false;
# };
#};
};
search = {
force = true;
default = "quant";
privateDefault = "qant";
order = [
"q"
"map"
"np"
"nw"
"bookmarks"
"tabs"
"history"
];
engines = {
# don't need these default ones
"amazondotcom-es".metaData.hidden = true;
"bing".metaData.hidden = true;
"ebay".metaData.hidden = true;
"metager".metaData.hidden = true; # dont work
"mojeek".metaData.hidden = true; # dont work
"seerx".metaData.hidden = true;
"perplexity".metaData.hidden = true;
"google".metaData.hidden = true;
"startpage".metaData.hidden = true;
"duckduckgo".metaData.hidden = true;
"quant" = {
urls = [
{
template = "https://www.qwant.com/";
params = [
{
name = "q";
value = "{searchTerms}";
}
];
}
];
definedAliases = ["q"];
};
"OpenStreeetMap" = {
urls = [
{
template = "https://www.openstreetmap";
params = [
{
name = "q";
value = "{searchTerms}";
}
];
}
];
definedAliases = ["map"];
};
"Onche.org" = {
urls = [
{
template = "https://onche.org/forum/1/blabla-general/search?by=topic&q={searchTerms}";
}
];
definedAliases = ["on"];
};
};
};
};
};
}
-44
View File
@@ -1,44 +0,0 @@
{
pkgs-unstable,
inputs,
...
}: {
programs.micro = {
enable = true;
package = pkgs-unstable.micro-full;
settings = {
};
};
home.file.".config/micro/plug/vivify" = {
enable = true;
source = inputs.microPlugins-vivify;
recursive = true;
force = true;
};
home.file.".config/micro/init.lua" = {
enable = true;
force = true;
text = ''
local buffer = import("micro/buffer")
local shell = import("micro/shell")
function vivifyOpen(buf)
local cursor = buf:GetActiveCursor()
local line = cursor.Loc.Y + 1
shell.ExecCommand("viv", string.format("%s:%d", buf.AbsPath, line))
end
function onBufferOpen(buf)
if os.getenv("MICRO_VIVIFY") ~= "1" then
return
end
-- only run for real files (not help/log/etc)
if buf.Type.Kind == buffer.BTDefault then
vivifyOpen(buf)
end
end
'';
};
}
-8
View File
@@ -1,8 +0,0 @@
# see also ../nixos/mullvad.nix
{pkgs-unstable, ...}: {
programs.mullvad-vpn = {
# gui
enable = true;
package = pkgs-unstable.mullvad-vpn;
};
}
-499
View File
@@ -1,499 +0,0 @@
{pkgs-unstable, ...}: {
programs.neovim = {
enable = true;
vimAlias = false;
viAlias = false;
package = pkgs-unstable.neovim-unwrapped; # required for unwrapped version
plugins = [
pkgs-unstable.vimPlugins.vivify-vim
pkgs-unstable.vimPlugins.vimtex
pkgs-unstable.vimPlugins.zoxide-vim
#pkgs-unstable.vimPlugins.gruvbox
pkgs-unstable.vimPlugins.gruvbox-nvim
pkgs-unstable.vimPlugins.neovim-sensible
pkgs-unstable.vimPlugins.nvim-web-devicons
pkgs-unstable.vimPlugins.nvim-tree-lua
pkgs-unstable.vimPlugins.nvim-surround
pkgs-unstable.vimPlugins.floaterm
pkgs-unstable.vimPlugins.nvim-lspconfig
pkgs-unstable.vimPlugins.cmp-nvim-lsp
pkgs-unstable.vimPlugins.cmp-nvim-lsp-signature-help
pkgs-unstable.vimPlugins.cmp-under-comparator
pkgs-unstable.vimPlugins.cmp-buffer
pkgs-unstable.vimPlugins.cmp-path
pkgs-unstable.vimPlugins.cmp-cmdline
pkgs-unstable.vimPlugins.nvim-cmp
pkgs-unstable.vimPlugins.cmp-vsnip
pkgs-unstable.vimPlugins.vim-vsnip
pkgs-unstable.vimPlugins.dashboard-nvim
pkgs-unstable.vimPlugins.lualine-nvim
pkgs-unstable.vimPlugins.vim-nix
pkgs-unstable.vimPlugins.plenary-nvim
pkgs-unstable.vimPlugins.blink-ripgrep-nvim
pkgs-unstable.vimPlugins.nvim-treesitter
pkgs-unstable.vimPlugins.nvim-treesitter-parsers.rasi
pkgs-unstable.vimPlugins.nvim-treesitter-parsers.regex
pkgs-unstable.vimPlugins.nvim-treesitter-parsers.udev
pkgs-unstable.vimPlugins.nvim-treesitter-parsers.zsh
pkgs-unstable.vimPlugins.nvim-treesitter-parsers.c
pkgs-unstable.vimPlugins.nvim-treesitter-parsers.bibtex
pkgs-unstable.vimPlugins.nvim-treesitter-parsers.bash
pkgs-unstable.vimPlugins.nvim-treesitter-parsers.gitignore
pkgs-unstable.vimPlugins.nvim-treesitter-parsers.comment
pkgs-unstable.vimPlugins.nvim-treesitter-parsers.json
pkgs-unstable.vimPlugins.nvim-treesitter-parsers.hyprlang
pkgs-unstable.vimPlugins.nvim-treesitter-parsers.lua
pkgs-unstable.vimPlugins.nvim-treesitter-parsers.latex
pkgs-unstable.vimPlugins.nvim-treesitter-parsers.kitty
pkgs-unstable.vimPlugins.nvim-treesitter-parsers.markdown
pkgs-unstable.vimPlugins.nvim-treesitter-parsers.nix
pkgs-unstable.vimPlugins.nvim-treesitter-parsers.printf
pkgs-unstable.vimPlugins.nvim-treesitter-parsers.python
pkgs-unstable.vimPlugins.telescope-nvim
pkgs-unstable.vimPlugins.nvim-scrollbar
pkgs-unstable.vimPlugins.promise-async
pkgs-unstable.vimPlugins.nvim-ufo
pkgs-unstable.vimPlugins.cheatsheet-nvim
pkgs-unstable.vimPlugins.popup-nvim
pkgs-unstable.vimPlugins.vim-visual-multi
pkgs-unstable.vimPlugins.fugit2-nvim
pkgs-unstable.vimPlugins.nvim-lastplace
pkgs-unstable.vimPlugins.runner-nvim # terminal
pkgs-unstable.vimPlugins.better-diagnostic-virtual-text
pkgs-unstable.vimPlugins.garbage-day-nvim
];
extraLuaConfig = ''
local vim = vim
-- =========================
-- LEADER & KEY DISABLE
-- =========================
vim.g.mapleader = ' '
vim.g.maplocalleader = ' '
vim.keymap.set({'n', 'v'}, '<Space>', '<Nop>', { desc = 'Leader key, disable default behavior' })
vim.keymap.set('n', 'q', '<Nop>', { desc = 'Disable macro recording' })
vim.keymap.set('n', 'gg', '<Nop>', { desc = 'Disable g motion' })
vim.keymap.set('n', 'gG', '<Nop>', { desc = 'Disable g motion' })
vim.keymap.set('n', 'g0', '<Nop>', { desc = 'Disable g motion' })
vim.keymap.set('n', 'g^', '<Nop>', { desc = 'Disable g motion' })
vim.keymap.set('n', 'g$', '<Nop>', { desc = 'Disable g motion' })
vim.keymap.set('n', 'gj', '<Nop>', { desc = 'Disable g motion' })
vim.keymap.set('n', 'gk', '<Nop>', { desc = 'Disable g motion' })
vim.keymap.set('n', 'g~', '<Nop>', { desc = 'Disable g motion' })
vim.keymap.set('n', 'gu', '<Nop>', { desc = 'Disable g motion' })
vim.keymap.set('n', 'gU', '<Nop>', { desc = 'Disable g motion' })
vim.keymap.set('n', 'g=', '<Nop>', { desc = 'Disable g motion' })
vim.keymap.set('n', 'gq', '<Nop>', { desc = 'Disable g motion' })
vim.keymap.set('n', 'g@', '<Nop>', { desc = 'Disable g motion' })
vim.keymap.set('n', 'g?', '<Nop>', { desc = 'Disable g motion' })
vim.keymap.set('n', 'gC', '<Nop>', { desc = 'Disable g motion' })
vim.keymap.set('n', 'gD', '<Nop>', { desc = 'Disable g motion' })
vim.keymap.set('n', 'gx', '<Nop>', { desc = 'Disable g motion' })
vim.keymap.set('n', 'gr', '<Nop>', { desc = 'Disable g motion' })
vim.keymap.set('n', 'g[', '<Nop>', { desc = 'Disable g motion' })
vim.keymap.set('n', 'g]', '<Nop>', { desc = 'Disable g motion' })
vim.keymap.set('n', 'g;', '<Nop>', { desc = 'Disable g motion' })
vim.keymap.set('n', 'g,', '<Nop>', { desc = 'Disable g motion' })
-- =========================
-- GENERAL OPTIONS
-- =========================
vim.g.have_nerd_font = true
vim.opt.relativenumber = false
vim.opt.number = true
vim.opt.mouse = 'a'
vim.opt.showmode = false
vim.schedule(function()
vim.opt.clipboard = 'unnamedplus'
end)
vim.opt.breakindent = true
vim.opt.undofile = true
vim.opt.ignorecase = true
vim.opt.smartcase = true
vim.opt.signcolumn = 'yes'
vim.opt.updatetime = 250
vim.opt.timeoutlen = 300
vim.opt.splitright = true
vim.opt.splitbelow = true
vim.opt.list = true
vim.opt.listchars = { tab = '» ', trail = '·', nbsp = '' }
vim.opt.expandtab = true
vim.opt.smartindent = true
vim.opt.tabstop = 4
vim.opt.shiftwidth = 4
vim.opt.inccommand = 'split'
vim.opt.cursorline = true
vim.opt.scrolloff = 10
-- =========================
-- BASIC KEYMAPS
-- =========================
vim.keymap.set('n', '<Esc>', '<cmd>nohlsearch<CR>')
vim.keymap.set('t', '<Esc><Esc>', '<C-\\><C-n>', { desc = 'Exit terminal mode' })
-- Disable arrow keys in normal mode
vim.keymap.set('n', '<left>', '<cmd>echo "Use h to move!!"<CR>')
vim.keymap.set('n', '<right>', '<cmd>echo "Use l to move!!"<CR>')
vim.keymap.set('n', '<up>', '<cmd>echo "Use k to move!!"<CR>')
vim.keymap.set('n', '<down>', '<cmd>echo "Use j to move!!"<CR>')
-- Window navigation
vim.keymap.set('n', '<C-Left>', '<C-w><C-h>', { desc = 'Move focus to the left window' })
vim.keymap.set('n', '<C-Right>', '<C-w><C-l>', { desc = 'Move focus to the right window' })
vim.keymap.set('n', '<C-Down>', '<C-w><C-j>', { desc = 'Move focus to the lower window' })
vim.keymap.set('n', '<C-Up>', '<C-w><C-k>', { desc = 'Move focus to the upper window' })
-- Cheatsheet
vim.keymap.set("n","§", "<cmd>Cheatsheet<CR>")
require("cheatsheet").setup({
bundled_cheatsheets = { enabled = { "default" } },
bundled_plugin_cheatsheets = { disabled = { "gitsigns.nvim" } }
})
-- Highlight yanked text
vim.api.nvim_create_autocmd('TextYankPost', {
desc = 'Highlight on yank',
group = vim.api.nvim_create_augroup('kickstart-highlight-yank', { clear = true }),
callback = function() vim.highlight.on_yank() end,
})
-- ========================
-- terminal
-- =======================
require("runner-nvim").setup({
position = 'right', -- position of the terminal window when using the shell_handler
-- can be: top, left, right, bottom
-- will be overwritten when using the telescope mapping to open horizontally or vertically
width = 80, -- width of window when position is left or right
height = 10, -- height of window when position is top or bottom
handlers = {
lua = function(bufnr)
vim.print('Running lua file in buffer ' .. bufnr)
-- Run the file here
end
}
})
vim.keymap.set("n", "<leader><leader>", function() require("runner-nvim").run() end)
-- =========================
-- SCROLLBAR
-- =========================
require("scrollbar").setup()
-- =========================
-- UFO FOLDING
-- =========================
vim.o.foldcolumn = '1'
vim.o.foldlevel = 99
vim.o.foldlevelstart = 99
vim.o.foldenable = true
vim.keymap.set('n', '<leader>1', "<cmd>foldopen<CR>")
vim.keymap.set('n', '<leader>2', "<cmd>foldclose<CR>")
require('ufo').setup({
provider_selector = function() return {'treesitter', 'indent'} end
})
-- =========================
-- treesitter
-- ========================
require('nvim-treesitter').setup({
ensure_installed = {},
highlight = {
enable = true,
additional_vim_regex_highlighting = false,
},
indent = { enable = true },
})
-- =========================
-- NVIM-TREE
-- =========================
vim.g.loaded_netrw = 1
vim.g.loaded_netrwPlugin = 1
require("nvim-tree").setup({
sort = { sorter = "case_sensitive" },
view = { width = 30 },
renderer = { group_empty = true },
filters = { dotfiles = true },
})
-- =========================
-- CMP CONFIGURATION
-- =========================
local cmp = require'cmp'
cmp.setup({
snippet = { expand = function(args) vim.fn["vsnip#anonymous"](args.body) end },
mapping = cmp.mapping.preset.insert({
['<C-b>'] = cmp.mapping.scroll_docs(-4),
['<C-f>'] = cmp.mapping.scroll_docs(4),
['<C-Space>'] = cmp.mapping.complete(),
['<C-e>'] = cmp.mapping.abort(),
['<CR>'] = cmp.mapping.confirm({ select = true }),
}),
sources = cmp.config.sources({ { name = 'nvim_lsp' }, { name = 'vsnip' } }, { { name = 'buffer' } }),
})
cmp.setup.cmdline({ '/', '?' }, { mapping = cmp.mapping.preset.cmdline(), sources = { { name = 'buffer' } } })
cmp.setup.cmdline(':', { mapping = cmp.mapping.preset.cmdline(), sources = cmp.config.sources({ { name = 'path' } }, { { name = 'cmdline' } }), matching = { disallow_symbol_nonprefix_matching = false } })
-- =========================
-- LSP CONFIGURATION
-- =========================
local capabilities = require('cmp_nvim_lsp').default_capabilities()
-- Diagnostics
vim.keymap.set("n", "<leader>e4", function() vim.diagnostic.jump({ prev=true, count = 1 }) end, { desc = "Previous diagnostic" })
vim.keymap.set("n", "<leader>e5", function() vim.diagnostic.jump({ prev=false, count = 1 }) end, { desc = "Next diagnostic" })
vim.keymap.set("n", "<leader>e1", vim.diagnostic.open_float, { desc = "Show diagnostic" })
vim.keymap.set("n", "<leader>e3", vim.diagnostic.setloclist, { desc = "Diagnostic list" })
vim.keymap.set("n", "<leader>e2", vim.lsp.buf.code_action, { desc = "Show correction" })
vim.keymap.set("n", "<leader>e<Tab>", function()
local clients = vim.lsp.get_clients({ name = "ltex" })
if #clients > 0 then
-- Stop LTeX
for _, client in ipairs(clients) do
client.stop()
end
print("LTeX OFF")
else
-- Start LTeX
vim.cmd("LspStart ltex")
print("LTeX ON")
end
end, { desc = "Toggle LTeX" })
vim.diagnostic.config({
update_in_insert = false, -- i don't get any new error when in insert
})
require("better-diagnostic-virtual-text").setup({
ui = {
wrap_line_after = false, -- wrap the line after this length to avoid the virtual text is too long
left_kept_space = 3, --- the number of spaces kept on the left side of the virtual text, make sure it enough to custom for each line
right_kept_space = 3, --- the number of spaces kept on the right side of the virtual text, make sure it enough to custom for each line
arrow = " ",
up_arrow = " ",
down_arrow = " ",
above = false, -- the virtual text will be displayed above the line
},
priority = 2003, -- the priority of virtual text
inline = false,
})
-- LSP functionality
vim.keymap.set("n", "<leader>g1", vim.lsp.buf.hover, { desc = "Hover documentation" })
vim.keymap.set("n", "<leader>g2", vim.lsp.buf.definition, { desc = "Go to definition" })
vim.keymap.set("n", "<leader>g3", vim.lsp.buf.declaration, { desc = "Go to declaration" })
vim.keymap.set("n", "<leader>g4", vim.lsp.buf.implementation, { desc = "Go to implementation" })
vim.keymap.set("n", "<leader>g5", vim.lsp.buf.references, { desc = "Show references" })
-- LSP server setup
vim.lsp.config("lua_ls", { cmd = { "lua-language-server" }, filetypes = { "lua" }, root_dir = vim.fs.dirname, on_attach = on_attach })
vim.lsp.config("clangd", {
cmd = { "clangd", "--header-insertion=never" },
filetypes = { "c","cpp","objc","objcpp" },
on_attach = on_attach ,
init_options = {
clangdFileStatus = true,
usePlaceholders = true,
completeUnimported = false, -- this adds a bunch of #include even thought they are #included in another header file
headerInsertion = false,
headerInsertionDecorators = false,
addDependencyHeaders = false,
semanticHighlighting = true}
})
vim.lsp.config("nixd", {
cmd = { "nixd" },
filetypes = { "nix" },
on_attach = on_attach,
})
vim.lsp.config("pylsp", {
cmd = { "pylsp" },
filetypes = { "python" },
on_attach = on_attach,
settings = {
pylsp = {
plugins = {
pylsp_mypy = { enabled = true },
jedi_completion = { fuzzy = true }
}
}
}
})
vim.lsp.config("texlab", { cmd = { "texlab" }, filetypes = { "tex" }, on_attach = on_attach })
vim.lsp.config("ltex", {
cmd = { "ltex-ls-plus" },
filetypes = { "markdown", "text", "tex", "plaintex" },
on_attach = on_attach,
settings = {
ltex = {
language = "fr",
enabled = {
"markdown",
"text",
"tex",
"plaintex",
},
completionEnabled = true,
diagnosticSeverity = "information",
additionalRules = {
enablePickyRules = false,
motherTongue = "fr",
},
dictionary = {
["fr"] = {
"icelle",
"icelui",
"iceux",
"maldoror",
"evariste",
"galois",
"arno",
"dessacrer",
},
},
},
},
})
vim.lsp.enable({ "lua_ls", "clangd", "pylsp", "texlab", "nixd", "ltex"})
-- =========================
-- DASHBOARD
-- =========================
require('dashboard').setup {
theme = 'hyper',
config = {
header = {
" ... ... . ",
" .=*8888n..\"%888: @88> ",
" X ?8888f '8888 u. ... .. %8P .. . : ",
" 88x. '8888X 8888> .u ...ue888b :~\"\"888h.:^\"888: . .888: x888 x888. ",
"'8888k 8888X '\"*8h. ud8888. 888R Y888r 8X `8888X 8888> .@88u ~`8888~'888X`?888f` ",
" \"8888 X888X .xH8 :888'8888. 888R I888> X888n. 8888X ?888> '\"888E` X888 888X '888> ",
" `8\" X888!:888X d888 '88%\" 888R I888> '88888 8888X ?**h. 888E X888 888X '888> ",
" =~` X888 X888X 8888.+\" 888R I888> `*88 8888~ x88x. 888E X888 888X '888> ",
" :h. X8*` !888X 8888L u8888cJ888 ..<\" 88*` 88888X 888E X888 888X '888> ",
" X888xX\" '8888..: '8888c. .+ \"*888*P\" ..XC. `*8888k 888& \"*88%\"\"*88\" '888!` ",
":~`888f '*888*\" \"88888% 'Y\" :888888H. `%88> R888\" `~ \" `\"` ",
" \"\" `\"` \"YP' < `\"888888: X\" \"\" ",
" %888888x.-` ",
" \"\"**\"\" ",
"",
""
},
shortcut = { { desc = " Open File Tree", group = "", key = 't', action = 'NvimTreeOpen' } },
packages = { enable = false },
project = { enable = true, limit = 8, icon = ' New file', action = 'Telescope find_files cwd=' },
mru = { limit = 10, icon = ' History' },
footer = {},
}
}
-- jumps cursor when was last cursor last time
require("nvim-lastplace").setup({
-- Filetypes to ignore
ignore_filetypes = {
"gitcommit", "gitrebase", "svn", "hgcommit", "xxd", "COMMIT_EDITMSG"
},
-- Buffer types to ignore
ignore_buftypes = {
"quickfix", "nofile", "help", "terminal"
},
-- Center cursor after jumping
center_on_jump = true,
-- Only jump if target line is not visible
jump_only_if_not_visible = false,
-- Minimum lines required to enable jumping
min_lines = 10,
-- Maximum line to jump to (0 = no limit)
max_line = 0,
-- Open folds after jumping
open_folds = true,
-- Enable debug messages
debug = false,
})
-- ======================
-- gruvbox
-- ======================
require("gruvbox").setup({
terminal_colors = false, -- add neovim terminal colors
undercurl = true,
underline = true,
bold = true,
italic = {
strings = false,
emphasis = true,
comments = true,
operators = false,
folds = true,
},
strikethrough = true,
invert_selection = false,
invert_signs = false,
invert_tabline = false,
inverse = true, -- invert background for search, diffs, statuslines and errors
contrast = "hard", -- can be "hard", "soft" or empty string
palette_overrides = { -- for overrides see https://github.com/ellisonleao/gruvbox.nvim/blob/main/lua/gruvbox.lua
dark0_hard = "#241F17"
},
overrides = {
String = {fg = "#FFB878", italic = false},
FoldColumn = {fg = faded_orange, bg = dark0_hard}
},
dim_inactive = false,
transparent_mode = false,
})
vim.opt.termguicolors = false
vim.o.background = "dark"
vim.cmd("colorscheme gruvbox")
-- =========================
-- LUALINE
-- =========================
require('lualine').setup { options = { theme = "gruvbox_dark" } }
--==================0
-- Some utils
--==================
vim.keymap.set('n', '<leader>r1', '<cmd>Fugit2<CR>', { desc = 'Open git helper' })
vim.keymap.set("n", "t", function()
local line = vim.api.nvim_get_current_line()
local result = vim.fn.system({ "custom-syllabes" }, line)
print(vim.trim(result))
end, { desc = "Count syllables (current line)" })
-- =========================
-- telescope
-- =======================
local builtin = require('telescope.builtin')
vim.keymap.set('n', '<leader>f1', builtin.find_files, { desc = 'Telescope find files' })
vim.keymap.set('n', '<leader>f2', builtin.live_grep, { desc = 'Telescope live grep' })
vim.keymap.set('n', '<leader>f3', builtin.buffers, { desc = 'Telescope buffers' })
vim.keymap.set('n', '<leader>f4', builtin.help_tags, { desc = 'Telescope help tags' })
-- Disable relative numbers even if plugins override
vim.api.nvim_create_autocmd("VimEnter", { callback = function() vim.opt.colorcolumn = ""; vim.opt.relativenumber = false end })
'';
};
}
-26
View File
@@ -1,26 +0,0 @@
_: {
programs.obsidian = {
enable = true;
vaults = {
miscellanious = {
enable = true;
target = "/Documents/Notes/miscellanious";
};
work = {
enable = true;
target = "/Documents/Notes/work";
};
};
defaultSettings = {
appearance.theme = "gruvbox";
extraFiles = {
".obsidian/themes/gruvbox/manifest.json" = ../../other/obsidian-theme/manifest.json;
".obsidian/themes/gruvbox/obsidian.css" = ../../other/obsidian-theme/obsidian.css;
".obsidian/themes/gruvbox/theme.css" = ../../other/obsidian-theme/theme.css;
};
};
};
}
-7
View File
@@ -1,7 +0,0 @@
_: {
programs.oh-my-posh = {
enable = true;
enableZshIntegration = true;
useTheme = "gruvbox";
};
}
-19
View File
@@ -1,19 +0,0 @@
_: {
programs.zsh.oh-my-zsh = {
enable = true;
theme = "jonathan";
plugins = [
"aliases"
"alias-finder"
"colored-man-pages"
"colorize"
"command-not-found"
"dirhistory"
"fzf"
"git"
"rclone"
"safe-paste"
"sudo"
];
};
}
@@ -1,30 +0,0 @@
_:
# see ../../docs/printing.md
{
home.file.".local/share/applications/org.quickshell.desktop" = {
enable = true;
text = ''
[Desktop Entry]
Name=QuickShell
Comment=QuickShell application
Exec=quickshell
Icon=utilities-terminal
Type=Application
Categories=Utility;
StartupNotify=true
X-DBUS-ServiceName=org.quickshell
'';
};
home.file.".local/share/applications/org.kde.PrintQueue.desktop" = {
enable = true;
text = ''
[Desktop Entry]
Type=Application
Name=Print Queue
Exec=print-queue
Icon=printer
Categories=Utility;
StartupNotify=true
'';
};
}
-9
View File
@@ -1,9 +0,0 @@
_: {
home.username = "tomasr";
home.homeDirectory = "/home/tomasr";
home.sessionVariables = {
EDITOR = "neovim";
TERMINAL = "kitty";
};
}
-12
View File
@@ -1,12 +0,0 @@
# pulled from https://codeberg.org/zacoons/rivendell-hyprdots
_: {
qt.enable = true;
programs.quickshell = {
systemd.enable = true;
enable = true;
};
home.file.".config/quickshell" = {
source = ../../other/quickshell;
recursive = true;
};
}
-6
View File
@@ -1,6 +0,0 @@
{pkgs-unstable, ...}: {
programs.rclone = {
enable = true;
package = pkgs-unstable.rclone;
};
}
-14
View File
@@ -1,14 +0,0 @@
_: {
programs.ripgrep = {
enable = true;
arguments = [
"-S"
"-."
"-p"
"-n"
];
};
programs.ripgrep-all = {
enable = true;
};
}
-6
View File
@@ -1,6 +0,0 @@
_: {
programs.rofi = {
enable = true;
theme = "gruvbox-dark-hard";
};
}
-29
View File
@@ -1,29 +0,0 @@
_: {
home.packages = [
#pkgs-unstable.sbb-tui
];
home.file.".config/sbb-tui/config.yaml" = {
enable = true;
# Gruvbox (from https://github.com/Necrom4/sbb-tui/blob/master/docs/themes.md)
text = ''
ui:
nerdfont: true
theme:
text: "#EBDBB2"
textMuted: "#928374"
error: "#FB4934"
warning: "#FB4934"
borderFocused: "#FABD2F"
borderUnfocused: "#504945"
badgeKeyFg: "#282828"
badgeKeyBg: "#FABD2F"
badgeVehicleFg: "#EBDBB2"
badgeVehicleBg: "#458588"
badgeModelFg: "#282828"
badgeModelBg: "#FB4934"
badgeCompanyFg: "#282828"
badgeCompanyBg: "#EBDBB2"
logo: "#EBDBB2"
'';
};
}
-25
View File
@@ -1,25 +0,0 @@
_: {
programs.ssh = {
enable = true;
enableDefaultConfig = false; # will be removed in the futur. Removes evaluation warning
matchBlocks."*" = {
# equivalent to the default config
forwardAgent = false;
addKeysToAgent = "no";
compression = false;
serverAliveInterval = 0;
serverAliveCountMax = 3;
hashKnownHosts = false;
userKnownHostsFile = "~/.ssh/known_hosts";
controlMaster = "no";
controlPath = "~/.ssh/master-%r@%n:%p";
controlPersist = "no";
};
};
services.ssh-agent.enable = true;
home.file.".ssh/config".text = ''
Host *
AddKeysToAgent yes
IdentityFile ~/.ssh/id_ed25519
'';
}
-36
View File
@@ -1,36 +0,0 @@
_: {
programs.swaylock = {
enable = true;
settings = {
color = "1e1e2e";
bs-hl-color = "f5e0dc";
caps-lock-bs-hl-color = "f5e0dc";
caps-lock-key-hl-color = "a6e3a1";
inside-color = "00000000";
inside-clear-color = "00000000";
inside-caps-lock-color = "00000000";
inside-ver-color = "00000000";
inside-wrong-color = "00000000";
key-hl-color = "a6e3a1";
layout-bg-color = "00000000";
layout-border-color = "00000000";
layout-text-color = "cdd6f4";
line-color = "00000000";
line-clear-color = "00000000";
line-caps-lock-color = "00000000";
line-ver-color = "00000000";
line-wrong-color = "00000000";
ring-color = "b4befe";
ring-clear-color = "f5e0dc";
ring-caps-lock-color = "fab387";
ring-ver-color = "89b4fa";
ring-wrong-color = "eba0ac";
separator-color = "00000000";
text-color = "cdd6f4";
text-clear-color = "f5e0dc";
text-caps-lock-color = "fab387";
text-ver-color = "89b4fa";
text-wrong-color = "eba0ac";
};
};
}
-5
View File
@@ -1,5 +0,0 @@
_: {
services.swaync = {
enable = true;
};
}
-8
View File
@@ -1,8 +0,0 @@
_: {
programs.thunderbird = {
enable = true;
profiles.tomasr = {
isDefault = true;
};
};
}
-26
View File
@@ -1,26 +0,0 @@
{pkgs-unstable, ...}: {
home.file.".config/vivify/config.json" = {
enable = true;
text = ''
{
"browserOptions": {
"name": "qutebrowser",
"arguments": ["-T"]
}
}'';
};
home.packages = [
pkgs-unstable.vivify
];
programs.qutebrowser = {
enable = true;
settings = {
auto_save.session = false;
changelog_after_upgrade = "never";
content.cookies.accept = "never";
};
extraConfig = ''
config.bind('<Ctrl-L>', 'yank url ;; message-info "URL copied"')
'';
};
}
-693
View File
@@ -1,693 +0,0 @@
_: {
programs.waybar = {
enable = true;
settings = [
{
layer = "top";
position = "left";
margin = "5 2 5 0";
reload_style_on_change = true;
modules-left = [
"hyprland/workspaces"
"group/info"
"group/power"
];
modules-center = [
];
modules-right = [
"hyprland/window"
"group/brightness"
"group/sound"
"group/connection"
"group/together"
"tray"
"battery"
];
# groups settings are organized by alphabetical order
"group/audio" = {
orientation = "inherit";
drawer = {
transition-duration = 500;
transition-left-to-right = false;
};
modules = [
"pulseaudio"
"pulseaudio#mic"
"pulseaudio/slider"
];
};
"group/bluetooth" = {
orientation = "inherit";
drawer = {
transition-duration = 500;
transition-left-to-right = true;
};
modules = [
"bluetooth"
"bluetooth#status"
];
};
"group/brightness" = {
orientation = "inherit";
drawer = {
transition-duration = 500;
transition-left-to-right = false;
};
modules = [
"backlight"
"backlight/slider"
];
};
"group/connection" = {
orientation = "inherit";
modules = ["group/network"];
};
"group/gcpu" = {
orientation = "inherit";
modules = [
"custom/cpu-icon"
"temperature"
"cpu"
];
};
"group/info" = {
orientation = "inherit";
modules = [
"group/gcpu"
"memory"
"disk"
];
};
"group/network" = {
orientation = "inherit";
drawer = {
transition-duration = 500;
transition-left-to-right = true;
};
modules = [
"network"
"network#speed"
];
};
"group/power" = {
orientation = "inherit";
modules = [
"battery#w"
"battery#powerdraw"
];
};
"group/sound" = {
orientation = "inherit";
modules = [
"group/audio"
"custom/notification"
];
};
"group/together" = {
orientation = "inherit";
modules = [
"group/utils"
"clock"
];
};
"group/utils" = {
orientation = "inherit";
drawer = {
transition-duration = 500;
transition-left-to-right = true;
};
modules = [
"custom/weather"
"custom/colorpicker"
];
};
# modules settings are organized by alphabetical order
backlight = {
device = "intel_backlight"; # my laptop is amd and it works
format = "{icon}";
format-icons = [
""
""
""
""
""
""
""
""
""
""
""
""
""
""
""
];
on-scroll-down = "brightnessctl s 5%-";
on-scroll-up = "brightness s +5%";
tooltip = true;
tooltip-format = "Brightness: {percent}%";
smooth-scrolling-threshold = 1;
};
"backlight/slider" = {
min = 5;
max = 100;
orientation = "vertical";
device = "intel_backlight";
};
battery = {
#rotate = 90;
interval = 30;
states = {
good = 95;
warning = 20;
critical = 15;
};
format = "{icon} {capacity}";
format-charging = "<b>{icon} {capacity}% </b>";
format-full = "<span color='#82A55F'><b>{icon}</b></span>";
format-icons = [
"󰁻"
"󰁼"
"󰁾"
"󰂀"
"󰂂"
"󰁹"
];
tooltip-format = "{timeTo} {capacity} %";
};
"battery#powerdraw" = {
rotate = 90;
interval = 10;
format = "{power:.0001f}";
};
"battery#w" = {
rotate = 90;
interval = 100000;
format = "W";
};
bluetooth = {
format-on = "";
format-off = "󰂲";
format-disabled = "";
format-connected = "<b></b>";
tooltip-format = "{controller_alias}\t{controller_address}\n\n{num_connections} connected";
tooltip-format-connected = "{controller_alias}\t{controller_address}\n\n{num_connections} connected\n\n{device_enumerate}";
tooltip-format-enumerate-connected = "{device_alias}\t{device_address}";
tooltip-format-enumerate-connected-battery = "{device_alias}\t{device_address}\t{device_battery_percentage}%";
};
"bluetooth#status" = {
format-on = "";
format-off = "";
format-disabled = "";
format-connected = "<b>{num_connections}</b>";
format-connected-battery = "<small><b>{device_battery_percentage}%</b></small>";
tooltip-format = "{controller_alias}\t{controller_address}\n\n{num_connections} connected";
tooltip-format-connected = "{controller_alias}\t{controller_address}\n\n{num_connections} connected\n\n{device_enumerate}";
tooltip-format-enumerate-connected = "{device_alias}\t{device_address}";
tooltip-format-enumerate-connected-battery = "{device_alias}\t{device_address}\t{device_battery_percentage}%";
};
clock = {
format = "{:%H\n%M}";
tooltip-format = "<tt><small>{calendar}</small></tt>";
calendar = {
mode = "month";
mode-mon-col = 3;
weeks-pos = "right";
on-scroll = 1;
on-click-right = "mode";
format = {
today = "<span color='#d65d0e'><b><u>{}</u></b></span>";
};
};
};
cpu = {
format = "<b>{usage}%</b>";
};
"custom/colorpicker" = {
format = "";
on-click = "hyprpicker | tee >(wl-copy) | cliphist store";
};
"custom/cpu-icon" = {
format = "󰻠";
tooltip = false;
};
"custom/mark" = {
format = "";
tooltip = false;
};
"custom/weather" = {
format = "{}";
interval = 3600;
exec = "custom-weatherwaybar";
return-type = "json";
};
disk = {
interval = 600;
format = "<b> 󰋊 \n{percentage_used}󱉸</b>";
path = "/"; #maybe we should subtract ~/kdrive if it is counted
};
"hyprland/window" = {
format = "{class}";
rotate = 90;
};
"hyprland/workspaces" = {
format = "{icon}";
format-icons = {
"1" = "";
"2" = "";
"3" = "";
"4" = "";
"5" = "";
"6" = "";
"7" = "";
"8" = "";
"9" = "";
"10" = "";
"active" = "";
"default" = "";
};
persistent-workspaces = {
"*" = [1 2 3 4 5 6 7 8 9 10];
};
};
idle_inhibitor = {
format = "{icon}";
tooltip-format-activated = "Idle Inhibitor is active";
tooltip-format-deactivated = "Idle Inhibitor is not active";
format-icons = {
activated = "󰔡";
deactivated = "󰔢";
};
};
memory = {
format = "<b> \n{:2}󱉸</b>";
};
network = {
format = "{icon}";
format-icons = {
wifi = ["󰤨"];
ethernet = ["󰈀"];
disconnected = ["󰖪"];
};
format-wifi = "󰤨";
format-ethernet = "󰈀";
format-disconnected = "󰖪";
format-linked = "󰈁";
tooltip = false;
};
"network#speed" = {
format = " {bandwidthDownBits} ";
rotate = 90;
interval = 5;
tooltip-format = "{ipaddr}";
tooltip-format-wifi = "{essid} ({signalStrength}%) \n{ipaddr} | {frequency} MHz{icon} ";
tooltip-format-ethernet = "{ifname} 󰈀 \n{ipaddr} | {frequency} MHz{icon} ";
tooltip-format-disconnected = "Not Connected to any type of Network";
tooltip = true;
};
power-profiles-daemon = {
format = "{icon}";
tooltip-format = "Power profile: {profile}\nDriver: {driver}";
tooltip = true;
format-icons = {
default = "";
performance = "<span color='#B37F34'><small></small></span>";
balanced = "<span><small> </small></span>";
power-saver = "<span color='#a6e3a1'><small></small></span>";
};
};
pulseaudio = {
format = "{icon}";
format-bluetooth = "{icon}";
tooltip-format = "{volume}% {icon} | {desc}";
format-muted = "󰖁";
format-icons = {
headphones = "󰋌";
handsfree = "󰋌";
headset = "󰋌";
phone = "";
portable = "";
car = " ";
default = [
"󰕿"
"󰖀"
"󰕾"
];
};
on-click = "volume mute";
on-click-middle = "pavucontrol";
on-scroll-up = "pactl set-sink-volume @DEFAULT_SINK@ +5%";
on-scroll-down = "pactl set-sink-volume @DEFAULT_SINK@ -5%";
smooth-scrolling-threshold = 1;
};
"pulseaudio#mic" = {
format = "{format_source}";
format-source = "";
format-source-muted = "";
tooltip-format = "{volume}% {format_source}";
on-click = "pactl set-source-mute 0 toggle";
on-scroll-down = "pactl set-source-volume 0 -1%";
on-scroll-up = "pactl set-source-volume 0 +1%";
};
"pulseaudio/slider" = {
min = 0;
max = 140;
orientation = "vertical";
};
temperature = {
format = "{temperatureC}°C";
format-critical = "{temperatureC}°C";
interval = 10;
};
tray = {
icon-size = 18;
spacing = 10;
};
}
]; # home-manager wants the whole config as a list of bars
style = ''
@define-color foreground #c5c5c5;
@define-color background #191919;
@define-color cursor #c5c5c5;
@define-color color0 #191919;
@define-color color1 #3a3632;
@define-color color2 #582c1e;
@define-color color3 #423f39;
@define-color color4 #50473c;
@define-color color5 #634723;
@define-color color6 #BAA470;
@define-color color7 #8c8c8c;
@define-color color8 #525252;
@define-color color9 #4e4843;
@define-color color10 #763b28;
@define-color color11 #59554c;
@define-color color12 #6b5f51;
@define-color color13 #855f2f;
@define-color color14 #796d62;
@define-color color15 #c5c5c5;
@define-color active @color6;
* {
font-size: 23px;
font-family: "0xProto Nerd Font";
min-width: 8px;
min-height: 0px;
border: none;
border-radius: 0;
box-shadow: none;
text-shadow: none;
padding: 0px;
margin: 0px;
}
window#waybar {
transition-property: background-color;
transition-duration: 0.5s;
border-radius: 8px;
border: 2px solid @active;
background: @background;
background: alpha(@background, 0.7);
color: lighter(@active);
}
menu,
tooltip {
border-radius: 8px;
padding: 2px;
border: 1px solid lighter(@active);
background: alpha(@background, 0.6);
color: lighter(@active);
}
menu label,
tooltip label {
font-size: 20px;
color: lighter(@active);
}
#submap,
#tray>.needs-attention {
animation-name: blink-active;
animation-duration: 1s;
animation-timing-function: linear;
animation-iteration-count: infinite;
animation-direction: alternate;
}
.modules-right {
margin: 0px 6px 6px 6px;
border-radius: 4px;
background: alpha(@background, 0.4);
color: lighter(@active);
}
.modules-left {
transition-property: background-color;
transition-duration: 0.5s;
margin: 6px 6px 6px 6px;
border-radius: 4px;
background: alpha(@background, 0.4);
color: lighter(@active);
}
#gcpu,
#custom-github,
#memory,
#disk,
#together,
#submap,
#custom-weather {
font-size: 17px;
}
#custom-recorder,
#connection,
#cnoti,
#brightness,
#power,
#custom-updates,
#tray,
#audio,
#privacy,
#sound {
border-radius: 4px;
margin: 2px 2px 4px 2px;
background: alpha(darker(@active), 0.3);
}
#custom-notifications {
padding-left: 4px;
}
#custom-hotspot,
#custom-github,
#custom-notifications {
font-size: 20px;
}
#custom-hotspot {
padding-right: 2px;
}
#custom-vpn,
#custom-hotspot {
background: alpha(darker(@active), 0.3);
}
#privacy-item {
padding: 6px 0px 6px 6px;
}
#gcpu {
padding: 8px 0px 8px 0px;
}
#custom-cpu-icon {
font-size: 36px;
}
#custom-cputemp,
#temperature {
font-size: 17px;
}
#disk,
#memory,
#cpu {
font-size: 20px;
font-weight: bold;
}
#custom-github {
padding-top: 2px;
padding-right: 4px;
}
#custom-dmark {
color: alpha(@foreground, 0.3);
}
#submap {
margin-bottom: 0px;
}
#hyprland.window {
margin-left: 20px;
}
#workspaces {
margin: 0px 2px;
padding: 4px 0px 0px 0px;
border-radius: 8px;
}
#workspaces button {
transition-property: background-color;
transition-duration: 0.5s;
color: @foreground;
background: transparent;
border-radius: 4px;
color: alpha(@foreground, 0.3);
}
#workspaces button.urgent {
font-weight: bold;
color: @foreground;
}
#workspaces button.active {
padding: 4px 2px;
background: alpha(@active, 0.4);
color: lighter(@active);
border-radius: 4px;
}
#network.wifi {
padding-right: 4px;
}
#submap {
min-width: 0px;
margin: 4px 6px 4px 6px;
}
#tray {
padding: 0px 0px 0px 0px;
}
#bluetooth {
padding-top: 2px;
}
#window {
border-radius: 8px;
padding: 4px 14px;
margin: 4px 2px 4px 2px;
}
#battery {
font-size: 17px;
border-radius: 8px;
padding: 4px 0px;
margin: 4px 2px 4px 2px;
}
#battery.discharging.warning {
animation-name: blink-yellow;
animation-duration: 1s;
animation-timing-function: linear;
animation-iteration-count: infinite;
animation-direction: alternate;
}
#battery.discharging.critical {
animation-name: blink-red;
animation-duration: 1s;
animation-timing-function: linear;
animation-iteration-count: infinite;
animation-direction: alternate;
}
#battery.powerdraw {
font-size: 17px;
padding: 0;
margin-right: -20px;
margin-left: -20px;
}
#battery.w {
font-size: 17px;
padding: 0;
margin-left: -20px;
margin-right: -20px;
}
#clock {
font-weight: bold;
padding: 4px 2px 2px 2px;
}
#pulseaudio.mic {
border-radius: 4px;
color: @background;
background: alpha(darker(@foreground), 0.6);
padding-left: 4px;
}
#backlight-slider slider,
#pulseaudio-slider slider {
background-color: transparent;
box-shadow: none;
}
#backlight-slider trough,
#pulseaudio-slider trough {
margin-top: 4px;
min-width: 6px;
min-height: 60px;
border-radius: 8px;
background-color: alpha(@background, 0.6);
}
#backlight-slider highlight,
#pulseaudio-slider highlight {
border-radius: 8px;
background-color: lighter(@active);
}
#bluetooth.discoverable,
#bluetooth.discovering,
#bluetooth.pairable {
border-radius: 8px;
animation-name: blink-active;
animation-duration: 1s;
animation-timing-function: linear;
animation-iteration-count: infinite;
animation-direction: alternate;
}
@keyframes blink-active {
to {
background-color: @active;
color: @foreground;
}
}
@keyframes blink-red {
to {
background-color: #c64d4f;
color: @foreground;
}
}
@keyframes blink-yellow {
to {
background-color: #cf9022;
color: @foreground;
}
}
'';
};
}
-115
View File
@@ -1,115 +0,0 @@
_: let
wallpaper = ../../assets/wallpaper1.jpg;
lock = ../../assets/lock.png;
lock-hover = ../../assets/lock-hover.png;
shutdown = ../../assets/power.png;
shutdown-hover = ../../assets/power-hover.png;
logout = ../../assets/logout.png;
logout-hover = ../../assets/logout-hover.png;
reboot = ../../assets/restart.png;
reboot-hover = ../../assets/restart-hover.png;
in {
programs.wlogout = {
enable = true;
layout = [
{
label = "lock";
action = "swaylock -eFLfk -i ${wallpaper}";
text = " Lock (L) ";
keybind = "l";
}
{
label = "reboot";
action = "systemctl reboot";
text = " Reboot (R) ";
keybind = "r";
}
{
label = "shutdown";
action = "systemctl poweroff";
text = "Shutdown (S)";
keybind = "s";
}
{
label = "logout";
action = "loginctl terminate-session $(loginctl show-session $(loginctl | grep $USER | awk '{print $1}') -p Id --value)";
text = " Logout (E) ";
keybind = "e";
}
];
style = ''
window {
font-family: OxProto Nerd Font;
font-size: 14pt;
color: #000000; /* text */
background-color: rgba(40, 40, 40, 0.76);
}
button {
background-repeat: no-repeat;
background-position: center;
background-size: 50%;
border-style: solid;
border-radius: 4px;
border-width: 2px;
border-color: #ebdbb2;
background-color: rgba(40, 40, 40, 0.76);
margin: 10px;
transition:
box-shadow 0.3s ease-in-out,
background-color 0.3s ease-in-out;
}
button:hover {
background-color: rgba(250, 137, 26, 0.3);
color: #282828;
}
button:focus {
background-color: #ebdbb2;
color: #282828;
}
#lock {
background-image: image(url("${lock}"));
}
#lock:focus {
background-image: image(url("${lock-hover}"));
}
#lock:hover {
background-image: image(url("${lock-hover}"));
}
#logout {
background-image: image(url("${logout}"));
}
#logout:focus {
background-image: image(url("${logout-hover}"));
}
#logout:hover {
background-image: image(url("${logout-hover}"));
}
#shutdown {
background-image: image(url("${shutdown}"));
}
#shutdown:focus {
background-image: image(url("${shutdown-hover}"));
}
#shutdown:hover {
background-image: image(url("${shutdown-hover}"));
}
#reboot {
background-image: image(url("${reboot}"));
}
#reboot:focus {
background-image: image(url("${reboot-hover}"));
}
#reboot:hover {
background-image: image(url("${reboot-hover}"));
}
'';
};
}
-6
View File
@@ -1,6 +0,0 @@
_: {
programs.zoxide = {
enable = true;
enableZshIntegration = true;
};
}
-55
View File
@@ -1,55 +0,0 @@
{pkgs-unstable, ...}: {
home.packages = [
(pkgs-unstable.callPackage ../packages/deja.nix {})
];
programs.zsh = {
enable = true;
autosuggestion.enable = false; # zsh-autocomplete is replaced by deja
initContent = ''
# Safe cat that uses colorize plugin ccat
custom-cat() {
if [[ -t 1 ]]; then
ccat "$@"
else
command cat "$@"
fi
}
custom-eza() { # behaves differently if we just call it or if we pipe initContent
if [[ -t 1 ]]; then
eza -hlF -aa --color=always --hyperlink --group-directories-first --show-symlinks --icons=always --git --no-permissions "$@"
else
command eza "$@"
fi
}
eval "$(direnv hook zsh)"
eval "$(deja init zsh)"
export PATH="$PATH:$HOME/NoteWrapper" # some project im coding
fastfetch''\n'';
shellAliases = {
".." = "z ..";
grep = "rg";
ll = "custom-eza"; # if there is a special ls just use the big eza
la = "custom-eza";
l = "custom-eza";
eza = "custom-eza";
ls = "\\eza -a"; # ls -> normal ls. eza gives more info
tree = "\\eza -hlTF --color=always --hyperlink --group-directories-first --show-symlinks --icons=always --git --no-permissions";
cat = "custom-cat";
pomodoro = "custom-tomato";
librewolf = "kitty --class \"custom-librewolfprofiles\" --name \"Select LibreWolf profile\" --hold custom-librewolfprofiles";
manix = "custom-manix";
man = "custom-man";
mplayer = "mplayer -volume 5";
# these are to create the developpement shell
cenv = "nix-shell -p zsh gcc raylib libx11 libGL";
# i always write nvim wrong :(
nbim = "nvim";
nivm = "nvim";
bivm = "nvim";
nibm = "nvim";
vikm = "nvim";
};
};
}
+114
View File
@@ -0,0 +1,114 @@
{ inputs, self, ...}: {
flake.nixosConfiguration.laptop = inputs.nixpkgs.lib.nixosSystem {
modules = with self.nixosModules; [
# keep this alphabetically organised
anki
audioAndMedia
autoCleanup-laptop
autoUpdate-laptop
battery-laptop
bluetooth
bootloader-laptop
browsers
caelestia
development
documentation
disk
disk-laptop
fonts
games
hardware-configuration-laptop
hardwareUtils-laptop
home-manager-laptop
hyprland
IO
kdrive
latex
ly
mullvad
networking
notifications
office
#ollama
otherUtils
printer
udev
user
];
};
flake.homeConfiguration.tomasr = inputs.home-manager.lib.homeManagerConfiguration {
pkgs = import inputs.nixpkgs { system = "x86_64-linux"; };
pkgs-unstable = import inputs.nixpkgs-unstable { system = "x86_64-linux"; };
modules = with self.homeModules; [
anki
cursor
eza
fastfetch
git
gtk
hyprland
hyprland-laptop
kitty
librewolf
mullvad
neovim
oh-my-zsh
ripgrep
rofi
sbb-tui
ssh
thunderbird
tomasrModule
vivify
zoxide
zsh
zsh-laptop
];
};
flake.nixosModules.laptop = { ... }: {
# This value determines the NixOS release from which the default
# settings for stateful data, like file locations and database versions
# on your system were taken. Its perfectly fine and recommended to leave
# this value at the release version of the first install of this system.
# Before changing this value read the documentation for this option
# (e.g. man configuration.nix or on https://nixos.org/nixos/options.html).
system.stateVersion = "25.11"; # Did you read the comment?
home-manager.users.USERNAME = self.homeModules.USERNAMEModule;
};
flake.nixosModules.home-manager-laptop = { ... }: {
imports = [
inputs.home-manager.nixosModules.default # import official home-manager NixOS module
];
home-manager = {
useGlobalPkgs = true;
useUserPackages = true;
};
};
flake.homeModules.tomasrModule = { ... }: {
imports = [
inputs.caelestia-shell.homeManagerModules.default
];
home.username = "tomasr";
home.homeDirectory = "/home/tomasr";
home.sessionVariables = {
EDITOR = "neovim";
TERMINAL = "kitty";
};
# Required for Home Manager
home.stateVersion = "25.11"; # match your Home Manager release
# This value determines the Home Manager release that your configuration is
# compatible with. This helps avoid breakage when a new Home Manager release
# introduces backwards incompatible changes.
#
# You should not change this value, even if you update Home Manager. If you do
# want to update the value, then make sure to first check the Home Manager
# release notes.
# Let Home Manager install and manage itself.
programs.home-manager.enable = true;
};
}
-302
View File
@@ -1,302 +0,0 @@
_: {
services.displayManager.ly = {
enable = true;
settings = {
animation = "gameoflife"; # none or doom or matrix or gameoflife or a dur file
animation_frame_delay = 5;
animation_timeout_sec = 0;
asterisk = "0x2022";
auth_fails = 2; # numbers of failed authentification before special animation
battery_id = "BAT1";
bigclock = "en";
bigclock_12hr = false;
bigclock_seconds = false;
# Blank main box background
# Setting to false will make it transparent
blank_box = false;
# Border foreground color id
border_fg = "0x00FFFFFF";
# Title to show at the top of the main box
# If set to null, none will be shown
box_title = null;
# Brightness decrease command
brightness_down_cmd = "$PREFIX_DIRECTORY/bin/brightnessctl -q -n s 10%-";
# Brightness decrease key combination, or null to disable
brightness_down_key = "F5";
# Brightness increase command
brightness_up_cmd = "$PREFIX_DIRECTORY/bin/brightnessctl -q -n s +10%";
# Brightness increase key combination, or null to disable
brightness_up_key = "F6";
# Erase password input on failure
clear_password = true;
# Format string for clock in top right corner (see strftime specification). Example: %c
# If null, the clock won't be shown
clock = true;
# CMatrix animation foreground color id
cmatrix_fg = "0x0000FF00";
# CMatrix animation character string head color id
cmatrix_head_col = "0x01FFFFFF";
# CMatrix animation minimum codepoint. It uses a 16-bit integer
# For Japanese characters for example, you can use 0x3000 here
cmatrix_min_codepoint = "0x21";
# CMatrix animation maximum codepoint. It uses a 16-bit integer
# For Japanese characters for example, you can use 0x30FF here
cmatrix_max_codepoint = "0x7B";
# Color mixing animation first color id
colormix_col1 = "0x00FF0000";
# Color mixing animation second color id
colormix_col2 = "0x000000FF";
# Color mixing animation third color id
colormix_col3 = "0x20000000";
# Custom sessions directory
# You can specify multiple directories,
# e.g. $CONFIG_DIRECTORY/ly/custom-sessions:$PREFIX_DIRECTORY/share/custom-sessions
custom_sessions = "$CONFIG_DIRECTORY/ly/custom-sessions";
# Input box active by default on startup
# Available inputs: info_line, session, login, password
default_input = "password";
# DOOM animation fire height (1 thru 9)
doom_fire_height = 6;
# DOOM animation fire spread (0 thru 4)
doom_fire_spread = 2;
# DOOM animation custom top color (low intensity flames)
doom_top_color = "0x009F2707";
# DOOM animation custom middle color (medium intensity flames)
doom_middle_color = "0x00C78F17";
# DOOM animation custom bottom color (high intensity flames)
doom_bottom_color = "0x00FFFFFF";
# Dur file path
dur_file_path = "$CONFIG_DIRECTORY/ly/example.dur";
# Dur file alignment
# The dur file can be aligned with a direction and centered easily with the flags below
# Available inputs: topleft, topcenter, topright, centerleft, center, centerright, bottomleft, bottomcenter, bottomright
dur_offset_alignment = "center";
# Dur offset x direction (value is added to the current position determined by alignment, negatives are supported)
dur_x_offset = 0;
# Dur offset y direction (value is added to the current position determined by alignment, negatives are supported)
dur_y_offset = 0;
# Set margin to the edges of the DM (useful for curved monitors)
edge_margin = 0;
# Error background color id
error_bg = "0x00000000";
# Error foreground color id
# Default is red and bold
error_fg = "0x01FF0000";
# Foreground color id
fg = "0x00FFFFFF";
# Render true colors (if supported)
# If false, output will be in eight-color mode
# All eight-color mode color codes:
# TB_DEFAULT 0x0000
# TB_BLACK 0x0001
# TB_RED 0x0002
# TB_GREEN 0x0003
# TB_YELLOW 0x0004
# TB_BLUE 0x0005
# TB_MAGENTA 0x0006
# TB_CYAN 0x0007
# TB_WHITE 0x0008
# If full color is off, the styling options still work. The colors are
# always 32-bit values with the styling in the most significant byte.
# Note: If using the dur_file animation option and the dur file's color range
# is saved as 256 with this option disabled, the file will not be drawn.
full_color = true;
# Game of Life entropy interval (0 = disabled, >0 = add entropy every N generations)
# 0 -> Pure Conway's Game of Life (will eventually stabilize)
# 10 -> Add entropy every 10 generations (recommended for continuous activity)
# 50+ -> Less frequent entropy for more natural evolution
gameoflife_entropy_interval = 10;
# Game of Life animation foreground color id
gameoflife_fg = "0x0000FF00";
# Game of Life frame delay (lower = faster animation, higher = slower)
# 1-3 -> Very fast animation
# 6 -> Default smooth animation speed
# 10+ -> Slower, more contemplative speed
gameoflife_frame_delay = 3;
# Game of Life initial cell density (0.0 to 1.0)
# 0.1 -> Sparse, minimal activity
# 0.4 -> Balanced activity (recommended)
# 0.7+ -> Dense, chaotic patterns
gameoflife_initial_density = 0.666;
# Command executed when pressing hibernate key (can be null)
hibernate_cmd = null;
# Specifies the key combination used for hibernate
hibernate_key = "F4";
# Remove main box borders
hide_borders = false;
# Remove power management command hints
hide_key_hints = false;
# Remove keyboard lock states from the top right corner
hide_keyboard_locks = false;
# Remove version number from the top left corner
hide_version_string = false;
# Command executed when no input is detected for a certain time
# If null, no command will be executed
inactivity_cmd = null;
# Executes a command after a certain amount of seconds
inactivity_delay = 0;
# Initial text to show on the info line
# If set to null, the info line defaults to the hostname
initial_info_text = null;
# Input boxes length
input_len = 34;
# Active language
# Available languages are found in $CONFIG_DIRECTORY/ly/lang/
lang = "en";
# Command executed when logging in
# If null, no command will be executed
# Important: the code itself must end with `exec "$@"` in order to launch the session!
# You can also set environment variables in there, they'll persist until logout
login_cmd = null;
# Path for login.defs file (used for listing all local users on the system on
# Linux)
#login_defs_path = /etc/login.defs
# Command executed when logging out
# If null, no command will be executed
# Important: the session will already be terminated when this command is executed, so
# no need to add `exec "$@"` at the end
logout_cmd = null;
# General log file path
#ly_log = /var/log/ly.log
# Main box horizontal margin
margin_box_h = 2;
# Main box vertical margin
margin_box_v = 1;
# Set numlock on/off at startup
numlock = false;
# Default path
# If null, ly doesn't set a path
#path = "/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin"
# Command executed when pressing restart_key
#restart_cmd = "/sbin/shutdown -r now"
# Specifies the key combination used for restart
restart_key = "F2";
# Save the current desktop and login as defaults, and load them on startup
save = true;
# Service name (set to ly to use the provided pam config file)
service_name = "ly";
# Session log file path
# This will contain stdout and stderr of Wayland sessions
# By default it's saved in the user's home directory
# Important: due to technical limitations, X11, shell sessions as well as
# launching session via KMSCON aren't supported, which means you won't get any
# logs from those sessions.
# If null, no session log will be created
session_log = null;
# Setup command
setup_cmd = "$CONFIG_DIRECTORY/ly/setup.sh";
# Command executed when pressing shutdown_key
shutdown_cmd = "/sbin/shutdown $PLATFORM_SHUTDOWN_ARG now";
# Specifies the key combination used for shutdown
shutdown_key = "F1";
# Command executed when pressing sleep key (can be null)
sleep_cmd = null;
# Specifies the key combination used for sleep
sleep_key = "F3";
# Command executed when starting Ly (before the TTY is taken control of)
# See file at path below for an example of changing the default TTY colors
start_cmd = "$CONFIG_DIRECTORY/ly/startup.sh";
# Center the session name.
text_in_center = false;
# Default vi mode
# normal -> normal mode
# insert -> insert mode
vi_default_mode = "normal";
# Enable vi keybindings
vi_mode = false;
# Wayland desktop environments
# You can specify multiple directories,
# e.g. $PREFIX_DIRECTORY/share/wayland-sessions:$PREFIX_DIRECTORY/local/share/wayland-sessions
waylandsessions = "$PREFIX_DIRECTORY/share/wayland-sessions";
# Xorg server command
x_cmd = "$PREFIX_DIRECTORY/bin/X";
# Xorg virtual terminal number
# Mostly useful for FreeBSD where choosing the current TTY causes issues
# If null, the current TTY will be chosen
x_vt = null;
# Xorg xauthority edition tool
xauth_cmd = "$PREFIX_DIRECTORY/bin/xauth";
# xinitrc
# If null, the xinitrc session will be hidden
xinitrc = "~/.xinitrc";
# Xorg desktop environments
# You can specify multiple directories,
# e.g. $PREFIX_DIRECTORY/share/xsessions:$PREFIX_DIRECTORY/local/share/xsessions
xsessions = "$PREFIX_DIRECTORY/share/xsessions";
};
};
}
-138
View File
@@ -1,138 +0,0 @@
{
config,
pkgs,
...
}: {
# udev are setup for controlling the framework 16 laptop's keyboard
services.udev.extraRules = ''
## https://github.com/qmk/qmk_firmware/blob/master/util/udev/50-qmk.extraRules
## Atmel DFU
#### ATmega16U2
#SUBSYSTEMS=="usb", ATTRS{idVendor}=="03eb", ATTRS{idProduct}=="2fef", TAG+="uaccess"
#### ATmega32U2
#SUBSYSTEMS=="usb", ATTRS{idVendor}=="03eb", ATTRS{idProduct}=="2ff0", TAG+="uaccess"
#### ATmega16U4
#SUBSYSTEMS=="usb", ATTRS{idVendor}=="03eb", ATTRS{idProduct}=="2ff3", TAG+="uaccess"
#### ATmega32U4
#SUBSYSTEMS=="usb", ATTRS{idVendor}=="03eb", ATTRS{idProduct}=="2ff4", TAG+="uaccess"
#### AT90USB64
#SUBSYSTEMS=="usb", ATTRS{idVendor}=="03eb", ATTRS{idProduct}=="2ff9", TAG+="uaccess"
#### AT90USB162
#SUBSYSTEMS=="usb", ATTRS{idVendor}=="03eb", ATTRS{idProduct}=="2ffa", TAG+="uaccess"
#### AT90USB128
#SUBSYSTEMS=="usb", ATTRS{idVendor}=="03eb", ATTRS{idProduct}=="2ffb", TAG+="uaccess"
#
## Input Club
#SUBSYSTEMS=="usb", ATTRS{idVendor}=="1c11", ATTRS{idProduct}=="b007", TAG+="uaccess"
#
## STM32duino
#SUBSYSTEMS=="usb", ATTRS{idVendor}=="1eaf", ATTRS{idProduct}=="0003", TAG+="uaccess"
## STM32 DFU
#SUBSYSTEMS=="usb", ATTRS{idVendor}=="0483", ATTRS{idProduct}=="df11", TAG+="uaccess"
#
## BootloadHID
#SUBSYSTEMS=="usb", ATTRS{idVendor}=="16c0", ATTRS{idProduct}=="05df", TAG+="uaccess"
#
## USBAspLoader
#SUBSYSTEMS=="usb", ATTRS{idVendor}=="16c0", ATTRS{idProduct}=="05dc", TAG+="uaccess"
#
## USBtinyISP
#SUBSYSTEMS=="usb", ATTRS{idVendor}=="1782", ATTRS{idProduct}=="0c9f", TAG+="uaccess"
#
## ModemManager should ignore the following devices
## Atmel SAM-BA (Massdrop)
#SUBSYSTEMS=="usb", ATTRS{idVendor}=="03eb", ATTRS{idProduct}=="6124", TAG+="uaccess", ENV{ID_MM_DEVICE_IGNORE}="1"
#
## Caterina (Pro Micro)
### pid.codes shared PID
#### Keyboardio Atreus 2 Bootloader
#SUBSYSTEMS=="usb", ATTRS{idVendor}=="1209", ATTRS{idProduct}=="2302", TAG+="uaccess", ENV{ID_MM_DEVICE_IGNORE}="1"
### Spark Fun Electronics
#### Pro Micro 3V3/8MHz
#SUBSYSTEMS=="usb", ATTRS{idVendor}=="1b4f", ATTRS{idProduct}=="9203", TAG+="uaccess", ENV{ID_MM_DEVICE_IGNORE}="1"
#### Pro Micro 5V/16MHz
#SUBSYSTEMS=="usb", ATTRS{idVendor}=="1b4f", ATTRS{idProduct}=="9205", TAG+="uaccess", ENV{ID_MM_DEVICE_IGNORE}="1"
#### LilyPad 3V3/8MHz (and some Pro Micro clones)
#SUBSYSTEMS=="usb", ATTRS{idVendor}=="1b4f", ATTRS{idProduct}=="9207", TAG+="uaccess", ENV{ID_MM_DEVICE_IGNORE}="1"
### Pololu Electronics
#### A-Star 32U4
#SUBSYSTEMS=="usb", ATTRS{idVendor}=="1ffb", ATTRS{idProduct}=="0101", TAG+="uaccess", ENV{ID_MM_DEVICE_IGNORE}="1"
### Arduino SA
#### Leonardo
#SUBSYSTEMS=="usb", ATTRS{idVendor}=="2341", ATTRS{idProduct}=="0036", TAG+="uaccess", ENV{ID_MM_DEVICE_IGNORE}="1"
#### Micro
#SUBSYSTEMS=="usb", ATTRS{idVendor}=="2341", ATTRS{idProduct}=="0037", TAG+="uaccess", ENV{ID_MM_DEVICE_IGNORE}="1"
### Adafruit Industries LLC
#### Feather 32U4
#SUBSYSTEMS=="usb", ATTRS{idVendor}=="239a", ATTRS{idProduct}=="000c", TAG+="uaccess", ENV{ID_MM_DEVICE_IGNORE}="1"
#### ItsyBitsy 32U4 3V3/8MHz
#SUBSYSTEMS=="usb", ATTRS{idVendor}=="239a", ATTRS{idProduct}=="000d", TAG+="uaccess", ENV{ID_MM_DEVICE_IGNORE}="1"
#### ItsyBitsy 32U4 5V/16MHz
#SUBSYSTEMS=="usb", ATTRS{idVendor}=="239a", ATTRS{idProduct}=="000e", TAG+="uaccess", ENV{ID_MM_DEVICE_IGNORE}="1"
### dog hunter AG
#### Leonardo
#SUBSYSTEMS=="usb", ATTRS{idVendor}=="2a03", ATTRS{idProduct}=="0036", TAG+="uaccess", ENV{ID_MM_DEVICE_IGNORE}="1"
#### Micro
#SUBSYSTEMS=="usb", ATTRS{idVendor}=="2a03", ATTRS{idProduct}=="0037", TAG+="uaccess", ENV{ID_MM_DEVICE_IGNORE}="1"
#
## hid_listen
#KERNEL=="hidraw*", MODE="0660", GROUP="plugdev", TAG+="uaccess", TAG+="udev-acl"
#
## hid bootloaders
### QMK HID
#SUBSYSTEMS=="usb", ATTRS{idVendor}=="03eb", ATTRS{idProduct}=="2067", TAG+="uaccess"
### PJRC's HalfKay
#SUBSYSTEMS=="usb", ATTRS{idVendor}=="16c0", ATTRS{idProduct}=="0478", TAG+="uaccess"
#
## APM32 DFU
#SUBSYSTEMS=="usb", ATTRS{idVendor}=="314b", ATTRS{idProduct}=="0106", TAG+="uaccess"
#
## GD32V DFU
#SUBSYSTEMS=="usb", ATTRS{idVendor}=="28e9", ATTRS{idProduct}=="0189", TAG+="uaccess"
#
## WB32 DFU
#SUBSYSTEMS=="usb", ATTRS{idVendor}=="342d", ATTRS{idProduct}=="dfa0", TAG+="uaccess"
#
## AT32 DFU
# SUBSYSTEMS=="usb", ATTRS{idVendor}=="2e3c", ATTRS{idProduct}=="df11", TAG+="uaccess"
# and # https://community.frame.work/t/guide-updated-after-firmware-updates-udev-rules-for-https-keyboard-frame-work/78708
#SUBSYSTEMS=="usb", ATTRS{idVendor}=="32ac", ATTRS{idProduct}=="0010", TAG+="uaccess"
#SUBSYSTEMS=="usb", ATTRS{idVendor}=="32ac", ATTRS{idProduct}=="0012", TAG+="uaccess"
SUBSYSTEMS=="usb", ATTRS{idVendor}=="32ac", ATTRS{idProduct}=="0013", TAG+="uaccess"
#SUBSYSTEMS=="usb", ATTRS{idVendor}=="32ac", ATTRS{idProduct}=="0014", TAG+="uaccess"
SUBSYSTEMS=="usb", ATTRS{idVendor}=="32ac", ATTRS{idProduct}=="0018", TAG+="uaccess"
#SUBSYSTEMS=="usb", ATTRS{idVendor}=="32ac", ATTRS{idProduct}=="0019", TAG+="uaccess"
# USB [VendorID]:[ProductID] [Manufacturer][Product name]
# 32ac:0012 Framework Laptop 16 Keyboard Module - ANSI
# 32ac:0013 Framework Laptop 16 RGB Macropad
# 32ac:0014 Framework Laptop 16 Numpad Module
# 32ac:0018 Framework Laptop 16 Keyboard Module - ISO
# 32ac:0019 Framework Laptop 16 Keyboard Module - JIS
##https://github.com/ublue-os/config/blob/main/files/etc/udev/rules.d/50-framework16.rules
## Audio Expansion Card
#ACTION=="add", SUBSYSTEM=="usb", ATTR{idVendor}=="32ac", ATTR{idProduct}=="0010", ATTR{power/autosuspend}="10", ATTR{power/control}="auto", GOTO="rules_end"
#
## Framework Laptop 16 Keyboard Module - ANSI
#ACTION=="add", SUBSYSTEM=="usb", ATTR{idVendor}=="32ac", ATTR{idProduct}=="0012", ATTR{power/autosuspend}="-1", ATTR{power/control}="on", ATTR{power/wakeup}="disabled", GOTO="rules_end"
#
## Framework Laptop 16 RGB Macropad
#
## Framework Laptop 16 Numpad Module
#ACTION=="add", SUBSYSTEM=="usb", ATTR{idVendor}=="32ac", ATTR{idProduct}=="0014", ATTR{power/autosuspend}="-1", ATTR{power/control}="on", ATTR{power/wakeup}="disabled", GOTO="rules_end"
#
## Framework Laptop 16 Keyboard Module
#ACTION=="add", SUBSYSTEM=="usb", ATTR{idVendor}=="32ac", ATTR{idProduct}=="0018", ATTR{power/autosuspend}="-1", ATTR{power/control}="on", ATTR{power/wakeup}="disabled", GOTO="rules_end"
#
#LABEL="rules_end"
'';
}
-20
View File
@@ -1,20 +0,0 @@
{pkgs, ...}: {
# Configure keymap in X11
services.xserver.xkb = {
layout = "ch";
variant = "fr";
};
# Configure console keymap
console.keyMap = "fr_CH";
# Enable touchpad support (enabled default in most desktopManager).
# services.xserver.libinput.enable = true;
environment.systemPackages = with pkgs; [
wl-clipboard
cliphist
hyprkeys # keybind helper
hyprpicker
];
}
-53
View File
@@ -1,53 +0,0 @@
{pkgs, ...}: {
environment.systemPackages = with pkgs; [
(pkgs.anki.withAddons [
(pkgs.ankiAddons.recolor.withConfig {
config = {
# we must specify all the colors or it crashes as this overwrite the whole colors set
colors = {
# ===== Foregrounds =====
FG = ["Foreground" "#ebdbb2" "#ebdbb2" ""];
FG_SUBTLE = ["Subtle FG" "#d5c4a1" "#d5c4a1" ""];
FG_FAINT = ["Faint FG" "#a89984" "#a89984" ""];
FG_DISABLED = ["Disabled FG" "#928374" "#928374" ""];
# ===== Main Background Layers =====
BG = ["Background" "#1d2021" "#1d2021" ""];
MAIN_BG = ["Main Background" "#1d2021" "#1d2021" ""];
VIEW_BG = ["View Background" "#282828" "#282828" ""];
EDITOR_BG = ["Editor Background" "#282828" "#282828" ""];
CANVAS = ["Canvas" "#282828" "#282828" ""];
CANVAS_ELEVATED = ["Elevated Canvas" "#32302f" "#32302f" ""];
# ===== Tables & Lists =====
TABLE_BG = ["Table Background" "#282828" "#282828" ""];
TABLE_ALT_BG = ["Table Alt Background" "#32302f" "#32302f" ""];
HEADER_BG = ["Header Background" "#3c3836" "#3c3836" ""];
SELECTED_BG = ["Selected Background" "#504945" "#504945" ""];
# ===== Borders =====
BORDER = ["Border" "#504945" "#504945" ""];
FAINT_BORDER = ["Faint Border" "#3c3836" "#3c3836" ""];
# ===== Buttons =====
BUTTON_GRADIENT_START = ["Button Start" "#3c3836" "#3c3836" ""];
BUTTON_GRADIENT_END = ["Button End" "#3c3836" "#3c3836" ""];
BUTTON_HOVER = ["Button Hover" "#665c54" "#665c54" ""];
# ===== Accent & Links =====
ACCENT = ["Accent" "#458588" "#458588" ""];
LINK = ["Link" "#83a598" "#83a598" ""];
LINK_HOVER = ["Link Hover" "#8ec07c" "#8ec07c" ""];
# ===== Status =====
WARNING = ["Warning" "#fe8019" "#fe8019" ""];
ERROR = ["Error" "#fb4934" "#fb4934" ""];
SUCCESS = ["Success" "#8ec07c" "#8ec07c" ""];
};
};
# version = { major = 3; minor = 1; };
# let nixpkgs handle the version
})
])
];
}
-34
View File
@@ -1,34 +0,0 @@
{pkgs, ...}: {
# Enable sound with pipewire.
services.pulseaudio.enable = false;
security.rtkit.enable = true;
services.pipewire = {
enable = true;
alsa.enable = true;
alsa.support32Bit = true;
pulse.enable = true;
# If you want to use JACK applications, uncomment this
#jack.enable = true;
# use the example session manager (no others are packaged yet so this is enabled by default,
# no need to redefine it in your config for now)
#media-session.enable = true;
};
environment.systemPackages = with pkgs; [
(pkgs.callPackage ../../modules/scripts/changeAudioOutput.nix {})
kdePackages.okular
kdePackages.dolphin
pulseaudio # sound server
playerctl # controls media player
pavucontrol # PulseAudio Volume Control
mplayer # Movie player that supports many video formats
krita # image edition
yt-dlp # some youtube downloader
vlc
#mprisence # Highly customizable Discord Rich Presence for MPRIS media players on Linux
#gif-for-cli # Render gifs as ASCII art in your cli
#rembg # background remover
gpu-screen-recorder
inkscape
];
}
-6
View File
@@ -1,6 +0,0 @@
{pkgs, ...}: {
hardware.bluetooth.enable = true;
environment.systemPackages = with pkgs; [
blueman # GTK-based Bluetooth Manager
];
}
-13
View File
@@ -1,13 +0,0 @@
# configuration for main browser is in ../home-manager/librewolf.nix
# configuration for qutebrowser is in ../home-manager/vivify.nix
{
pkgs,
pkgs-unstable,
...
}: {
environment.systemPackages = with pkgs; [
chromium # used only to flash the firmware on my framework laptop 16 (keyboard.frame.work) as only chromium based browser support webHID.
pkgs-unstable.tor-browser
(pkgs.callPackage ../../modules/scripts/librewolfprofiles.nix {}) # fzf librewolf profile selector
];
}
-33
View File
@@ -1,33 +0,0 @@
{
pkgs,
pkgs-unstable,
...
}: {
programs.nix-ld.enable = true; #Run unpatched dynamic binaries on NixOS. For example lets run ./a.out from gcc
environment.systemPackages = with pkgs; [
gcc
jq # json parser used in some scripts
jp # lightweight and flexible cli JSON parser
(pkgs-unstable.python314.withPackages (ps:
with ps; [
matplotlib
networkx
scipy
]))
python313Packages.pygments # used for ccat (comment of colorize plugin from oh-my-zsh)
pkg-config
gdb
raylib
glfw # raylib and some dependecies
gnumake
go
direnv
cling # c interpreter used for coding
# lsp
clang-tools
python311Packages.python-lsp-server
ltex-ls-plus
pylint
black
];
}
-11
View File
@@ -1,11 +0,0 @@
{pkgs, ...}: {
environment.systemPackages = with pkgs; [
gnome-disk-utility
udiskie # removable disk automounter for udisks
(pkgs.callPackage ../../modules/scripts/mountkdrive.nix {})
];
# removes rclone error
programs.fuse.userAllowOther = true;
programs.fuse.enable = true;
}
-14
View File
@@ -1,14 +0,0 @@
{pkgs, ...}: {
documentation.man.generateCaches = true; # used for the man script
environment.pathsToLink = [
# see https://wiki.nixos.org/wiki/Documentation_Gaps#How_do_manpages_work?_Or:_environment.pathsToLink_and_buildEnv
"/share/applications"
"/share/xdg-desktop-portal"
];
environment.systemPackages = [
pkgs.manix
(pkgs.callPackage ../../modules/scripts/manix.nix {}) # fzf manix searcher
(pkgs.callPackage ../../modules/scripts/man.nix {}) # fzf man searcher
];
}
-12
View File
@@ -1,12 +0,0 @@
{pkgs, ...}: {
# fonts
fonts.packages = with pkgs; [
nerd-fonts._0xproto
cinzel
times-newer-roman
];
environment.systemPackages = with pkgs; [
gnome-font-viewer
];
}
-7
View File
@@ -1,7 +0,0 @@
{pkgs, ...}: {
environment.systemPackages = with pkgs; [
supertux # fuck mario
supertuxkart # fuck mariokart
# my favorite italian plumber is free software
];
}
-44
View File
@@ -1,44 +0,0 @@
{pkgs, ...}: {
environment.systemPackages = with pkgs; [
texlab
ltex-ls-plus
biber
(pkgs.texliveMedium.withPackages (
ps:
with ps; [
# these few pkgs are used in the CV template
titlesec # allows creating custom \section
marvosym # some symboles
ebgaramond # Use the EB Garamond font
microtype # To enable letterspacing
fontaxes
# these few pkgs were used for my TM
svg
catchfile
caption
transparent
cfr-lm
svn-prov
nfssext-cfr
hyphenat
csquotes
enumitem
chngcntr
tcolorbox
pdfcol
wrapfig
tocloft
lastpage
biblatex
biblatex-iso690
libertine
minted
upquote
lipsum
footmisc
#(setq org-latex-compiler "lualatex")
#(setq org-preview-latex-default-process 'dvisvgm)
]
))
];
}
-94
View File
@@ -1,94 +0,0 @@
_: {
# a minimal ly config as the big config (ly.nix) didnt worked
services.displayManager.ly = {
enable = true;
settings = {
# Core animation
animation = "none"; # none or doom or matrix or gameoflife or a dur file
# Ly supports 24-bit true color with styling, which means each color is a 32-bit value.
# The format is 0xSSRRGGBB, where SS is the styling, RR is red, GG is green, and BB is blue.
# Here are the possible styling options:
# TB_BOLD 0x01000000
# TB_UNDERLINE 0x02000000
# TB_REVERSE 0x04000000
# TB_ITALIC 0x08000000
# TB_BLINK 0x10000000
# TB_HI_BLACK 0x20000000
# TB_BRIGHT 0x40000000
# TB_DIM 0x80000000
# Programmatically, you'd apply them using the bitwise OR operator (|), but because Ly's
# configuration doesn't support using it, you have to manually compute the color value.
# Note that, if you want to use the default color value of the terminal, you can use the
# special value 0x00000000. This means that, if you want to use black, you *must* use
# the styling option TB_HI_BLACK (the RGB values are ignored when using this option).
# Basic TUI settings
clear_password = true;
default_input = "password";
fg = "0x01cd6400";
full_color = true;
hide_borders = false;
hide_key_hints = false;
hide_keyboard_locks = true;
hide_version_string = false;
input_len = 34;
lang = "en";
numlock = false;
save = true;
service_name = "ly";
bigclock = "en";
clock = "%H:%M";
colormix_col1 = "0x08E85D04";
colormix_col2 = "0x08FABD2F";
colormix_col3 = "0x08FE8019";
# Box appearance
#border_fg = "0x00FFFFFF";
blank_box = true;
box_title = "tomasr@nixos";
#margin_box_h = 2;
#margin_box_v = 1;
#text_in_center = false;
# Animation: Conways Game of Life (optional, comment out for minimal setup)
gameoflife_fg = "0x40FFFFFF";
gameoflife_frame_delay = 3;
gameoflife_entropy_interval = 10;
gameoflife_initial_density = 0.666;
# Optional commands (leave null or comment if unused)
hibernate_cmd = null;
inactivity_cmd = null;
login_cmd = "start-hyprland";
#logout_cmd = null;
sleep_cmd = null;
# System commands keys
shutdown_cmd = "/sbin/shutdown $PLATFORM_SHUTDOWN_ARG now";
shutdown_key = "F1";
restart_key = "F2";
sleep_key = "F3";
hibernate_key = "F4";
# top bar
session_log = null;
initial_info_text = null; #
# Custom sessions
#custom_sessions = "$CONFIG_DIRECTORY/ly/custom-sessions";
#waylandsessions = "$PREFIX_DIRECTORY/share/wayland-sessions";
#xsessions = "$PREFIX_DIRECTORY/share/xsessions";
# Xorg settings (only needed if using X)
#x_cmd = "$PREFIX_DIRECTORY/bin/X";
#x_vt = null;
#xauth_cmd = "$PREFIX_DIRECTORY/bin/xauth";
#xinitrc = "~/.xinitrc";
# Setup / startup scripts
#setup_cmd = "$CONFIG_DIRECTORY/ly/setup.sh";
#start_cmd = "$CONFIG_DIRECTORY/ly/startup.sh";
};
};
}
-7
View File
@@ -1,7 +0,0 @@
# see also ../home-manager/mullvad.nix
{pkgs-unstable, ...}: {
services.mullvad-vpn = {
enable = true;
package = pkgs-unstable.mullvad-vpn;
};
}
-34
View File
@@ -1,34 +0,0 @@
# some options are in ../../hostsModules/laptop/nixos/nixUtils.nix
{
pkgs-unstable,
inputs,
...
}: {
# Garbage collector of generations
nix.gc = {
automatic = true;
dates = "weekly";
options = "--delete-older-than 7d"; # every week delete generations older than a month
};
#manix is unhappy without this
nix.nixPath = [
"nixpkgs=${inputs.nixpkgs.outPath}"
"home-manager=${inputs.home-manager.outPath}"
];
#adds nixos experimental features:
nix.settings.experimental-features = ["nix-command" "flakes"];
environment.systemPackages = with pkgs-unstable; [
nixpkgs-review
nixfmt-tree
treefmt
nixd
deadnix
alejandra
vimPluginsUpdater # used for building plugins
nix-index
statix
];
}
-15
View File
@@ -1,15 +0,0 @@
# notifications server is set by caelestia-shell. See ../home-manager/caelestia.nix
{pkgs, ...}: {
environment.systemPackages = with pkgs; [
libnotify # Library that sends desktop notifications to a notification daemon
socat # Utility for bidirectional data transfer between two independent data channels (used to communicate between hyprland and swww to change wallpapers dinamically)
matrix-commander-rs # matrix client used to send notifications from scripts to my phone
# battery notifications
(pkgs.callPackage ../../hostsModules/laptop/scripts/batterynotify.nix {})
(pkgs.callPackage ../../hostsModules/laptop/scripts/batterywarning.nix {})
# checks if matrix-commander-rs is installed and logged in
(pkgs.callPackage ../../hostsModules/laptop/scripts/checkMatrix.nix {})
(pkgs.callPackage ../../modules/scripts/gitnotify.nix {}) # check if git is set up
(pkgs.callPackage ../../modules/scripts/checkKdrive.nix {}) # check if kdrive is set up with rclone
];
}
-6
View File
@@ -1,6 +0,0 @@
{pkgs, ...}: {
environment.systemPackages = with pkgs; [
libreoffice
birdtray
];
}
-28
View File
@@ -1,28 +0,0 @@
# try to keep packages here at a minium. Preferably use a dedicated file
{
pkgs,
pkgs-unstable,
...
}: {
environment.systemPackages = with pkgs; [
gnome-calculator
snapshot
gnome-characters
#tree # shows dir in tree # we use eza now
brightnessctl # control brightness
powertop
fzf
bottom # Cross-platform graphical process/system monitor with a customizable interface
tomato-c # pomodoro timer
#hyprshot
mailcap
fuzzel
usbutils # used for lsusb
(pkgs.callPackage ../../modules/scripts/dontkillsteam.nix {}) # kill app (if it is steam put it in some background
(pkgs.callPackage ../../modules/scripts/killall.nix {}) # kill all windows except focused window
(pkgs.callPackage ../../modules/scripts/tomato.nix {})
(pkgs.callPackage ../../modules/scripts/syllabes.nix {}) # python script to get number of syllabes in french
pkgs-unstable.bitwarden-desktop
fluffychat # matrix client
];
}
-39
View File
@@ -1,39 +0,0 @@
{pkgs, ...}: {
#https://wiki.nixos.org/wiki/Printing
services.avahi = {
enable = true;
nssmdns4 = true;
openFirewall = true;
};
# Enable CUPS to print documents.
services.printing = {
enable = true;
drivers = with pkgs; [
cups-filters
#cups-browsed
#gutenprint
#gutenprintBin
hplipWithPlugin
hplip
];
};
services.ipp-usb.enable = true;
environment.systemPackages = with pkgs; [
kdePackages.print-manager
ghostscript
hplipWithPlugin
];
hardware.printers = {
ensurePrinters = [
{
name = "HP_OfficeJet_Pro_7740";
location = "Home";
deviceUri = "hp:/usb/OfficeJet_Pro_7740_series";
model = "drv:///hp/hpcups.drv/hp-officejet_pro_7740_series.ppd";
}
];
ensureDefaultPrinter = "HP_OfficeJet_Pro_7740";
};
}
-22
View File
@@ -1,22 +0,0 @@
# most of the themeing are in the home-manager modules. This just installs some packages needed
{pkgs, ...}: {
qt.enable = true;
# to resolve this https://wiki.nixos.org/wiki/Home_Manager#I_cannot_set_GNOME_or_Gtk_themes_via_Home_Manager
programs.dconf.enable = true;
environment.systemPackages = with pkgs; [
swww #wallpaper daemon
gruvbox-gtk-theme
hyprcursor
capitaine-cursors-themed # cursor theme
kdePackages.qtdeclarative # provides qmlls and other things
quickshell # we have it but adding it there solves "WARN qt.qpa.services: Failed to register with host portal QDBusError("org.freedesktop.portal.Error.Failed", "Could not register app ID: App info not found for 'org.quickshell'")"
papirus-icon-theme
papirus-folders
(pkgs.callPackage ../../modules/scripts/wallpaper.nix {})
#(pkgs.callPackage ../../modules/scripts/colorpicker.nix {}) # old color picker
#(pkgs.callPackage ../../modules/scripts/weather.nix {}) # old cli weather
(pkgs.callPackage ../../hostsModules/laptop/qt/qtbatticon.nix {}) # custom qt tray icon for battery
];
}
-63
View File
@@ -1,63 +0,0 @@
{
pkgs,
pkgs-unstable,
inputs,
...
}: {
services.dbus.enable = true;
security.polkit.enable = true;
home-manager = {
useGlobalPkgs = true;
useUserPackages = true;
# the home manager config is set in ../../hostsModules/*/nixos/user.nix
extraSpecialArgs = {inherit inputs pkgs-unstable;};
};
# Set your time zone.
time.timeZone = "Europe/Zurich";
# Select internationalisation properties.
i18n.defaultLocale = "en_US.UTF-8";
# zsh dont want to work if it is not initialzed here.
programs.zsh.enable = true;
# Define a user account. Don't forget to set a password with passwd.
users.users.tomasr = {
isNormalUser = true;
description = "Tomas Rivera";
extraGroups = ["networkmanager" "wheel" "fuse"]; #wheel allow to use sudo / fuse -> rclone
shell = pkgs.zsh;
};
security.wrappers.gsr-kms-server = {
# to remove the password prompt when using gpu-screen-recorder
owner = "root";
group = "root";
capabilities = "cap_sys_admin+ep";
source = "${pkgs.gpu-screen-recorder}/bin/gsr-kms-server";
};
services.upower.enable = true;
# removes need for password for nixos-rebuild
security.sudo.extraRules = [
{
users = ["tomasr"];
commands = [
{
command = "/run/current-system/sw/bin/nixos-rebuild";
options = ["NOPASSWD"];
}
{
command = "${pkgs.nixos-rebuild}/bin/nixos-rebuild";
options = ["NOPASSWD"];
}
{
command = "${pkgs-unstable.nixos-rebuild}/bin/nixos-rebuild";
options = ["NOPASSWD"];
}
];
}
];
}

Some files were not shown because too many files have changed in this diff Show More