update hwylterm

This commit is contained in:
Daylin Morgan 2025-02-19 18:05:34 -06:00
parent 9f2be2c4ac
commit a49b057bb6
Signed by: daylin
GPG key ID: 950D13E9719334AD
4 changed files with 18 additions and 28 deletions

View file

@ -15,23 +15,21 @@
}: }:
let let
inherit (nixpkgs.lib) genAttrs cleanSource; inherit (nixpkgs.lib) genAttrs cleanSource;
supportedSystems = [ systems = [
"x86_64-linux" "x86_64-linux"
"x86_64-darwin" "x86_64-darwin"
"aarch64-linux" "aarch64-linux"
"aarch64-darwin" "aarch64-darwin"
]; ];
forAllSystems = forSystem =
f: f: system:
genAttrs supportedSystems (
system:
f ( f (
import nixpkgs { import nixpkgs {
inherit system; inherit system;
overlays = [ nim2nix.overlays.default ]; overlays = [ nim2nix.overlays.default ];
} }
)
); );
forAllSystems = f: genAttrs systems (forSystem f);
in in
{ {
devShells = forAllSystems (pkgs: { devShells = forAllSystems (pkgs: {
@ -48,7 +46,7 @@
pname = "hyprman"; pname = "hyprman";
version = "unstable"; version = "unstable";
src = cleanSource ./.; src = cleanSource ./.;
nimbleDepsHash = "sha256-noqNxRnz8C7HTiqtO6u9+Oe9tC8C9cBSGSpIUrN5btU="; nimbleDepsHash = "sha256-s1uyhpie+tqUmrlCTV6alGmJhY6roGNU8l2W7CpWQqA=";
}; };
}); });
formatter = forAllSystems (pkgs: pkgs.nixfmt-rfc-style); formatter = forAllSystems (pkgs: pkgs.nixfmt-rfc-style);

View file

@ -13,4 +13,4 @@ bin = @["hyprman"]
requires "nim >= 2.0.8" requires "nim >= 2.0.8"
requires "yaml" requires "yaml"
requires "jsony" requires "jsony"
requires "https://github.com/daylinmorgan/hwylterm#dbde9c9" requires "https://github.com/daylinmorgan/hwylterm#1324ba54"

View file

@ -3,12 +3,12 @@
"packages": { "packages": {
"hwylterm": { "hwylterm": {
"version": "0.1.0", "version": "0.1.0",
"vcsRevision": "dbde9c91e972e101c6e9da4ad87a0b2fa6d1bee8", "vcsRevision": "1324ba54151eeb6c2a28d8236854ccfb9885b530",
"url": "https://github.com/daylinmorgan/hwylterm", "url": "https://github.com/daylinmorgan/hwylterm",
"downloadMethod": "git", "downloadMethod": "git",
"dependencies": [], "dependencies": [],
"checksums": { "checksums": {
"sha1": "aa7def4e92d09001e407791bbe02f21c4d835158" "sha1": "b5c3cc2e8ed4ce5514750d1216d0816cd4ef0dc7"
} }
}, },
"jsony": { "jsony": {

View file

@ -13,12 +13,9 @@ hwylCli:
settings Propagate, InferShort settings Propagate, InferShort
flags: flags:
[global] [global]
config: c|config(string, "path to config file"):
i configPath
T string
? "path to config file"
* (getConfigDir() / "hyprman" / "config.yml") * (getConfigDir() / "hyprman" / "config.yml")
- c i configPath
S HideDefault S HideDefault
preSub: preSub:
config.load(configPath) config.load(configPath)
@ -26,14 +23,9 @@ hwylCli:
[mako] [mako]
... "interact with mako" ... "interact with mako"
flags: flags:
count: count(10, int, "# of notifications")
T int json "outptut as json"
? "# of notifications" reverse "swap notification order"
* 10
json:
? "output as json"
reverse:
? "swap notification order"
run: run:
let history = getHistory(reverse, count) let history = getHistory(reverse, count)
if json: echo $(%* history) if json: echo $(%* history)