From 29043896c8f536cf9c9e242b9464dc9a73122c23 Mon Sep 17 00:00:00 2001 From: Petru Paler Date: Sun, 25 Jan 2026 10:31:53 +0000 Subject: [PATCH] Add ham radio profile with FLEcli package Introduces a custom packages overlay (pkgs/) for packages not in nixpkgs. Adds FLEcli v0.1.7 for processing amateur radio logs (SOTA, POTA, WWFF). Enables ham-radio profile on beefy. Co-Authored-By: Claude Opus 4.5 --- common/ham-radio.nix | 8 ++++++++ flake.nix | 4 +++- hosts/beefy/default.nix | 1 + pkgs/default.nix | 7 +++++++ pkgs/flecli.nix | 28 ++++++++++++++++++++++++++++ 5 files changed, 47 insertions(+), 1 deletion(-) create mode 100644 common/ham-radio.nix create mode 100644 pkgs/default.nix create mode 100644 pkgs/flecli.nix diff --git a/common/ham-radio.nix b/common/ham-radio.nix new file mode 100644 index 0000000..9cbf98e --- /dev/null +++ b/common/ham-radio.nix @@ -0,0 +1,8 @@ +# ABOUTME: Ham radio tools profile for amateur radio operators. +# ABOUTME: Provides CLI tools for logging and processing ham radio contacts. +{ pkgs, ... }: +{ + environment.systemPackages = [ + pkgs.custom.flecli + ]; +} diff --git a/flake.nix b/flake.nix index d40d660..27f7e3e 100644 --- a/flake.nix +++ b/flake.nix @@ -67,6 +67,8 @@ browser-previews = browser-previews.packages.${prev.stdenv.hostPlatform.system}; }; + overlay-custom = import ./pkgs; + mkHost = system: profile: modules: let @@ -79,7 +81,7 @@ ( { config, pkgs, ... }: { - nixpkgs.overlays = [ overlay-unstable overlay-browser-previews ]; + nixpkgs.overlays = [ overlay-unstable overlay-browser-previews overlay-custom ]; nixpkgs.config.allowUnfree = true; } ) diff --git a/hosts/beefy/default.nix b/hosts/beefy/default.nix index 6ea74e0..59a1743 100644 --- a/hosts/beefy/default.nix +++ b/hosts/beefy/default.nix @@ -7,6 +7,7 @@ ../../common/cluster-member.nix # Consul + storage clients ../../common/cluster-tools.nix # Nomad CLI (no service) ../../common/docker.nix # Docker daemon + ../../common/ham-radio.nix # Ham radio tools (FLEcli) ./hardware.nix ]; diff --git a/pkgs/default.nix b/pkgs/default.nix new file mode 100644 index 0000000..be3b5e5 --- /dev/null +++ b/pkgs/default.nix @@ -0,0 +1,7 @@ +# ABOUTME: Custom packages overlay for packages not in nixpkgs. +# ABOUTME: Adds packages under pkgs.custom.* namespace. +final: prev: { + custom = { + flecli = final.callPackage ./flecli.nix { }; + }; +} diff --git a/pkgs/flecli.nix b/pkgs/flecli.nix new file mode 100644 index 0000000..a89032c --- /dev/null +++ b/pkgs/flecli.nix @@ -0,0 +1,28 @@ +# ABOUTME: FLEcli - Fast Log Entry CLI for amateur radio logging. +# ABOUTME: Processes FLE-formatted files into ADIF for SOTA, POTA, WWFF, etc. +{ + lib, + buildGoModule, + fetchFromGitHub, +}: + +buildGoModule rec { + pname = "flecli"; + version = "0.1.7"; + + src = fetchFromGitHub { + owner = "on4kjm"; + repo = "FLEcli"; + rev = "v${version}"; + hash = "sha256-6OFcShgUaK9RwonP6cl8eOD6Cu+F5LHZEUFPjCfWNV0="; + }; + + vendorHash = "sha256-6m01rcewPyy8pUXnIMwjyW+7I08pyJaTDliwTNp3fOM="; + + meta = with lib; { + description = "Fast Log Entry CLI - process amateur radio logs"; + homepage = "https://github.com/on4kjm/FLEcli"; + license = licenses.mit; + mainProgram = "FLEcli"; + }; +}