mirror of
https://github.com/tomasriveral/nixos.git
synced 2026-10-12 17:30:55 +02:00
Compare commits
29
Commits
f745a79af8
..
main
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
3ac5aaa396 | ||
|
|
21349e4585 | ||
|
|
1a19380962 | ||
|
|
f23ec09369 | ||
|
|
7d5ae9fa2c | ||
|
|
8f4117f3e7 | ||
|
|
bd97ba4df7 | ||
|
|
bd678ae32d | ||
|
|
3a51d3c14a | ||
|
|
9879131aca | ||
|
|
c2f733d4c9 | ||
|
|
44709a3b7c | ||
|
|
ce8c4f7d73 | ||
|
|
2f2d3cd2ba | ||
|
|
b738cbb8ef | ||
|
|
fdb4d53ec0 | ||
|
|
1a29fda1f9 | ||
|
|
bc5f00cf1d | ||
|
|
b760904557 | ||
|
|
28d56cf671 | ||
|
|
4db1f329f2 | ||
|
|
7afe2cf7b6 | ||
|
|
434e6ed31d | ||
|
|
f1e266331c | ||
|
|
98bc46e67f | ||
|
|
07c2293f77 | ||
|
|
7f74878433 | ||
|
|
c235a0a724 | ||
|
|
3fc66623f2 |
No files matched your search
@@ -430,7 +430,6 @@ The macros in the layout generate combinations involving `CTRL`, `ALT`, `SUPER`,
|
||||
| Row 2, Col 2 | Change audio output (`CTRL + ALT + SHIFT + 0`) |
|
||||
| Row 2, Col 3 | Special characters (`CTRL + SUPER + 5`) |
|
||||
| Row 2, Col 4 | Color picker (`CTRL + ALT + 8`) |
|
||||
| Row 3, Col 1 | Pomodoro timer (`CTRL + ALT + 0`) |
|
||||
| Row 4, Col 1 | Launch Anki (`CTRL + ALT + 9`) |
|
||||
|
||||
The physical layout file contains additional transparent/unused positions, but the bindings above are the active shortcuts documented for the macropad.
|
||||
|
||||
@@ -64,12 +64,15 @@
|
||||
flake = let
|
||||
system = "x86_64-linux";
|
||||
unfreePkgs = [
|
||||
"code"
|
||||
"hplip"
|
||||
"nvidia-x11"
|
||||
"nvidia-settings"
|
||||
"steam"
|
||||
"steam-unwrapped"
|
||||
"cheatsheet.nvim"
|
||||
"vscode"
|
||||
"vscode-fhs"
|
||||
"zoom-us"
|
||||
"zoom"
|
||||
];
|
||||
|
||||
@@ -402,6 +402,24 @@
|
||||
keyword = "nix function search";
|
||||
url = "https://noogle.dev";
|
||||
}
|
||||
{
|
||||
name = "EPFL Moodle";
|
||||
tags = ["epfl" "moodle"];
|
||||
keyword = "epfl moodle";
|
||||
url = "https://moodle.epfl.ch/my/courses.php";
|
||||
}
|
||||
{
|
||||
name = "EPFL ICC Courseware";
|
||||
tags = ["icc" "epfl" "courseware"];
|
||||
keyword = "icc epfl courseware";
|
||||
url = "https://courseware.epfl.ch/learner-dashboard/";
|
||||
}
|
||||
{
|
||||
name = "Detexify";
|
||||
tags = ["draw" "Latex" "symbols"];
|
||||
keyword = "draw latex symbols";
|
||||
url = "https://detexify.kirelabs.org/";
|
||||
}
|
||||
];
|
||||
};
|
||||
search = {
|
||||
|
||||
@@ -24,16 +24,16 @@
|
||||
inhibitWhenAudio = true;
|
||||
timeouts = [
|
||||
{
|
||||
timeout = 180;
|
||||
timeout = 1000;
|
||||
idleAction = "lock";
|
||||
}
|
||||
{
|
||||
timeout = 300;
|
||||
timeout = 1010;
|
||||
idleAction = "dpms off"; # what's that?
|
||||
returnAction = "dpms on";
|
||||
}
|
||||
{
|
||||
timeout = 600;
|
||||
timeout = 12200;
|
||||
idleAction = ["systemctl" "suspend-then-hibernate"];
|
||||
}
|
||||
];
|
||||
|
||||
@@ -35,23 +35,22 @@ _: {
|
||||
services.xserver.enable = true;
|
||||
};
|
||||
flake.homeModules.hyprland-laptop = {
|
||||
home.file.".config/hypr/host.lua" = {
|
||||
text = ''
|
||||
hl.on("hyprland.start", function()
|
||||
hl.exec_cmd("qtbatticon")
|
||||
hl.exec_cmd("source /run/agenix/ntfy && nixpkgs-notifier listen")
|
||||
end)
|
||||
|
||||
hl.monitor({
|
||||
output = "eDP-1",
|
||||
mode = "highres@highrr",
|
||||
position = "0x0",
|
||||
scale = 1,
|
||||
})
|
||||
'';
|
||||
enable = true;
|
||||
force = true;
|
||||
};
|
||||
home.file.".config/hypr/host.lua" = {
|
||||
text = ''
|
||||
hl.on("hyprland.start", function()
|
||||
hl.exec_cmd("qtbatticon")
|
||||
end)
|
||||
|
||||
hl.monitor({
|
||||
output = "eDP-1",
|
||||
mode = "highres@highrr",
|
||||
position = "0x0",
|
||||
scale = 1,
|
||||
})
|
||||
'';
|
||||
enable = true;
|
||||
force = true;
|
||||
};
|
||||
};
|
||||
flake.homeModules.hyprland-desktop = {
|
||||
home.file.".config/hypr/host.lua" = {
|
||||
|
||||
@@ -8,7 +8,7 @@
|
||||
force = true;
|
||||
text = ''
|
||||
{
|
||||
"directory": ["~/kdrive/Notes/"],
|
||||
"directory": ["~/Documents/Notes/"],
|
||||
"render": true,
|
||||
"jumpToEndOfFileOnLaunch": true,
|
||||
"editor": "neovim",
|
||||
@@ -18,7 +18,7 @@
|
||||
"backup": {
|
||||
"enable": true,
|
||||
"directory": {
|
||||
"~/kdrive/Notes/": "~/kdrive/Notes/"
|
||||
"~/Documents/Notes/": "~/kdrive/Notes/"
|
||||
},
|
||||
"interval": "daily",
|
||||
"rsyncArgs": ["-Lqah", "--update"],
|
||||
|
||||
@@ -43,6 +43,11 @@ _: {
|
||||
enable = true;
|
||||
autosuggestion.enable = false; # zsh-autocomplete is replaced by deja
|
||||
initContent = ''
|
||||
# those aliases can't be written in nix, because of ö
|
||||
# l and ö are very close
|
||||
alias -- ös=ls
|
||||
alias -- öös=ls
|
||||
|
||||
# Safe cat that uses colorize plugin ccat
|
||||
custom-cat() {
|
||||
if [[ -t 1 ]]; then
|
||||
@@ -61,7 +66,11 @@ _: {
|
||||
}
|
||||
eval "$(direnv hook zsh)"
|
||||
eval "$(deja init zsh)"
|
||||
fastfetch''\n'';
|
||||
if [[ "$TERM_PROGRAM" != "vscode" ]]; then
|
||||
fastfetch
|
||||
fi
|
||||
|
||||
'';
|
||||
shellAliases = {
|
||||
".." = "z ..";
|
||||
grep = "rg";
|
||||
|
||||
@@ -11,6 +11,7 @@ _: {
|
||||
})
|
||||
syswatch
|
||||
];
|
||||
services.fwupd.enable = true; # update device firmware
|
||||
};
|
||||
flake.nixosModules.hardwareUtils-desktop = {pkgs-unstable, ...}: {
|
||||
environment.systemPackages = with pkgs-unstable; [
|
||||
@@ -20,5 +21,6 @@ _: {
|
||||
})
|
||||
syswatch
|
||||
];
|
||||
services.fwupd.enable = true; # update device firmware
|
||||
};
|
||||
}
|
||||
@@ -23,6 +23,7 @@
|
||||
bootloader
|
||||
browsers
|
||||
caelestia
|
||||
cs-119l # I'm obliged to use vscode. RIP neovim
|
||||
development
|
||||
documentation
|
||||
disk
|
||||
|
||||
@@ -4,8 +4,8 @@
|
||||
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 awww to change wallpapers dinamically)
|
||||
# battery notifications
|
||||
self.packages.${pkgs.system}.custom-batterynotify
|
||||
self.packages.${pkgs.system}.custom-batterywarning
|
||||
/*self.packages.${pkgs.system}.custom-batterynotify
|
||||
self.packages.${pkgs.system}.custom-batterywarning*/
|
||||
self.packages.${pkgs.system}.custom-gitnotify # checks if git is set up
|
||||
self.packages.${pkgs.system}.custom-checkKdrive # check if kdrive is set up with rclone
|
||||
zoom-us
|
||||
|
||||
@@ -1,7 +1,65 @@
|
||||
_: {
|
||||
{self, ...}: {
|
||||
flake.nixosModules.epfl = {pkgs, ...}: {
|
||||
environment.systemPackages = with pkgs; [
|
||||
openconnect
|
||||
self.packages.${pkgs.system}.custom-mountEpflDrive
|
||||
];
|
||||
};
|
||||
|
||||
flake.nixosModules.cs-119l = {pkgs, ...}: let
|
||||
user = "tomasr";
|
||||
home = "/home/${user}";
|
||||
src = "${home}/epfl/cs-119l-ICC/";
|
||||
dst = "${home}/kdrive/Travail/2 - Bachelor/BA1/Information, calcul, communication CS-119l/code/";
|
||||
in {
|
||||
environment.systemPackages = with pkgs; [
|
||||
vscode-fhs
|
||||
];
|
||||
systemd.services.sync-cs119l-to-kdrive = {
|
||||
description = "Sync CS-119l ICC to kDrive";
|
||||
|
||||
serviceConfig = {
|
||||
Type = "oneshot";
|
||||
User = user;
|
||||
|
||||
ExecStart = "${pkgs.rsync}/bin/rsync -a '${src}' '${dst}'";
|
||||
};
|
||||
};
|
||||
|
||||
systemd.timers.sync-cs119l-to-kdrive = {
|
||||
description = "Sync CS-119l ICC to kDrive every Thursday and Friday evening";
|
||||
|
||||
wantedBy = ["timers.target"];
|
||||
|
||||
timerConfig = {
|
||||
OnCalendar = [
|
||||
"Thu *-*-* 20:00:00"
|
||||
"Fri *-*-* 20:00:00"
|
||||
];
|
||||
Persistent = true;
|
||||
};
|
||||
};
|
||||
};
|
||||
perSystem = {pkgs, ...}: {
|
||||
packages.custom-mountEpflDrive = pkgs.writeShellApplication {
|
||||
name = "custom-mountEpflDrive";
|
||||
runtimeInputs = with pkgs; [
|
||||
rclone
|
||||
libnotify
|
||||
];
|
||||
text = ''
|
||||
REMOTE_NAME="epfl"
|
||||
MOUNT_POINT="$HOME/epfl/drive"
|
||||
|
||||
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 ~/epfl/drive/ or comment out the exec line in hyprland.lua."
|
||||
echo "Remote ''${REMOTE_NAME} not found. Configure rclone or comment out the exec line in hyprland.lua."
|
||||
fi
|
||||
'';
|
||||
};
|
||||
};
|
||||
}
|
||||
@@ -45,6 +45,7 @@
|
||||
nix-index
|
||||
statix
|
||||
self.packages.${pkgs-unstable.system}.custom-trimmer
|
||||
nix-update # nix-update <package> --build --test --format # the review will be done by nixpkgs-review-gha
|
||||
];
|
||||
};
|
||||
perSystem = {pkgs, ...}: {
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
{self, ...}: {
|
||||
flake.nixosModules.otherUtils =
|
||||
# try to keep packages here at a minium. Preferably use a dedicated file
|
||||
{pkgs, ...}: {
|
||||
{pkgs, pkgs-unstable, ...}: {
|
||||
environment.systemPackages = with pkgs; [
|
||||
gnome-calculator
|
||||
snapshot
|
||||
@@ -18,8 +18,7 @@
|
||||
usbutils # used for lsusb
|
||||
self.packages.${pkgs.system}.custom-tomato
|
||||
self.packages.${pkgs.system}.custom-syllabes
|
||||
# Electron 39 EOL. https://github.com/bitwarden/clients/pull/20448 should move it to 41. For the moment use the browser extension
|
||||
#pkgs-unstable.bitwarden-desktop
|
||||
pkgs-unstable.bitwarden-desktop
|
||||
fluffychat # matrix client
|
||||
];
|
||||
};
|
||||
|
||||
@@ -322,7 +322,7 @@ hl.bind(mod .. " + CTRL + 3", hl.dsp.exec_cmd("pavucontrol"))
|
||||
hl.bind("CTRL + SHIFT + ALT + 0", hl.dsp.exec_cmd("kitty --hold --class \"custom-changeAudioOutput\" --name \"Select audio output\" zsh -c \"custom-changeAudioOutput\""))
|
||||
hl.bind(mod .. " + CTRL + 5", hl.dsp.exec_cmd("gnome-characters"))
|
||||
hl.bind("CTRL + ALT + 8", hl.dsp.exec_cmd("hyprpicker | tee >(wl-copy) | cliphist store"))
|
||||
hl.bind("CTRL + ALT + 0", hl.dsp.exec_cmd("custom-tomato"))
|
||||
-- hl.bind("CTRL + ALT + 0", hl.dsp.exec_cmd("custom-tomato"))
|
||||
hl.bind("CTRL + ALT + 2", hl.dsp.exec_cmd("custom-bottom"))
|
||||
hl.bind("CTRL + ALT + 9", hl.dsp.exec_cmd("anki"))
|
||||
|
||||
@@ -926,7 +926,6 @@ hl.config({
|
||||
|
||||
hl.on("hyprland.start", function()
|
||||
hl.exec_cmd("/nix/store/8kih8alkk4qzgjchg5501r1c3a8a71aw-dbus-1.16.2/bin/dbus-update-activation-environment --systemd DISPLAY HYPRLAND_INSTANCE_SIGNATURE WAYLAND_DISPLAY XDG_CURRENT_DESKTOP XDG_SESSION_TYPE && systemctl --user stop hyprland-session.target && systemctl --user start hyprland-session.target")
|
||||
hl.exec_cmd("qtbatticon")
|
||||
hl.exec_cmd("source /run/agenix/ntfy && nixpkgs-notifier listen")
|
||||
hl.exec_cmd("dbus-update-activation-environment --systemd WAYLAND_DISPLAY XDG_CURRENT_DESKTOP")
|
||||
hl.exec_cmd("dbus-update-activation-environment --systemd --all")
|
||||
@@ -936,11 +935,12 @@ hl.on("hyprland.start", function()
|
||||
hl.exec_cmd("udiskie --no-automount --smart-tray")
|
||||
hl.exec_cmd("nm-applet --indicator")
|
||||
hl.exec_cmd("rm -rf ~/.cache/cliphist/ && wl-paste --type text --watch cliphist store & wl-paste --type image --watch cliphist store")
|
||||
hl.exec_cmd("custom-batterynotify")
|
||||
hl.exec_cmd("custom-batterywarning")
|
||||
-- hl.exec_cmd("custom-batterynotify")
|
||||
-- hl.exec_cmd("custom-batterywarning")
|
||||
hl.exec_cmd("awww img WALLPAPER/PATH/PLACEHOLDER")
|
||||
hl.exec_cmd("awww-daemon")
|
||||
hl.exec_cmd("custom-checkKdrive && custom-mountkdrive")
|
||||
hl.exec_cmd("custom-mountEpflDrive")
|
||||
hl.exec_cmd("custom-gitnotify")
|
||||
hl.exec_cmd("sleep 4 & caelestia-shell")
|
||||
hl.exec_cmd("sleep 20 && ngcp pull --automatic")
|
||||
|
||||
Reference in new issue
Block a user