properly reformat all files

This commit is contained in:
Franek 2025-05-03 09:25:00 +02:00
parent 635ef052e7
commit 5948c1db1c
18 changed files with 324 additions and 287 deletions

View File

@ -19,7 +19,13 @@
ags.inputs.nixpkgs.follows = "nixpkgs";
};
outputs = { self, nixpkgs, android-nixpkgs, ... }:
outputs =
{
self,
nixpkgs,
android-nixpkgs,
...
}:
let
forAllSystems = nixpkgs.lib.genAttrs [
"aarch64-linux"
@ -29,12 +35,16 @@
in
{
nixosConfigurations = import ./hosts { inherit self; };
devShells = forAllSystems (system:
let pkgs = nixpkgs.legacyPackages.${system};
in {
devShells = forAllSystems (
system:
let
pkgs = nixpkgs.legacyPackages.${system};
in
{
ddt4all = import ./shells/ddt4all.nix { inherit pkgs; };
android = import ./shells/android.nix { inherit pkgs android-nixpkgs; };
rust = import ./shells/rust.nix { inherit pkgs; };
});
}
);
};
}

View File

@ -12,7 +12,8 @@ let
hostname,
useHomeManager ? true,
modules ? [ ],
}: lib.nixosSystem {
}:
lib.nixosSystem {
specialArgs = { inherit inputs; };
modules =
[

View File

@ -9,7 +9,10 @@
];
nix.settings = {
experimental-features = [ "nix-command" "flakes" ];
experimental-features = [
"nix-command"
"flakes"
];
auto-optimise-store = true;
};

View File

@ -1,37 +1,14 @@
{ config, pkgs, lib, inputs, ... }:
{
options.modules.ags = {
enable = lib.mkEnableOption "Aylur's GTK Shell with optional Stylix support";
full = lib.mkOption {
type = lib.types.bool;
default = false;
description = "Enable all components (AstalBattery, AstalPowerProfiles etc.)";
};
};
config,
pkgs,
lib,
inputs,
...
}:
config = lib.mkIf config.modules.ags.enable {
programs.ags = {
enable = true;
extraPackages = if config.modules.ags.full then
with inputs.ags.packages.${pkgs.system};
[
apps
battery
bluetooth
greet
hyprland
mpris
network
notifd
powerprofiles
tray
wireplumber
] else [];
};
home.file.".config/theme_colors.scss".text = if config.modules.stylix.enable
then with config.lib.stylix.colors; ''
let
generate-colors =
colors: with colors; ''
$base00: #${base00};
$base01: #${base01};
$base02: #${base02};
@ -48,6 +25,42 @@
$base0D: #${base0D};
$base0E: #${base0E};
$base0F: #${base0F};
'' else null;
'';
in
{
options.modules.ags = {
enable = lib.mkEnableOption "Aylur's GTK Shell with optional Stylix support";
full = lib.mkOption {
type = lib.types.bool;
default = false;
description = "Enable all components (AstalBattery, AstalPowerProfiles etc.)";
};
};
config = lib.mkIf config.modules.ags.enable {
programs.ags = {
enable = true;
extraPackages =
if config.modules.ags.full then
with inputs.ags.packages.${pkgs.system};
[
apps
battery
bluetooth
greet
hyprland
mpris
network
notifd
powerprofiles
tray
wireplumber
]
else
[ ];
};
home.file.".config/theme_colors.scss".text =
if config.modules.stylix.enable then generate-colors config.lib.stylix.colors else null;
};
}

View File

@ -27,7 +27,8 @@ let
'';
switch-theme = theme: "$(${find-generation})/${theme}/activate";
in {
in
{
options.modules.darkman = {
enable = lib.mkEnableOption "Darkman service and integration";
customLightModeScript = lib.mkOption {
@ -46,15 +47,19 @@ in {
config = lib.mkIf config.modules.darkman.enable {
services.darkman = {
enable = true;
darkModeScripts = optionalAttrs (config.modules.darkman.customDarkModeScript != null) {
darkModeScripts =
optionalAttrs (config.modules.darkman.customDarkModeScript != null) {
custom = config.modules.darkman.customDarkModeScript;
} // optionalAttrs (config.modules.stylix.enable) {
}
// optionalAttrs (config.modules.stylix.enable) {
stylix = switch-theme "dark";
};
lightModeScripts = optionalAttrs (config.modules.darkman.customLightModeScript != null) {
lightModeScripts =
optionalAttrs (config.modules.darkman.customLightModeScript != null) {
custom = config.modules.darkman.customLightModeScript;
} // optionalAttrs (config.modules.stylix.enable) {
}
// optionalAttrs (config.modules.stylix.enable) {
stylix = switch-theme "light";
};

View File

@ -8,7 +8,8 @@
let
module = inputs.fingerprint-sensor.nixosModules."06cb-009a-fingerprint-sensor";
in {
in
{
options.modules.fingerprint-fix = {
enable = lib.mkEnableOption "Enable support for fingerprint for P51S-like ThinkPads.";
calibDataFile = lib.mkOption {

View File

@ -8,7 +8,7 @@
enable = true;
};
services.xserver.videoDrivers = ["nvidia"];
services.xserver.videoDrivers = [ "nvidia" ];
hardware.nvidia = {
modesetting.enable = true;

View File

@ -1,7 +1,7 @@
{
webcopy = ''
set -l domain (string trim $argv)
get --recursive \
wget --recursive \
--level 5 \
--no-clobber \
--page-requisites \

View File

@ -47,7 +47,7 @@
darkWallpaper = ./wallpapers/dark.jpg;
};
stylix.targets.firefox.profileNames = ["default"];
stylix.targets.firefox.profileNames = [ "default" ];
modules.ags = {
enable = true;

View File

@ -1,6 +1,7 @@
{ pkgs, inputs, ... }:
with pkgs; [
with pkgs;
[
(python3.withPackages (
py: with py; [
pywayland

View File

@ -1,15 +1,18 @@
{ pkgs, android-nixpkgs }:
let
android = pkgs.callPackage android-nixpkgs {};
androidSdk = android.sdk (sdkPkgs: with sdkPkgs; [
android = pkgs.callPackage android-nixpkgs { };
androidSdk = android.sdk (
sdkPkgs: with sdkPkgs; [
cmdline-tools-latest
build-tools-35-0-0
platform-tools
platforms-android-35
]);
]
);
in pkgs.mkShell rec {
in
pkgs.mkShell rec {
buildInputs = with pkgs; [
androidSdk
jdk17