Add pomodoro timer package
Some checks failed
pre-commit / pre-commit (push) Failing after 13m10s

This commit is contained in:
Torjus Håkestad 2024-03-27 10:07:48 +01:00
parent 13aa781ebc
commit d5d12e79d8
2 changed files with 48 additions and 1 deletions

View File

@ -1,5 +1,12 @@
{ pkgs, ... }: { { pkgs, ... }:
let
my-pomodoro = pkgs.callPackage ../../packages/open-pomodoro.nix { };
in
{
home.packages = with pkgs; [ home.packages = with pkgs; [
# My own packages
my-pomodoro
# Generic tools # Generic tools
age age
alacritty alacritty

View File

@ -0,0 +1,40 @@
{ lib, buildGoModule, fetchFromGitHub, installShellFiles }:
buildGoModule rec {
pname = "openpomodoro-cli";
version = "0.3.0";
src = fetchFromGitHub {
owner = "open-pomodoro";
repo = "openpomodoro-cli";
rev = "v${version}";
hash = "sha256-h/o4yxrZ8ViHhN2JS0ZJMfvcJBPCsyZ9ZQw9OmKnOfY=";
};
vendorHash = "sha256-BR9d/PMQ1ZUYWSDO5ID2bkTN+A+VbaLTlz5t0vbkO60=";
ldflags = [ "-s" "-w" ];
GOWORK = "off";
subPackages = [ "cmd/pomodoro" ];
nativeBuildInputs = [ installShellFiles ];
# postInstall = ''
# installShellCompletion --cmd talosctl \
# --bash <($out/bin/talosctl completion bash) \
# --fish <($out/bin/talosctl completion fish) \
# --zsh <($out/bin/talosctl completion zsh)
# '';
doCheck = false; # no tests
meta = with lib; {
description = "A command-line Pomodoro tracker which uses the Open Pomodoro Format";
mainProgram = "pomodoro";
homepage = "https://github.com/open-pomodoro/openpomodoro-cli";
license = licenses.mit;
# maintainers = with maintainers; [ flokli ];
};
}