herdr: distribute the SKILL.md file
By distributing the SKILL.md file, we can configure LLM tooling to pick
up the skill from the filesystem instead of either manually keeping
a local copy in sync or doing a remote fetch.
An example from how this could be used from home-manager:
programs.opencode.settings.skills.paths = [
"${pkgs.herdr}/share/herdr/skills"
];
There doesn't seem to be a convention within nixpkgs of how to
distribute skills, so I've taken the liberty of using the $out/share
directory.
Signed-off-by: Tristan Partin <tristan@partin.io>
This commit is contained in:
@@ -55,7 +55,10 @@ rustPlatform.buildRustPackage (finalAttrs: {
|
||||
chmod -R u+w "$ZIG_GLOBAL_CACHE_DIR/p"
|
||||
'';
|
||||
|
||||
postInstall = lib.optionalString (stdenv.buildPlatform.canExecute stdenv.hostPlatform) ''
|
||||
postInstall = ''
|
||||
install -Dm444 SKILL.md -t $out/share/herdr/skills/herdr
|
||||
''
|
||||
+ lib.optionalString (stdenv.buildPlatform.canExecute stdenv.hostPlatform) ''
|
||||
installShellCompletion --cmd herdr \
|
||||
--bash <("$out/bin/herdr" completion bash) \
|
||||
--fish <("$out/bin/herdr" completion fish) \
|
||||
|
||||
Reference in New Issue
Block a user