+devshell with opencode rules
This commit is contained in:
21
flake.nix
21
flake.nix
@@ -4,13 +4,21 @@
|
||||
inputs = {
|
||||
nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable";
|
||||
flake-utils.url = "github:numtide/flake-utils";
|
||||
|
||||
m3ta-nixpkgs.url = "git+https://code.m3ta.dev/m3tam3re/nixpkgs";
|
||||
agents = {
|
||||
url = "git+https://code.m3ta.dev/m3tam3re/AGENTS";
|
||||
flake = false;
|
||||
};
|
||||
};
|
||||
|
||||
outputs = {
|
||||
self,
|
||||
nixpkgs,
|
||||
flake-utils,
|
||||
}:
|
||||
m3ta-nixpkgs,
|
||||
agents,
|
||||
} @ inputs:
|
||||
flake-utils.lib.eachDefaultSystem (system: let
|
||||
pkgs = nixpkgs.legacyPackages.${system};
|
||||
pythonPackages = pkgs.python311Packages;
|
||||
@@ -74,6 +82,12 @@
|
||||
license = pkgs.lib.licenses.mit;
|
||||
};
|
||||
};
|
||||
|
||||
m3taLib = m3ta-nixpkgs.lib.x86_64-linux;
|
||||
rules = m3taLib.opencode-rules.mkOpencodeRules {
|
||||
inherit agents;
|
||||
languages = ["python"];
|
||||
};
|
||||
in {
|
||||
packages.default = zugferd-service;
|
||||
packages.zugferd-service = zugferd-service;
|
||||
@@ -96,6 +110,11 @@
|
||||
]))
|
||||
pkgs.python311Packages.pip
|
||||
];
|
||||
|
||||
inherit (rules) instructions;
|
||||
shellHook = ''
|
||||
${rules.shellHook}
|
||||
'';
|
||||
};
|
||||
});
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user