aboutsummaryrefslogtreecommitdiff
path: root/flake.nix
diff options
context:
space:
mode:
authorAlexander Kassouni <alex@kassouni.net>2026-09-05 17:51:13 -0700
committerAlexander Kassouni <alex@kassouni.net>2026-09-05 17:51:13 -0700
commit46227e2003de28202cc4e82bca4f7f4745476c4e (patch)
treefe450ac33ffa13747613c3cfdf36ea24b3036c46 /flake.nix
init
Diffstat (limited to 'flake.nix')
-rw-r--r--flake.nix41
1 files changed, 41 insertions, 0 deletions
diff --git a/flake.nix b/flake.nix
new file mode 100644
index 0000000..c3900bb
--- /dev/null
+++ b/flake.nix
@@ -0,0 +1,41 @@
+{
+ description = "animalese - Animal Crossing style speech synthesis";
+
+ inputs = {
+ nixpkgs.url = "github:nixos/nixpkgs?ref=nixos-unstable";
+ };
+
+ outputs = inputs: {
+ packages = builtins.mapAttrs (system: pkgs: {
+ animalese = pkgs.rustPlatform.buildRustPackage {
+ pname = "animalese";
+ version = "0.1.0";
+
+ src = inputs.self;
+ cargoLock.lockFile = ./Cargo.lock;
+
+ meta = {
+ description = "Animal Crossing style speech synthesis";
+ mainProgram = "animalese";
+ };
+ };
+
+ default = inputs.self.packages.${system}.animalese;
+ }) inputs.nixpkgs.legacyPackages;
+
+ devShells = builtins.mapAttrs (system: pkgs: {
+ default = pkgs.mkShell {
+ packages = [
+ pkgs.cargo
+ pkgs.rustc
+ pkgs.clippy
+ pkgs.rustfmt
+ pkgs.rust-analyzer
+ ];
+
+ # so rust-analyzer can find the standard library sources
+ RUST_SRC_PATH = "${pkgs.rustPlatform.rustLibSrc}";
+ };
+ }) inputs.nixpkgs.legacyPackages;
+ };
+}