fix nix functional test & add mole to brew, del osgrep bd
This commit is contained in:
parent
63d0716aaa
commit
d8ad4e916d
11 changed files with 13 additions and 7398 deletions
|
|
@ -140,7 +140,7 @@
|
|||
else
|
||||
pkgs.python3;
|
||||
|
||||
# Custom packages (osgrep, beads, etc.)
|
||||
# Custom packages
|
||||
customPkgs = import ./packages { inherit pkgs lib llm-agents; };
|
||||
|
||||
# Common arguments passed to all devshell imports
|
||||
|
|
@ -173,6 +173,6 @@
|
|||
let
|
||||
pkgs = mkPkgs system;
|
||||
customPkgs = import ./packages { inherit pkgs lib llm-agents; };
|
||||
in { inherit (customPkgs) osgrep opencode beads; });
|
||||
in { inherit (customPkgs) opencode; });
|
||||
};
|
||||
}
|
||||
|
|
|
|||
|
|
@ -16,7 +16,7 @@ in {
|
|||
};
|
||||
brews = mkOption {
|
||||
type = types.listOf types.str;
|
||||
default = [ "curl" "yt-dlp" "infisical" ];
|
||||
default = [ "curl" "yt-dlp" "infisical" "mole" ];
|
||||
description = "Homebrew formulae to install.";
|
||||
};
|
||||
casks = mkOption {
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
imports = [ ./homebrew.nix ./devtools.nix ];
|
||||
|
||||
nix = {
|
||||
package = pkgs.nix;
|
||||
package = pkgs.nixVersions.nix_2_28;
|
||||
extraOptions = ''
|
||||
keep-derivations = true
|
||||
keep-outputs = true
|
||||
|
|
|
|||
|
|
@ -21,6 +21,7 @@
|
|||
nil # Nix LSP
|
||||
pyright
|
||||
nodePackages.typescript-language-server
|
||||
mdx-language-server
|
||||
rust-analyzer
|
||||
gopls
|
||||
clang-tools # provides clangd
|
||||
|
|
|
|||
|
|
@ -26,6 +26,7 @@ return {
|
|||
jsonc = { "prettierd", "prettier", stop_after_first = true },
|
||||
yaml = { "prettierd", "prettier", stop_after_first = true },
|
||||
markdown = { "prettierd", "prettier", stop_after_first = true },
|
||||
mdx = { "prettierd", "prettier", stop_after_first = true },
|
||||
html = { "prettierd", "prettier", stop_after_first = true },
|
||||
css = { "prettierd", "prettier", stop_after_first = true },
|
||||
scss = { "prettierd", "prettier", stop_after_first = true },
|
||||
|
|
|
|||
|
|
@ -101,6 +101,11 @@ return {
|
|||
lspconfig.clangd.setup({
|
||||
capabilities = capabilities,
|
||||
})
|
||||
|
||||
-- MDX
|
||||
lspconfig.mdx_analyzer.setup({
|
||||
capabilities = capabilities,
|
||||
})
|
||||
end,
|
||||
},
|
||||
}
|
||||
|
|
|
|||
|
|
@ -27,6 +27,7 @@ return {
|
|||
"luap",
|
||||
"markdown",
|
||||
"markdown_inline",
|
||||
"mdx",
|
||||
"nix",
|
||||
"norg",
|
||||
"printf",
|
||||
|
|
|
|||
|
|
@ -4,8 +4,5 @@ let
|
|||
system = pkgs.stdenv.hostPlatform.system;
|
||||
llmPkgs = llm-agents.packages.${system};
|
||||
in {
|
||||
osgrep = pkgs.callPackage ./osgrep.nix { };
|
||||
opencode = llmPkgs.opencode;
|
||||
# Source beads from llm-agents.nix
|
||||
beads = llmPkgs.beads;
|
||||
}
|
||||
|
|
|
|||
7292
packages/osgrep-package-lock.json
generated
7292
packages/osgrep-package-lock.json
generated
File diff suppressed because it is too large
Load diff
|
|
@ -1,32 +0,0 @@
|
|||
{ lib, buildNpmPackage, fetchurl, python3 }:
|
||||
|
||||
buildNpmPackage rec {
|
||||
pname = "osgrep";
|
||||
version = "0.5.16";
|
||||
|
||||
src = fetchurl {
|
||||
url = "https://registry.npmjs.org/${pname}/-/${pname}-${version}.tgz";
|
||||
hash = "sha256-V23PNxtMCdRaqr4uDOs0rptmSROUrUO7I9HazoGqUCQ=";
|
||||
};
|
||||
|
||||
sourceRoot = "package";
|
||||
|
||||
postPatch = ''
|
||||
cp ${./osgrep-package-lock.json} package-lock.json
|
||||
'';
|
||||
|
||||
npmDepsHash = "sha256-JDeZ3kcsbcZM//0846i1gsvoAgMpIpN8c160cp7wB5s=";
|
||||
|
||||
npmFlags = [ "--legacy-peer-deps" ];
|
||||
|
||||
dontNpmBuild = true; # Already built in npm package
|
||||
|
||||
nativeBuildInputs = [ python3 ];
|
||||
|
||||
meta = {
|
||||
description = "Semantic grep for AI agents";
|
||||
homepage = "https://github.com/Ryandonofrio3/osgrep";
|
||||
license = lib.licenses.asl20;
|
||||
mainProgram = "osgrep";
|
||||
};
|
||||
}
|
||||
|
|
@ -1,56 +1,9 @@
|
|||
{ pkgs, lib, customPkgs, ... }:
|
||||
|
||||
let
|
||||
# Get Beads package from custom packages
|
||||
beadsPkg = customPkgs.beads;
|
||||
|
||||
# Helper script to show Beads project status
|
||||
beadsStatus = pkgs.writeShellScriptBin "beads-status" ''
|
||||
if [ ! -d ".beads" ]; then
|
||||
echo "Not a Beads project (no .beads directory found)"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
echo "=== Beads Project Status ==="
|
||||
echo ""
|
||||
echo "Ready tasks:"
|
||||
${beadsPkg}/bin/bd ready --json | ${pkgs.jq}/bin/jq -r '.[] | " - [\(.id)] \(.title) (\(.type))"'
|
||||
echo ""
|
||||
echo "In Progress:"
|
||||
${beadsPkg}/bin/bd list --status in-progress --json | ${pkgs.jq}/bin/jq -r '.[] | " - [\(.id)] \(.title)"'
|
||||
echo ""
|
||||
echo "For full details, run: bd list --json | jq"
|
||||
'';
|
||||
|
||||
# Helper script to generate full project context for AI agents
|
||||
beadsContext = pkgs.writeShellScriptBin "beads-context" ''
|
||||
if [ ! -d ".beads" ]; then
|
||||
echo "Not a Beads project (no .beads directory found)"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
echo "=== Beads Project Context ==="
|
||||
echo ""
|
||||
echo "All issues:"
|
||||
${beadsPkg}/bin/bd list --json | ${pkgs.jq}/bin/jq '.'
|
||||
echo ""
|
||||
echo "Dependency tree (first ready task):"
|
||||
ready_id=$(${beadsPkg}/bin/bd ready --json | ${pkgs.jq}/bin/jq -r '.[0].id // empty')
|
||||
if [ -n "$ready_id" ]; then
|
||||
${beadsPkg}/bin/bd dep tree "$ready_id"
|
||||
else
|
||||
echo "No ready tasks"
|
||||
fi
|
||||
'';
|
||||
|
||||
in pkgs.mkShell {
|
||||
pkgs.mkShell {
|
||||
name = "ai-agent";
|
||||
|
||||
packages = with pkgs; [
|
||||
# Custom packages
|
||||
customPkgs.beads
|
||||
customPkgs.osgrep
|
||||
|
||||
# Version control
|
||||
git
|
||||
jujutsu
|
||||
|
|
@ -62,10 +15,6 @@ in pkgs.mkShell {
|
|||
|
||||
# JSON processing
|
||||
jq
|
||||
|
||||
# Helper scripts
|
||||
beadsStatus
|
||||
beadsContext
|
||||
];
|
||||
|
||||
shellHook = ''
|
||||
|
|
@ -77,22 +26,7 @@ in pkgs.mkShell {
|
|||
echo "AI Agent development shell loaded"
|
||||
echo ""
|
||||
echo "Available tools:"
|
||||
echo " bd - Beads CLI (issue tracker)"
|
||||
echo " beads-status - Show project status summary"
|
||||
echo " beads-context - Generate full context for AI"
|
||||
echo " osgrep - Semantic code search"
|
||||
echo " jj/git - Version control"
|
||||
echo " rg/ast-grep - Code search"
|
||||
echo ""
|
||||
echo "Quick start:"
|
||||
echo " bd init - Initialize Beads in current project"
|
||||
echo " bd create - Create new issue"
|
||||
echo " bd ready - Show ready tasks"
|
||||
echo " bd --help - Full command reference"
|
||||
echo ""
|
||||
echo "Nushell helpers (if in nushell):"
|
||||
echo " bd-init - Safe init with git checks"
|
||||
echo " bd-ready - View ready tasks (structured)"
|
||||
echo " bd-sync - Sync database with git"
|
||||
'';
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue