Compare commits

...

21 commits

Author SHA1 Message Date
e8b83724ca Update rust treesitter grammar for helix 2024-04-27 12:13:43 +02:00
0b1c7bce55 disable firewall for strawberry 2024-04-27 11:11:45 +02:00
1d5a7e0804 Fix strawberry issues (add steam, update pins, switch to pulse) 2023-12-23 18:01:36 +01:00
ca5ee9ed20 Fix swaylock on work machine 2023-12-22 12:26:06 +01:00
78abfc12eb Merge branch 'mistress' of im.badat.dev:riley/os into mistress 2023-12-22 12:25:00 +01:00
504df67a2c Enable steam and bluetooth on lime 2023-11-10 18:45:01 +01:00
3107449982 Change waybar styles 2023-09-21 20:38:50 +02:00
f6a3d89a8a Update nixpkgs 2023-09-21 17:38:37 +02:00
616d74641b Change wallpaper 2023-09-21 18:07:31 +02:00
a61c8fc8fb Clean /tmp on boot 2023-09-03 13:11:37 +02:00
4fd6205b88 Add deemix + config 2023-09-02 23:26:09 +02:00
2858ec8363 Add user packages 2023-08-29 15:32:56 +02:00
721ab25e11 Add yeet script 2023-08-23 10:03:13 +02:00
95431378af Override nixpkgs version for security-critical applications 2023-08-13 10:22:51 +02:00
f7455b059e Revert "Update pins"
This reverts commit dcac16d9c9.
2023-08-13 09:55:11 +02:00
dcac16d9c9 Update pins 2023-08-12 20:31:01 +02:00
978fc8186d Add utils dev shell 2023-07-06 11:57:44 +02:00
666a75f844 Add keybinds for volume and fix eval on dev-lt-63 2023-06-28 13:29:23 +02:00
8e7233cc43 Enable Docker 2023-06-24 10:08:48 +02:00
c69e5c07be Add rust toolchain 2023-06-19 22:14:22 +02:00
2083556fad Allow aarch64 emulation on lime 2023-06-19 21:46:55 +02:00
30 changed files with 427 additions and 138 deletions

View file

@ -7,11 +7,11 @@
"nixpkgs": "nixpkgs"
},
"locked": {
"lastModified": 1684153753,
"narHash": "sha256-PVbWt3qrjYAK+T5KplFcO+h7aZWfEj1UtyoKlvcDxh0=",
"lastModified": 1703260116,
"narHash": "sha256-ipqShkBmHKC9ft1ZAsA6aeKps32k7+XZSPwfxeHLsAU=",
"owner": "ryantm",
"repo": "agenix",
"rev": "db5637d10f797bb251b94ef9040b237f4702cde3",
"rev": "d0d4ad5be611da43da04321f49684ad72d705c7e",
"type": "github"
},
"original": {
@ -20,6 +20,27 @@
"type": "github"
}
},
"crane": {
"inputs": {
"nixpkgs": [
"helix",
"nixpkgs"
]
},
"locked": {
"lastModified": 1709610799,
"narHash": "sha256-5jfLQx0U9hXbi2skYMGodDJkIgffrjIOgMRjZqms2QE=",
"owner": "ipetkov",
"repo": "crane",
"rev": "81c393c776d5379c030607866afef6406ca1be57",
"type": "github"
},
"original": {
"owner": "ipetkov",
"repo": "crane",
"type": "github"
}
},
"darwin": {
"inputs": {
"nixpkgs": [
@ -43,6 +64,42 @@
}
},
"flake-utils": {
"inputs": {
"systems": "systems"
},
"locked": {
"lastModified": 1709126324,
"narHash": "sha256-q6EQdSeUZOG26WelxqkmR7kArjgWCdw5sfJVHPH/7j8=",
"owner": "numtide",
"repo": "flake-utils",
"rev": "d465f4819400de7c8d874d50b982301f28a84605",
"type": "github"
},
"original": {
"owner": "numtide",
"repo": "flake-utils",
"type": "github"
}
},
"flake-utils_2": {
"inputs": {
"systems": "systems_2"
},
"locked": {
"lastModified": 1681202837,
"narHash": "sha256-H+Rh19JDwRtpVPAWp64F+rlEtxUWBAQW28eAi3SRSzg=",
"owner": "numtide",
"repo": "flake-utils",
"rev": "cfacdce06f30d2b68473a46042957675eebb3401",
"type": "github"
},
"original": {
"owner": "numtide",
"repo": "flake-utils",
"type": "github"
}
},
"flake-utils_3": {
"locked": {
"lastModified": 1667395993,
"narHash": "sha256-nuEHfE/LcWyuSWnS8t12N1wc105Qtau+/OdUAjtQ0rA=",
@ -57,6 +114,27 @@
"type": "github"
}
},
"helix": {
"inputs": {
"crane": "crane",
"flake-utils": "flake-utils",
"nixpkgs": "nixpkgs_2",
"rust-overlay": "rust-overlay"
},
"locked": {
"lastModified": 1714168229,
"narHash": "sha256-EzNJ7L1XgqSIo3myFl/dFVqm6BXa8oV9qzSJpMBGYWU=",
"owner": "helix-editor",
"repo": "helix",
"rev": "5ee7411450021df3854b62f61b8722451e40277c",
"type": "github"
},
"original": {
"owner": "helix-editor",
"repo": "helix",
"type": "github"
}
},
"home-manager": {
"inputs": {
"nixpkgs": [
@ -80,14 +158,14 @@
},
"home-manager_2": {
"inputs": {
"nixpkgs": "nixpkgs_2"
"nixpkgs": "nixpkgs_3"
},
"locked": {
"lastModified": 1686922395,
"narHash": "sha256-ysevinohPxdKp0RXyhDRsz1/vh1eXazg4AWp0n5X/U4=",
"lastModified": 1703265279,
"narHash": "sha256-5jVtOwyMH1FzclxHrsFWzBdB+VyjUUSu1wyZhZlR6WU=",
"owner": "nix-community",
"repo": "home-manager",
"rev": "9ba7b3990eb1f4782ea3f5fe7ac4f3c88dd7a32c",
"rev": "07c322a7cff03267fd881adae1afe63367c5d608",
"type": "github"
},
"original": {
@ -114,11 +192,11 @@
},
"nixos-hardware": {
"locked": {
"lastModified": 1686838567,
"narHash": "sha256-aqKCUD126dRlVSKV6vWuDCitfjFrZlkwNuvj5LtjRRU=",
"lastModified": 1702453208,
"narHash": "sha256-0wRi9SposfE2wHqjuKt8WO2izKB/ASDOV91URunIqgo=",
"owner": "NixOS",
"repo": "nixos-hardware",
"rev": "429f232fe1dc398c5afea19a51aad6931ee0fb89",
"rev": "7763c6fd1f299cb9361ff2abf755ed9619ef01d6",
"type": "github"
},
"original": {
@ -143,13 +221,29 @@
"type": "github"
}
},
"nixpkgs-latest": {
"locked": {
"lastModified": 1703013332,
"narHash": "sha256-+tFNwMvlXLbJZXiMHqYq77z/RfmpfpiI3yjL6o/Zo9M=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "54aac082a4d9bb5bbc5c4e899603abfb76a3f6d6",
"type": "github"
},
"original": {
"owner": "NixOS",
"ref": "nixos-unstable",
"repo": "nixpkgs",
"type": "github"
}
},
"nixpkgs_2": {
"locked": {
"lastModified": 1686501370,
"narHash": "sha256-G0WuM9fqTPRc2URKP9Lgi5nhZMqsfHGrdEbrLvAPJcg=",
"lastModified": 1709479366,
"narHash": "sha256-n6F0n8UV6lnTZbYPl1A9q1BS0p4hduAv1mGAP17CVd0=",
"owner": "nixos",
"repo": "nixpkgs",
"rev": "75a5ebf473cd60148ba9aec0d219f72e5cf52519",
"rev": "b8697e57f10292a6165a20f03d2f42920dfaf973",
"type": "github"
},
"original": {
@ -161,11 +255,11 @@
},
"nixpkgs_3": {
"locked": {
"lastModified": 1686869522,
"narHash": "sha256-tbJ9B8WLCTnVP/LwESRlg0dII6Zyg2LmUU/mB9Lu98E=",
"lastModified": 1702312524,
"narHash": "sha256-gkZJRDBUCpTPBvQk25G0B7vfbpEYM5s5OZqghkjZsnE=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "7c67f006ea0e7d0265f16d7df07cc076fdffd91f",
"rev": "a9bf124c46ef298113270b1f84a164865987a91c",
"type": "github"
},
"original": {
@ -175,9 +269,60 @@
"type": "github"
}
},
"nixpkgs_4": {
"locked": {
"lastModified": 1703013332,
"narHash": "sha256-+tFNwMvlXLbJZXiMHqYq77z/RfmpfpiI3yjL6o/Zo9M=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "54aac082a4d9bb5bbc5c4e899603abfb76a3f6d6",
"type": "github"
},
"original": {
"owner": "NixOS",
"ref": "nixos-unstable",
"repo": "nixpkgs",
"type": "github"
}
},
"nixpkgs_5": {
"locked": {
"lastModified": 1681358109,
"narHash": "sha256-eKyxW4OohHQx9Urxi7TQlFBTDWII+F+x2hklDOQPB50=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "96ba1c52e54e74c3197f4d43026b3f3d92e83ff9",
"type": "github"
},
"original": {
"owner": "NixOS",
"ref": "nixpkgs-unstable",
"repo": "nixpkgs",
"type": "github"
}
},
"oxalica": {
"inputs": {
"flake-utils": "flake-utils_2",
"nixpkgs": "nixpkgs_5"
},
"locked": {
"lastModified": 1703297543,
"narHash": "sha256-d4QlzcoSNzb/iZheWtjOyRxoBSaLETSpViENGEkxv9g=",
"owner": "oxalica",
"repo": "rust-overlay",
"rev": "fc77c8b416b1537522d30c710baaaaebf769f816",
"type": "github"
},
"original": {
"owner": "oxalica",
"repo": "rust-overlay",
"type": "github"
}
},
"pwnix": {
"inputs": {
"flake-utils": "flake-utils",
"flake-utils": "flake-utils_3",
"jwt-tool": "jwt-tool",
"nixpkgs": [
"nixpkgs"
@ -217,11 +362,69 @@
"root": {
"inputs": {
"agenix": "agenix",
"helix": "helix",
"home-manager": "home-manager_2",
"nixos-hardware": "nixos-hardware",
"nixpkgs": "nixpkgs_3",
"nixpkgs": "nixpkgs_4",
"nixpkgs-latest": "nixpkgs-latest",
"oxalica": "oxalica",
"pwnix": "pwnix"
}
},
"rust-overlay": {
"inputs": {
"flake-utils": [
"helix",
"flake-utils"
],
"nixpkgs": [
"helix",
"nixpkgs"
]
},
"locked": {
"lastModified": 1709604635,
"narHash": "sha256-le4fwmWmjGRYWwkho0Gr7mnnZndOOe4XGbLw68OvF40=",
"owner": "oxalica",
"repo": "rust-overlay",
"rev": "e86c0fb5d3a22a5f30d7f64ecad88643fe26449d",
"type": "github"
},
"original": {
"owner": "oxalica",
"repo": "rust-overlay",
"type": "github"
}
},
"systems": {
"locked": {
"lastModified": 1681028828,
"narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=",
"owner": "nix-systems",
"repo": "default",
"rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e",
"type": "github"
},
"original": {
"owner": "nix-systems",
"repo": "default",
"type": "github"
}
},
"systems_2": {
"locked": {
"lastModified": 1681028828,
"narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=",
"owner": "nix-systems",
"repo": "default",
"rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e",
"type": "github"
},
"original": {
"owner": "nix-systems",
"repo": "default",
"type": "github"
}
}
},
"root": "root",

View file

@ -1,7 +1,8 @@
{
inputs = {
nixpkgs.url = github:NixOS/nixpkgs/nixos-unstable;
nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable";
nixpkgs-latest.url = github:NixOS/nixpkgs/nixos-unstable;
home-manager.url = github:nix-community/home-manager;
pwnix = {
inputs.nixpkgs.follows = "nixpkgs";
@ -9,16 +10,20 @@
};
agenix.url = github:ryantm/agenix;
nixos-hardware.url = github:NixOS/nixos-hardware;
oxalica.url = github:oxalica/rust-overlay;
helix.url = "github:helix-editor/helix";
};
outputs = args@{ home-manager, nixpkgs, agenix, nixos-hardware, ... }: with nixpkgs; {
outputs = args@{ home-manager, nixpkgs, agenix, nixos-hardware, oxalica, ... }: with nixpkgs; rec {
# Configurations for NixOS machines.
nixosConfigurations =
let mkUserConfig = path: {
let mkUserConfig = path: { config, ... }: {
imports = [ home-manager.nixosModules.home-manager ];
config = {
home-manager.users."riley" = (import "${path}/home.nix");
home-manager.extraSpecialArgs = args // { age = config.age; };
home-manager.useGlobalPkgs = true;
};
};
in {
@ -42,8 +47,6 @@
modules = [
(mkUserConfig ./system/lime)
agenix.nixosModules.default
nixos-hardware.nixosModules.lenovo-thinkpad-x390
nixos-hardware.nixosModules.common-gpu-nvidia-disable
./system/lime/core.nix
./shared/core
./shared/secrets.nix
@ -64,8 +67,10 @@
# Configurations for non-NixOS machines.
homeConfigurations = with home-manager.lib; {
"dev-lt-63" = homeManagerConfiguration {
pkgs = nixpkgs.legacyPackages."x86_64-linux";
extraSpecialArgs = args;
pkgs = import nixpkgs { system = "x86_64-linux"; };
modules = [
agenix.homeManagerModules.default
./system/dev-lt-63/home.nix
./shared/home
];
@ -73,7 +78,13 @@
};
overlays = {
default = (import ./shared/overlay.nix);
default = (import ./shared/overlay.nix args.helix);
};
devShells."x86_64-linux"."utils" = let
pkgs = import nixpkgs { system = "x86_64-linux"; };
in pkgs.mkShell {
buildInputs = import ./shared/env.nix pkgs;
};
};

1
script/yeet Normal file
View file

@ -0,0 +1 @@
curl https://ttm.sh -F "file=@$1" | c

BIN
secret/arl.age Normal file

Binary file not shown.

Binary file not shown.

View file

@ -13,4 +13,6 @@ let strawberry = [
in {
# Secrets for backup cloud storage provider
"secret/backblaze.age".publicKeys = all;
# The ARL for my deezer account
"secret/arl.age".publicKeys = all;
}

View file

@ -5,6 +5,7 @@
imports = [
./services.nix
./backups.nix
./docker.nix
./users.nix
./gui.nix
./nix.nix
@ -12,6 +13,7 @@
config = {
time.timeZone = "Europe/Amsterdam";
boot.tmp.cleanOnBoot = true;
environment.systemPackages = (import ../env.nix pkgs) ++ (with pkgs; [
# For Mae
neovim

11
shared/core/docker.nix Normal file
View file

@ -0,0 +1,11 @@
{ ... }: {
virtualisation.docker = {
enable = true;
rootless = {
enable = true;
setSocketVariable = true;
};
};
}

View file

@ -23,11 +23,13 @@ in {
};
services.pipewire = {
enable = true;
enable = false;
pulse.enable = true;
wireplumber.enable = true;
};
hardware.pulseaudio.enable = true;
services.dbus.enable = true;
programs.sway = {

View file

@ -1,4 +1,4 @@
{ pkgs, lib, config, nixpkgs, pwnix, ... }:
{ pkgs, lib, config, nixpkgs, pwnix, helix, ... }:
let cfg = config.custom.nix;
@ -9,10 +9,12 @@ in with lib; {
# TODO: Add strawberry as a build machine here
config = {
nixpkgs.config.allowUnfree = true;
nixpkgs.overlays = [ (import ../overlay.nix helix) ];
nix.extraOptions = ''
experimental-features = nix-command flakes
'';
nix.registry.nixpkgs.flake = nixpkgs;
nix.registry.helix.flake = helix;
nix.registry.pwnix.flake = pwnix;
nix.settings.trusted-users = [
"@wheel"

Binary file not shown.

After

Width:  |  Height:  |  Size: 436 KiB

View file

Before

Width:  |  Height:  |  Size: 598 KiB

After

Width:  |  Height:  |  Size: 598 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 325 KiB

BIN
shared/data/time-warp.jpg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.2 MiB

View file

@ -5,7 +5,7 @@ pkgs: with pkgs; [
bottom
coreutils
curl
exa
eza
fd
file
git

View file

@ -25,6 +25,7 @@ in with lib; {
"reboot"
"exit"
"exa"
"eza"
"fg"
"cd"
"ls"
@ -38,7 +39,8 @@ in with lib; {
shellAliases = {
# General aliases
":q" = "exit";
"t" = "${exa}/bin/exa -T";
"t" = "${eza}/bin/eza -T";
"l" = "${eza}/bin/eza";
".." = "cd ..";
# Git command aliases

View file

@ -4,6 +4,7 @@
imports = [
./bash.nix
./rust.nix
./git.nix
./mpd.nix
./xdg.nix

View file

@ -5,9 +5,8 @@
global = {
font = "Fira Code 9";
origin = "bottom-right";
offset = "10x10";
offset = "3x50";
frame_width = "2";
frame_color = "#ffffff";
corner_radius = "4";
width = "400";
};

View file

@ -1,4 +1,4 @@
{ pkgs, lib, config, ... }:
{ pkgs, nixpkgs-latest, lib, config, ... }:
let mod = "Mod4";
cfg = config.custom.gui;
@ -57,11 +57,14 @@ in with lib; {
extraConfig = ''
bindsym --release ${mod}+d exec ${sc}/bin/sc
'';
'' + (if !config.isNixos then ''
exec "${(import nixpkgs-latest {}).google-chrome}/bin/google-chrome-stable --ozone-platform-hint=auto --enable-features=VaapiVideoDecoder,VaapiVideoEncoder --app=https://calendar.google.com"
'' else "");
config = rec {
output."*".bg = "${../../data/wallpaper.jpg} fill";
input."type:keyboard".xkb_options = "caps:escape";
output."*".bg = "${../../data/time-warp.jpg} fill";
output."eDP-1".bg = "${../../data/temporal-cleansing.png} fill";
input."type:keyboard".xkb_options = "caps:super";
terminal = "kitty --single-instance";
bars = [];
@ -113,12 +116,13 @@ in with lib; {
"${mod}+Alt+a" = "layout toggle stacking splitv";
"${mod}+Alt+s" = "layout toggle tabbed splith";
"${mod}+Escape" = "exec swaylock";
"${mod}+Escape" = if config.isNixos then "exec ${pkgs.swaylock}/bin/swaylock" else "exec swaylock";
"${mod}+Space" = "exec pkill -SIGUSR1 waybar";
"${mod}+Return" = "exec ${terminal}";
"${mod}+Alt+Return" = "exec ${pkgs.foot}/bin/foot";
"${mod}+Tab" = "exec ${pkgs.firefox-wayland}/bin/firefox";
"${mod}+Alt+Tab" = "exec ${pkgs.google-chrome}/bin/google-chrome-stable --ozone-platform-hint=auto --enable-features=VaapiVideoDecoder,VaapiVideoEncoder";
"${mod}+Alt+Tab" = "exec ${(import nixpkgs-latest {}).google-chrome}/bin/google-chrome-stable --ozone-platform-hint=auto --enable-features=VaapiVideoDecoder,VaapiVideoEncoder";
"${mod}+Backspace" = "mode kill";
@ -127,6 +131,9 @@ in with lib; {
"XF86AudioMute" = "exec ${vol} toggle";
"XF86AudioPlay" = "exec ${mpc} toggle";
"${mod}+z" = "exec ${vol} lower";
"${mod}+x" = "exec ${vol} raise";
"${mod}+comma" = "exec ${mpc} prev";
"${mod}+period" = "exec ${mpc} next";
"${mod}+slash" = "exec ${mpc} toggle";

View file

@ -36,20 +36,15 @@ in {
target = "sway-session.target";
};
settings = [{
margin = "3";
position = "bottom";
exclusive = false;
layer = "top";
modules-left = [
modules-right = with lib; flatten [
"sway/workspaces"
"sway/mode"
"mpd"
];
modules-right = with lib; flatten [
"cpu"
"disk"
(optional (cfg.battery.name != "") "battery")
(optional (cfg.bluetooth.enable) "bluetooth")
(optional (cfg.network.wifi != "") "network#wifi")
(optional (cfg.network.eth != "") "network#eth")
(optional (cfg.network.vpn != "") "network#vpn")
"network"
(if cfg.audio.wireplumber
then "wireplumber"
else "pulseaudio")
@ -62,35 +57,28 @@ in {
"format-disconnected" = "";
};
"clock#time" = {
"format" = "{:%H:%M:%S}";
"format" = "{:%H:%M}";
"interval" = 1;
};
"clock#date" = {
"format" = "{:%Y-%m-%d}";
"interval" = 60;
};
"network#wifi" = {
"interface" = cfg.network.wifi;
"format" = "wifi";
};
"network#eth" = {
"interface" = cfg.network.eth;
"format" = "eth";
};
"network#vpn" = {
"interface" = cfg.network.vpn;
"format" = "vpn";
"network" = {
"format-wifi" = "{essid}";
"format-ethernet" = "eth";
"format-disconnected" = "";
};
"pulseaudio" = {
"format" = "{desc}: {volume}%";
"format" = "{desc} | {volume}%";
};
"wireplumber" = {
"format" = "{node_name}: {volume}%";
"format" = "{node_name} | {volume}%";
};
"battery" = {
"bat" = cfg.battery.name;
"format-discharging" = "{capacity}% (battery)";
"format-charging" = "{capacity}% (charging)";
"format-discharging" = "{capacity}%";
"format-charging" = "{capacity}%";
"format-full" = "";
"states" = {
"critical" = 20;
@ -101,29 +89,10 @@ in {
"format-on" = "";
"format-connected" = "{device_alias}";
};
"disk" = {
"format" = "{used} :: {free}";
};
"sway/workspaces" = {
"all-outputs" = true;
};
}];
style = let
green = "#27e67a";
yellow = "#edd340";
pink = "#ff4787";
teal = "#1bcf9c";
blue = "#3988e3";
violet = "#9063e6";
lime = "#bfed5a";
red = "#eb3b5b";
disabled = ''
color: #ffffff;
background-color: rgba(207, 207, 207, 0.4);
'';
in ''
# TODO: make this fancy scss
style = ''
/* General/shared styles */
* {
@ -133,7 +102,13 @@ in {
}
window#waybar {
background-color: rgba(0, 0, 0, 0.45);
background-color: transparent;
}
.modules-right {
background-color: #424242;
border-radius: 40px;
padding-left: 2px;
}
#battery,
@ -147,12 +122,9 @@ in {
#pulseaudio,
#wireplumber
{
padding: 2px 10px;
margin: 5px;
padding: 5px 10px;
margin: 5px 2px;
border-radius: 100px;
}
#cpu, #disk, #bluetooth, #mpd {
color: #ffffff;
background-color: rgba(0, 0, 0, 0.4);
}
@ -161,32 +133,34 @@ in {
/* Sway chips */
#workspaces {
margin-left: 5px;
padding: 0;
margin: 5px;
margin: 5px 2px 5px 5px;
border-radius: 200px;
background-color: rgba(0, 0, 0, 0.4);
}
#workspaces button {
margin: 0;
padding: 0 5px;
border: 2px solid;
border-color: transparent;
border-radius: 100px;
color: #ffffff;
background-color: rgba(0, 0, 0, 0.4);
font-size: 9px;
margin: 0;
padding: 0 5px;
}
#workspaces button.visible.focused {
color: #212121;
background-color: ${green};
color: #ffffff;
border-color: #2bdafc;
}
#workspaces button.visible {
color: ${green};
color: #2bdafc;
}
#mode {
background-color: ${teal};
color: #212121;
background-color: #2bdafc;
}
@ -194,69 +168,63 @@ in {
#clock {
color: #ffffff;
background-color: transparent;
padding: 5px 10px;
background-color: rgba(0, 0, 0, 0.4);
}
#clock.date { padding-right: 0; }
#clock.time { padding-left: 0; }
#clock.date {
padding-right: 5px;
margin-right: 0;
border-radius: 14px 0 0 14px;
}
#clock.time {
padding-left: 5px;
margin-left: 0;
border-radius: 0 14px 14px 0;
margin-right: 5px;
}
/* Radio chips */
#network {
background-color: ${green};
}
#network.disconnected {
${disabled}
color: #ffffff;
background-color: transparent;
}
#bluetooth.connected {
background-color: ${blue};
background-color: #3988e3;
}
/* Audio chip */
#pulseaudio,
#wireplumber
{
background-color: ${yellow};
}
#pulseaudio.muted,
#wireplumber.muted
{
${disabled}
color: rgba(207, 207, 207, 0.9);
}
/* Battery chip */
#battery.discharging {
#battery {
border: 2px solid;
border-color: transparent;
border-radius: 200px;
padding: 5px 8px;
color: #ffffff;
background-color: ${violet};
background-color: rgba(0, 0, 0, 0.4);
}
#battery.charging {
background-color: ${lime};
border-color: #2bdafc;
}
#battery.critical {
background-color: ${red};
border-color: #eb3b5b;
}
/* MPD chip */
#mpd.playing {
color: #ffffff;
}
#mpd.paused {
${disabled}
}
'';
};
};

View file

@ -1,4 +1,4 @@
{ lib, pkgs, config, ... }:
{ lib, pkgs, config, helix, ... }:
(lib.mkIf (!config.isNixos) {
@ -12,7 +12,7 @@
nixpkgs.config = import ./nix-config.nix;
nixpkgs.overlays = [
(import ../../overlay.nix)
(import ../../overlay.nix helix)
];
xdg.configFile."nixpkgs/config.nix".source = ./nix-config.nix;

View file

@ -9,6 +9,8 @@
eva
hyperfine
du-dust
pijul
python311Packages.deemix
]) ++ (import ../env.nix pkgs);
# CLI for accessing my passwords
@ -24,7 +26,7 @@
# It's like `top` but cooler
programs.bottom.enable = true;
programs.exa = {
programs.eza = {
enable = true;
extraOptions = [
"--group-directories-first"

14
shared/home/rust.nix Normal file
View file

@ -0,0 +1,14 @@
{ oxalica, nixpkgs, ... }: {
home.packages = let
pkgs = import nixpkgs { overlays = [ oxalica.overlays.default ]; };
# We want an up-to-date nightly but also we need there to be stdlib and stuff
rust = pkgs.rust-bin.selectLatestNightlyWith (tc: tc.default.override {
extensions = [ "rust-src" ];
});
in [
rust
pkgs.rust-analyzer
];
}

View file

@ -1,4 +1,4 @@
final: prev:
helix: final: prev:
with (import ./lib.nix final); {
element-web = webApp "element" "https://riot.badat.dev";
@ -10,4 +10,15 @@ with (import ./lib.nix final); {
prev.tor-browser-bundle-bin.override {
useHardenedMalloc = false;
};
# We can't just patch it because grammars are fetched at build time.
helix = helix.packages.${prev.stdenv.system}.default.override {
grammarOverlays = [(f: p: {
"rust" = p.rust.overrideAttrs (o: {
rev = "04352146022062c101b8ddd853adf17eadd8cf56";
});
})];
};
# python311Packages.deemix = prev.python311Packages.deemix.overrideAttrs (old: {
# patches = [./patch/dont_write_arl.patch];
# });
}

View file

@ -0,0 +1,18 @@
diff --git a/deemix/__main__.py b/deemix/__main__.py
index 39a878a..74acf8d 100644
--- a/deemix/__main__.py
+++ b/deemix/__main__.py
@@ -47,9 +47,10 @@ def download(url, bitrate, portable, path):
with open(configFolder / '.arl', 'r', encoding="utf-8") as f:
arl = f.readline().rstrip("\n").strip()
if not dz.login_via_arl(arl): arl = requestValidArl()
- else: arl = requestValidArl()
- with open(configFolder / '.arl', 'w', encoding="utf-8") as f:
- f.write(arl)
+ else:
+ arl = requestValidArl()
+ with open(configFolder / '.arl', 'w', encoding="utf-8") as f:
+ f.write(arl)
plugins = {}
if Spotify:

View file

@ -1,5 +1,10 @@
{
age.secrets = {
"backblaze".file = ../secret/backblaze.age;
"arl" = {
file = ../secret/arl.age;
owner = "riley";
mode = "777"; # Fuck it we ball
};
};
}

View file

@ -5,6 +5,7 @@
username = "riley";
homeDirectory = "/home/riley";
stateVersion = "22.05";
packages = [ pkgs.tty-share ];
};
programs = {

View file

@ -1,12 +1,21 @@
{ lib, modulesPath, ... }: {
{ pkgs, lib, nixos-hardware, ... }: {
imports = [./hardware-configuration.nix];
imports = [
nixos-hardware.nixosModules.lenovo-thinkpad-x390
nixos-hardware.nixosModules.common-gpu-nvidia-disable
./hardware-configuration.nix
];
custom = {
gui.enable = true;
backups.enable = true;
};
boot = {
kernelModules = [ "kvm-intel" ];
binfmt.emulatedSystems = [ "aarch64-linux" ];
};
services.fprintd.enable = true;
networking.hostName = "lime";
@ -17,5 +26,16 @@
home-manager.users."riley".home.stateVersion = "22.11";
programs.adb.enable = true;
users.users."riley".extraGroups = ["adbusers"];
programs.steam.enable = true;
users.users."riley".packages = [ pkgs.bluez ];
hardware.bluetooth = {
enable = true;
powerOnBoot = true;
};
}

View file

@ -1,4 +1,4 @@
{ ... }:
{ pkgs, ... }:
{
custom.gui = {
@ -9,4 +9,8 @@
};
};
programs.iamb.enable = true;
home.packages = with pkgs; [
qbittorrent
vlc
];
}

View file

@ -11,6 +11,7 @@
networking = {
hostName = "strawberry";
interfaces."enp9s0".useDHCP = true;
firewall.enable = false;
};
nix = {
@ -57,6 +58,8 @@
{ device = "/dev/nixos/swap"; }
];
programs.steam.enable = true;
services.xserver.videoDrivers = [ "nvidia" ];
hardware.nvidia.modesetting.enable = true;