mirror of
https://github.com/nix-community/home-manager.git
synced 2026-01-11 01:19:32 +08:00
deploy: b1b1c68033
This commit is contained in:
@@ -62444,12 +62444,12 @@ null or package</p>
|
||||
</span>
|
||||
</dt>
|
||||
<dd>
|
||||
<p>Custom agents for opencode.
|
||||
The attribute name becomes the agent filename, and the value is either:</p><div class="itemizedlist"><ul class="itemizedlist " style="list-style-type: disc;"><li class="listitem"><p>Inline content as a string</p></li><li class="listitem"><p>A path to a file containing the agent content
|
||||
Agents are stored in <code class="filename">$XDG_CONFIG_HOME/opencode/agent/</code> directory.</p></li></ul></div>
|
||||
<p>Custom agents for opencode.</p><p>This option can either be:</p><div class="itemizedlist"><ul class="itemizedlist " style="list-style-type: disc;"><li class="listitem"><p>An attribute set defining agents</p></li><li class="listitem"><p>A path to a directory containing multiple agent files</p></li></ul></div><p>If an attribute set is used, the attribute name becomes the agent filename,
|
||||
and the value is either:</p><div class="itemizedlist"><ul class="itemizedlist " style="list-style-type: disc;"><li class="listitem"><p>Inline content as a string (creates <code class="literal">opencode/agent/<name>.md</code>)</p></li><li class="listitem"><p>A path to a file (creates <code class="literal">opencode/agent/<name>.md</code>)</p></li></ul></div><p>If a path is used, it is expected to contain agent files.
|
||||
The directory is symlinked to <code class="filename">$XDG_CONFIG_HOME/opencode/agent/</code>.</p>
|
||||
|
||||
<p><span class="emphasis"><em>Type:</em></span>
|
||||
attribute set of (strings concatenated with “\n” or absolute path)</p>
|
||||
(attribute set of (strings concatenated with “\n” or absolute path)) or absolute path</p>
|
||||
|
||||
<p><span class="emphasis"><em>Default:</em></span>
|
||||
<code class="literal">{ }</code></p>
|
||||
@@ -62488,12 +62488,12 @@ attribute set of (strings concatenated with “\n” or absolute path)</p>
|
||||
</span>
|
||||
</dt>
|
||||
<dd>
|
||||
<p>Custom commands for opencode.
|
||||
The attribute name becomes the command filename, and the value is either:</p><div class="itemizedlist"><ul class="itemizedlist " style="list-style-type: disc;"><li class="listitem"><p>Inline content as a string</p></li><li class="listitem"><p>A path to a file containing the command content
|
||||
Commands are stored in <code class="filename">$XDG_CONFIG_HOME/opencode/command/</code> directory.</p></li></ul></div>
|
||||
<p>Custom commands for opencode.</p><p>This option can either be:</p><div class="itemizedlist"><ul class="itemizedlist " style="list-style-type: disc;"><li class="listitem"><p>An attribute set defining commands</p></li><li class="listitem"><p>A path to a directory containing multiple command files</p></li></ul></div><p>If an attribute set is used, the attribute name becomes the command filename,
|
||||
and the value is either:</p><div class="itemizedlist"><ul class="itemizedlist " style="list-style-type: disc;"><li class="listitem"><p>Inline content as a string (creates <code class="literal">opencode/command/<name>.md</code>)</p></li><li class="listitem"><p>A path to a file (creates <code class="literal">opencode/command/<name>.md</code>)</p></li></ul></div><p>If a path is used, it is expected to contain command files.
|
||||
The directory is symlinked to <code class="filename">$XDG_CONFIG_HOME/opencode/command/</code>.</p>
|
||||
|
||||
<p><span class="emphasis"><em>Type:</em></span>
|
||||
attribute set of (strings concatenated with “\n” or absolute path)</p>
|
||||
(attribute set of (strings concatenated with “\n” or absolute path)) or absolute path</p>
|
||||
|
||||
<p><span class="emphasis"><em>Default:</em></span>
|
||||
<code class="literal">{ }</code></p>
|
||||
@@ -62666,18 +62666,65 @@ containing a <code class="filename">SKILL.md</code>. The directory is symlinked
|
||||
</span>
|
||||
</dt>
|
||||
<dd>
|
||||
<p>Custom themes for opencode. The attribute name becomes the theme
|
||||
filename, and the value is either:</p><div class="itemizedlist"><ul class="itemizedlist " style="list-style-type: disc;"><li class="listitem"><p>An attribute set, that is converted to a json</p></li><li class="listitem"><p>A path to a file containing the content
|
||||
Themes are stored in <code class="filename">$XDG_CONFIG_HOME/opencode/themes/</code> directory.
|
||||
Set <code class="literal">programs.opencode.settings.theme</code> to enable the custom theme.
|
||||
See <a class="link" href="https://opencode.ai/docs/themes/" target="_top">https://opencode.ai/docs/themes/</a> for the documentation.</p></li></ul></div>
|
||||
<p>Custom themes for opencode.</p><p>This option can either be:</p><div class="itemizedlist"><ul class="itemizedlist " style="list-style-type: disc;"><li class="listitem"><p>An attribute set defining themes</p></li><li class="listitem"><p>A path to a directory containing multiple theme files</p></li></ul></div><p>If an attribute set is used, the attribute name becomes the theme filename,
|
||||
and the value is either:</p><div class="itemizedlist"><ul class="itemizedlist " style="list-style-type: disc;"><li class="listitem"><p>An attribute set that is converted to a JSON file (creates <code class="literal">opencode/themes/<name>.json</code>)</p></li><li class="listitem"><p>A path to a file (creates <code class="literal">opencode/themes/<name>.json</code>)</p></li></ul></div><p>If a path is used, it is expected to contain theme files.
|
||||
The directory is symlinked to <code class="filename">$XDG_CONFIG_HOME/opencode/themes/</code>.</p><p>Set <code class="literal">programs.opencode.settings.theme</code> to enable the custom theme.
|
||||
See <a class="link" href="https://opencode.ai/docs/themes/" target="_top">https://opencode.ai/docs/themes/</a> for the documentation.</p>
|
||||
|
||||
<p><span class="emphasis"><em>Type:</em></span>
|
||||
attribute set of (JSON value or absolute path)</p>
|
||||
(attribute set of (JSON value or absolute path)) or absolute path</p>
|
||||
|
||||
<p><span class="emphasis"><em>Default:</em></span>
|
||||
<code class="literal">{ }</code></p>
|
||||
|
||||
<p><span class="emphasis"><em>Declared by:</em></span></p>
|
||||
<table border="0" summary="Simple list" class="simplelist">
|
||||
<tr><td>
|
||||
<code class="filename"><a class="filename" href="https://github.com/nix-community/home-manager/blob/master/modules/programs/opencode.nix" target="_top">
|
||||
<home-manager/modules/programs/opencode.nix>
|
||||
</a></code>
|
||||
</td></tr>
|
||||
</table>
|
||||
</dd>
|
||||
<dt>
|
||||
<span class="term">
|
||||
<a id="opt-programs.opencode.tools"></a><a class="term" href="options.xhtml#opt-programs.opencode.tools"><code class="option">programs.opencode.tools</code>
|
||||
</a>
|
||||
</span>
|
||||
</dt>
|
||||
<dd>
|
||||
<p>Custom tools for opencode.</p><p>This option can either be:</p><div class="itemizedlist"><ul class="itemizedlist " style="list-style-type: disc;"><li class="listitem"><p>An attribute set defining tools</p></li><li class="listitem"><p>A path to a directory containing multiple tool files</p></li></ul></div><p>If an attribute set is used, the attribute name becomes the tool filename,
|
||||
and the value is either:</p><div class="itemizedlist"><ul class="itemizedlist " style="list-style-type: disc;"><li class="listitem"><p>Inline content as a string (creates <code class="literal">opencode/tool/<name>.ts</code>)</p></li><li class="listitem"><p>A path to a file (creates <code class="literal">opencode/tool/<name>.ts</code> or <code class="literal">opencode/tool/<name>.js</code>)</p></li></ul></div><p>If a path is used, it is expected to contain tool files.
|
||||
The directory is symlinked to <code class="filename">$XDG_CONFIG_HOME/opencode/tool/</code>.</p><p>See <a class="link" href="https://opencode.ai/docs/tools/" target="_top">https://opencode.ai/docs/tools/</a> for the documentation.</p>
|
||||
|
||||
<p><span class="emphasis"><em>Type:</em></span>
|
||||
(attribute set of (strings concatenated with “\n” or absolute path)) or absolute path</p>
|
||||
|
||||
<p><span class="emphasis"><em>Default:</em></span>
|
||||
<code class="literal">{ }</code></p>
|
||||
|
||||
<p><span class="emphasis"><em>Example:</em></span></p><pre><code class="programlisting">{
|
||||
database-query = ''
|
||||
import { tool } from "@opencode-ai/plugin"
|
||||
|
||||
export default tool({
|
||||
description: "Query the project database",
|
||||
args: {
|
||||
query: tool.schema.string().describe("SQL query to execute"),
|
||||
},
|
||||
async execute(args) {
|
||||
// Your database logic here
|
||||
return `Executed query: ${args.query}`
|
||||
},
|
||||
})
|
||||
'';
|
||||
|
||||
# Or reference an existing file
|
||||
api-client = ./tools/api-client.ts;
|
||||
}
|
||||
|
||||
</code></pre>
|
||||
|
||||
<p><span class="emphasis"><em>Declared by:</em></span></p>
|
||||
<table border="0" summary="Simple list" class="simplelist">
|
||||
<tr><td>
|
||||
|
||||
Reference in New Issue
Block a user