mirror of
https://github.com/srid/nixos-config.git
synced 2026-04-12 14:56:28 +08:00
opencode: wire commands
This commit is contained in:
parent
f13b2406c6
commit
0e07a3fbc2
2 changed files with 13 additions and 2 deletions
|
|
@ -1,11 +1,22 @@
|
|||
{ pkgs, ... }:
|
||||
{ flake, lib, pkgs, ... }:
|
||||
let
|
||||
inherit (flake.inputs) AI;
|
||||
juspayProvider = import ./juspay;
|
||||
|
||||
commandsDir = AI + "/commands";
|
||||
autoCommands = if builtins.pathExists commandsDir then
|
||||
lib.mapAttrs'
|
||||
(fileName: _: lib.nameValuePair
|
||||
(lib.removeSuffix ".md" fileName)
|
||||
(commandsDir + "/${fileName}"))
|
||||
(builtins.readDir commandsDir)
|
||||
else { };
|
||||
in
|
||||
{
|
||||
programs.opencode = {
|
||||
enable = true;
|
||||
package = pkgs.opencode;
|
||||
commands = autoCommands;
|
||||
settings = {
|
||||
model = "litellm/glm-latest";
|
||||
# Explore agent for fast codebase search/reading tasks
|
||||
|
|
|
|||
2
vendor/AI
vendored
2
vendor/AI
vendored
|
|
@ -1 +1 @@
|
|||
Subproject commit d4fec34a2750439093ce5bcffdaa430ddea6d734
|
||||
Subproject commit 957882d54641938a538a08bbf61c5195261c1052
|
||||
Loading…
Add table
Add a link
Reference in a new issue