1
0
mirror of https://github.com/kmein/niveum synced 2026-03-16 10:11:08 +01:00
This commit is contained in:
2026-02-17 22:28:56 +01:00
parent e5c86818d9
commit c34647a800
3 changed files with 26 additions and 23 deletions

View File

@@ -129,6 +129,7 @@ in
polyglot polyglot
qrpaste qrpaste
ttspaste ttspaste
pi # llm agent
new-mac # get a new mac address new-mac # get a new mac address
scanned scanned
default-gateway default-gateway

View File

@@ -293,6 +293,7 @@
menstruation-backend = menstruation-backend =
menstruation-backend.packages.${prev.stdenv.hostPlatform.system}.menstruation-backend; menstruation-backend.packages.${prev.stdenv.hostPlatform.system}.menstruation-backend;
telebots = telebots.packages.${prev.stdenv.hostPlatform.system}.telebots; telebots = telebots.packages.${prev.stdenv.hostPlatform.system}.telebots;
pi-llm = llm-agents.packages.${prev.stdenv.hostPlatform.system}.pi;
hesychius = scripts.packages.${prev.stdenv.hostPlatform.system}.hesychius; hesychius = scripts.packages.${prev.stdenv.hostPlatform.system}.hesychius;
autorenkalender = autorenkalender.packages.${prev.stdenv.hostPlatform.system}.default; autorenkalender = autorenkalender.packages.${prev.stdenv.hostPlatform.system}.default;
onomap = scripts.packages.${prev.stdenv.hostPlatform.system}.onomap; onomap = scripts.packages.${prev.stdenv.hostPlatform.system}.onomap;
@@ -306,6 +307,7 @@
radio-news = prev.callPackage packages/radio-news { }; radio-news = prev.callPackage packages/radio-news { };
untilport = prev.callPackage packages/untilport.nix { }; untilport = prev.callPackage packages/untilport.nix { };
weechat-declarative = prev.callPackage packages/weechat-declarative.nix { }; weechat-declarative = prev.callPackage packages/weechat-declarative.nix { };
pi = prev.callPackage packages/pi.nix { };
# my packages # my packages
betacode = prev.callPackage packages/betacode.nix { }; betacode = prev.callPackage packages/betacode.nix { };
@@ -622,6 +624,7 @@
obsidian-vim obsidian-vim
opustags opustags
pdf-ocr pdf-ocr
pi
picoclaw picoclaw
pls pls
polyglot polyglot

View File

@@ -18,7 +18,7 @@ let
]; ];
outputHashMode = "recursive"; outputHashMode = "recursive";
outputHashAlgo = "sha256"; outputHashAlgo = "sha256";
outputHash = "sha256-QZSVCJ0XirRz56v6ogxaB37c0bI8+OGEjrnqCFr/YI8="; outputHash = "sha256-hfYl0Slxg3nuN6KTtvpWW0QUxtg3JRE0n9N7rIXBTOc=";
impureEnvVars = [ impureEnvVars = [
"http_proxy" "http_proxy"
"https_proxy" "https_proxy"
@@ -41,30 +41,29 @@ let
''; '';
in in
writeShellApplication { writeShellApplication {
name = "pi";
runtimeInputs = [ nodejs ]; runtimeInputs = [ nodejs ];
wrapper = text = ''
{ exePath, ... }: set -efu
'' export npm_config_prefix="${pluginPrefix}"
set -efu
export npm_config_prefix="${pluginPrefix}"
# Ensure settings.json has our plugins listed # Ensure settings.json has our plugins listed
SETTINGS_DIR="''${PI_CODING_AGENT_DIR:-$HOME/.pi/agent}" SETTINGS_DIR="''${PI_CODING_AGENT_DIR:-$HOME/.pi/agent}"
SETTINGS_FILE="$SETTINGS_DIR/settings.json" SETTINGS_FILE="$SETTINGS_DIR/settings.json"
mkdir -p "$SETTINGS_DIR" mkdir -p "$SETTINGS_DIR"
# Add packages to settings if not already present # Add packages to settings if not already present
if [ ! -f "$SETTINGS_FILE" ]; then if [ ! -f "$SETTINGS_FILE" ]; then
echo '{"packages":["npm:pi-hooks","npm:shitty-extensions"]}' > "$SETTINGS_FILE" echo '{"packages":["npm:pi-hooks","npm:shitty-extensions"]}' > "$SETTINGS_FILE"
else else
for pkg in "npm:pi-hooks" "npm:shitty-extensions"; do for pkg in "npm:pi-hooks" "npm:shitty-extensions"; do
if ! grep -q "$pkg" "$SETTINGS_FILE"; then if ! grep -q "$pkg" "$SETTINGS_FILE"; then
${lib.getExe jq} --arg p "$pkg" '.packages = ((.packages // []) + [$p] | unique)' "$SETTINGS_FILE" > "$SETTINGS_FILE.tmp" ${lib.getExe jq} --arg p "$pkg" '.packages = ((.packages // []) + [$p] | unique)' "$SETTINGS_FILE" > "$SETTINGS_FILE.tmp"
mv "$SETTINGS_FILE.tmp" "$SETTINGS_FILE" mv "$SETTINGS_FILE.tmp" "$SETTINGS_FILE"
fi fi
done done
fi fi
exec ${lib.getExe pi-llm} "$@" exec ${lib.getExe pi-llm} "$@"
''; '';
} }