Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions nixos/doc/manual/release-notes/rl-2505.section.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,8 @@

- [Kimai](https://www.kimai.org/), a web-based multi-user time-tracking application. Available as [services.kimai](option.html#opt-services.kimai).

- [Framework Inputmodule](https://github.com/FrameworkComputer/inputmodule-rs), a tool to control Framework 16 input modules such as the LED Matrix. Available as [hardware.framework.inputmodule.enable](options.html#opt-hardware.framework.inputmodule.enable).

- [Omnom](https://github.com/asciimoo/omnom), a webpage bookmarking and snapshotting service. Available as [services.omnom](options.html#opt-services.omnom.enable).

- [Amazon CloudWatch Agent](https://github.com/aws/amazon-cloudwatch-agent), the official telemetry collector for AWS CloudWatch and AWS X-Ray. Available as [services.amazon-cloudwatch-agent](#opt-services.amazon-cloudwatch-agent.enable).
Expand Down
16 changes: 16 additions & 0 deletions nixos/modules/hardware/framework.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
{
config,
lib,
pkgs,
...
}:
{
options.hardware.framework = {
inputmodule.enable = lib.mkEnableOption "control software for the Framework 16 input modules";
};

config = lib.mkIf config.hardware.framework.inputmodule.enable {
environment.systemPackages = [ pkgs.inputmodule-control ];
services.udev.packages = [ pkgs.inputmodule-control ];
};
}
2 changes: 2 additions & 0 deletions nixos/modules/module-list.nix
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,8 @@
./hardware/digitalbitbox.nix
./hardware/flipperzero.nix
./hardware/flirc.nix
./hardware/framework.nix
./hardware/gkraken.nix
./hardware/glasgow.nix
./hardware/gpgsmartcards.nix
./hardware/graphics.nix
Expand Down
39 changes: 39 additions & 0 deletions pkgs/by-name/in/inputmodule-control/package.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
{
lib,
fetchFromGitHub,
pkg-config,
rustPlatform,
systemd,
}:
rustPlatform.buildRustPackage rec {
pname = "inputmodule-control";
version = "0.2.0-unstable-2024-11-17";

src = fetchFromGitHub {
owner = "FrameworkComputer";
repo = "inputmodule-rs";
rev = "262edffd35ad6aa7976aee38632f6b75695bc0a8";
hash = "sha256-d9Tvxch9VZbaWzwe69oQMqlCRcirkrtoFJd2SaXh+wY=";
};

useFetchCargoVendor = true;
cargoHash = "sha256-iqB0JxRlIwdjTh+dPa3W5bwYVOFGWObmBXUETZC6Rk8=";
buildAndTestSubdir = "inputmodule-control";

buildInputs = [ systemd ];
nativeBuildInputs = [ pkg-config ];

postInstall = ''
mkdir -p $out/lib/udev/rules.d
cp release/50-framework-inputmodule.rules $out/lib/udev/rules.d/50-framework-inputmodule.rules
'';

meta = with lib; {
description = "Framework Laptop 16 Input Module";
homepage = "https://github.com/FrameworkComputer/inputmodule-rs";
license = licenses.mit;
maintainers = with maintainers; [ dsluijk ];
mainProgram = "inputmodule-control";
platforms = platforms.linux;
};
}