|
1 | 1 | { |
2 | 2 | description = "agents-workflow"; |
3 | 3 |
|
4 | | - inputs.nixpkgs.url = "github:NixOS/nixpkgs/nixpkgs-unstable"; |
| 4 | + inputs = { |
| 5 | + nixpkgs.url = "github:NixOS/nixpkgs/nixpkgs-unstable"; |
| 6 | + codex.url = "github:openai/codex"; |
| 7 | + codex.inputs.nixpkgs.follows = "nixpkgs"; |
| 8 | + }; |
5 | 9 |
|
6 | 10 | outputs = { |
7 | 11 | self, |
8 | 12 | nixpkgs, |
| 13 | + codex, |
9 | 14 | }: let |
10 | 15 | systems = ["x86_64-linux" "aarch64-linux" "x86_64-darwin" "aarch64-darwin"]; |
11 | 16 | forAllSystems = nixpkgs.lib.genAttrs systems; |
12 | 17 | in { |
13 | 18 | packages = forAllSystems ( |
14 | 19 | system: let |
15 | | - pkgs = import nixpkgs {inherit system;}; |
| 20 | + pkgs = import nixpkgs { |
| 21 | + inherit system; |
| 22 | + config.allowUnfree = true; # Allow unfree packages like claude-code |
| 23 | + }; |
16 | 24 | agent-task-script = pkgs.writeShellScriptBin "agent-task" '' |
17 | | - PATH=${pkgs.lib.makeBinPath [ pkgs.ruby pkgs.codex pkgs.goose ]}:$PATH |
| 25 | + PATH=${pkgs.lib.makeBinPath [ |
| 26 | + pkgs.ruby |
| 27 | + pkgs.goose-cli |
| 28 | + pkgs.claude-code |
| 29 | + pkgs.gemini-cli |
| 30 | + codex.packages.${system}.codex-rs |
| 31 | + ]}:$PATH |
18 | 32 | exec ruby ${./bin/agent-task} "$@" |
19 | 33 | ''; |
20 | 34 | get-task = pkgs.writeShellScriptBin "get-task" '' |
|
25 | 39 | ''; |
26 | 40 | agent-utils = pkgs.symlinkJoin { |
27 | 41 | name = "agent-utils"; |
28 | | - paths = [ get-task start-work ]; |
| 42 | + paths = [get-task start-work]; |
29 | 43 | }; |
30 | 44 | in { |
31 | 45 | agent-task = agent-task-script; |
|
42 | 56 | }); |
43 | 57 |
|
44 | 58 | devShells = forAllSystems (system: let |
45 | | - pkgs = import nixpkgs {inherit system;}; |
| 59 | + pkgs = import nixpkgs { |
| 60 | + inherit system; |
| 61 | + config.allowUnfree = true; # Allow unfree packages like claude-code |
| 62 | + }; |
46 | 63 | in { |
47 | 64 | default = pkgs.mkShell { |
48 | 65 | buildInputs = [ |
|
53 | 70 | pkgs.git |
54 | 71 | pkgs.fossil |
55 | 72 | pkgs.mercurial |
| 73 | + |
| 74 | + # AI Coding Assistants (latest versions from nixpkgs-unstable) |
| 75 | + pkgs.goose-cli # Goose AI coding assistant |
| 76 | + pkgs.claude-code # Claude Code - agentic coding tool |
| 77 | + pkgs.gemini-cli # Gemini CLI |
| 78 | + codex.packages.${system}.codex-rs # OpenAI Codex CLI (native Rust implementation) |
56 | 79 | ]; |
| 80 | + |
| 81 | + shellHook = '' |
| 82 | + echo "Agent workflow development environment loaded" |
| 83 | + ''; |
57 | 84 | }; |
58 | 85 | }); |
59 | 86 | }; |
|
0 commit comments