This commit is contained in:
EdenQwQ 2025-12-01 22:23:21 +08:00
parent 57869f04d9
commit 38e630d727
3 changed files with 35 additions and 2 deletions

17
flake.lock generated
View file

@ -865,6 +865,22 @@
"type": "github"
}
},
"nixpkgs-kimi-cli": {
"locked": {
"lastModified": 1762848367,
"narHash": "sha256-xI+WSnETMXwwbB0sGmKs6wwUwIFvAfRW30KBLyajGDI=",
"owner": "jetjinser",
"repo": "nixpkgs",
"rev": "7bd2238bc0eef41e08cd1ac6c36aa7a2af27759d",
"type": "github"
},
"original": {
"owner": "jetjinser",
"ref": "jinser/kimi-cli",
"repo": "nixpkgs",
"type": "github"
}
},
"nixpkgs-lib": {
"locked": {
"lastModified": 1761765539,
@ -1375,6 +1391,7 @@
"nixGL": "nixGL",
"nixd": "nixd",
"nixpkgs": "nixpkgs_12",
"nixpkgs-kimi-cli": "nixpkgs-kimi-cli",
"nixpkgs-stable": "nixpkgs-stable_2",
"nixpkgs-wayland": "nixpkgs-wayland",
"nixvim": "nixvim",

View file

@ -102,5 +102,6 @@
inputs.nixpkgs.follows = "nixpkgs";
};
hexecute.url = "github:ThatOtherAndrew/Hexecute";
nixpkgs-kimi-cli.url = "github:jetjinser/nixpkgs/jinser/kimi-cli";
};
}

View file

@ -1,4 +1,9 @@
{ pkgs, config, ... }:
{
pkgs,
config,
inputs,
...
}:
{
programs.gemini-cli = {
enable = true;
@ -12,7 +17,17 @@
ANTHROPIC_BASE_URL = "https://anyrouter.top";
SILICONFLOW_API_KEY = "$(cat ${config.age.secrets.siliconflow_token.path})";
};
home.packages = with pkgs; [ nur.repos.charmbracelet.crush ];
home.packages = with pkgs; [
nur.repos.charmbracelet.crush
(inputs.nixpkgs-kimi-cli.legacyPackages.${pkgs.stdenv.hostPlatform.system}.kimi-cli.overrideAttrs {
src = fetchFromGitHub {
owner = "MoonshotAI";
repo = "kimi-cli";
rev = "8c942b97c52996885a508e37e503d37b63e5bf90";
hash = "sha256-mRoyGpZv6C2wva3ishqqRLQwoabeKDtCrpVoFBwX5QM=";
};
})
];
xdg.configFile."crush/crush.json".text = ''
{
"providers": {