Skip to content

Commit

Permalink
Control panel integration
Browse files Browse the repository at this point in the history
Control panel was added as input to flake.nix and as overlay
to common modules. The desktop item were added along with
appropriate icon.

Signed-off-by: dmitry-erin <dmitry.erin@unikie.com>
  • Loading branch information
dmitry-erin committed Sep 19, 2024
1 parent cfcfe93 commit 742f132
Show file tree
Hide file tree
Showing 7 changed files with 60 additions and 2 deletions.
28 changes: 28 additions & 0 deletions flake.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

9 changes: 9 additions & 0 deletions flake.nix
Original file line number Diff line number Diff line change
Expand Up @@ -155,6 +155,15 @@
pre-commit-hooks-nix.follows = "pre-commit-hooks-nix";
};
};

ctrl-panel = {
url = "github:tiiuae/ghaf-ctrl-panel";
inputs = {
nixpkgs.follows = "nixpkgs";
flake-utils.follows = "flake-utils";
crane.follows = "givc/crane";
};
};
};

outputs =
Expand Down
6 changes: 6 additions & 0 deletions modules/common/services/desktop.nix
Original file line number Diff line number Diff line change
Expand Up @@ -160,6 +160,12 @@ in
path = "${pkgs.givc-cli}/bin/givc-cli ${cliArgs} reboot";
icon = "${pkgs.icon-pack}/system-reboot.svg";
}

{
name = "Control panel";
path = "${pkgs.ctrl-panel}/bin/ctrl-panel";
icon = "${pkgs.icon-pack}/utilities-tweak-tool.svg";
}
]
++ optionals config.ghaf.reference.programs.windows-launcher.enable [
{
Expand Down
8 changes: 7 additions & 1 deletion modules/flake-module.nix
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,13 @@
nixpkgs.overlays = [ inputs.ghafpkgs.overlays.default ];
}
];

laptop.imports = [
./hardware/definition.nix
./hardware/x86_64-generic
./reference/hardware/laptop.nix
./hardware/common
{ nixpkgs.overlays = [ inputs.ghafpkgs.overlays.default ]; }
];
desktop.imports = [ ./desktop ];
host.imports = [ ./host ];
lanzaboote.imports = [ ./lanzaboote ];
Expand Down
9 changes: 8 additions & 1 deletion modules/hardware/flake-module.nix
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,14 @@
./x86_64-generic
./laptop.nix
./common
{ nixpkgs.overlays = [ inputs.ghafpkgs.overlays.default ]; }
{
nixpkgs.overlays = [
inputs.ghafpkgs.overlays.default
(_final: prev: {
ctrl-panel = inputs.ctrl-panel.packages.${prev.stdenv.hostPlatform.system}.default;
})
];
}
];
hw-x86_64-generic.imports = [
./definition.nix
Expand Down
1 change: 1 addition & 0 deletions modules/microvm/virtualization/microvm/guivm.nix
Original file line number Diff line number Diff line change
Expand Up @@ -113,6 +113,7 @@ let
pkgs.nm-launcher
pkgs.pamixer
]
++ [ inputs.ctrl-panel.packages.${pkgs.system}.default ]
++ (lib.optional (
config.ghaf.profiles.debug.enable && config.ghaf.virtualization.microvm.idsvm.mitmproxy.enable
) pkgs.mitmweb-ui)
Expand Down
1 change: 1 addition & 0 deletions packages/icon-pack/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ let
"thorium-browser.svg"
"utilities-terminal.svg"
"yast-vpn.svg"
"utilities-tweak-tool.svg"
];
in
runCommand "icon-pack"
Expand Down

0 comments on commit 742f132

Please sign in to comment.