From 64f812b2f0ecd1b6759d8f2e4a9f05905f52e99d Mon Sep 17 00:00:00 2001 From: Vincent Ambo Date: Thu, 8 Dec 2022 16:55:47 +0300 Subject: refactor(tvix): provide a combined //tvix:shell mkShell target Manually maintained shell target based on the previous "loose" `shell.nix` file. We might want to have a function that combines the dependencies of all the targets automatically, but at a quick glance that was actually non-trivial so I'm leaving it as an exercise for someone else. Change-Id: I74754940088f1b58e3b6754fb782470c80ea4292 Reviewed-on: https://cl.tvl.fyi/c/depot/+/7540 Autosubmit: tazjin Reviewed-by: sterni Tested-by: BuildkiteCI --- tvix/default.nix | 20 ++++++++++++++++++++ tvix/shell.nix | 17 ----------------- 2 files changed, 20 insertions(+), 17 deletions(-) delete mode 100644 tvix/shell.nix diff --git a/tvix/default.nix b/tvix/default.nix index 7225bfb89e75..23ce0592ceb6 100644 --- a/tvix/default.nix +++ b/tvix/default.nix @@ -7,4 +7,24 @@ inherit pkgs; nixpkgs = pkgs.path; }; + + # Provide a shell for the combined dependencies of all Tvix Rust + # projects. Note that as this is manually maintained it may be + # lacking something, but it is required for some people's workflows. + # + # This shell can be entered with e.g. `mg shell //tvix:shell`. + shell = pkgs.mkShell { + name = "tvix-rust-dev-env"; + packages = [ + pkgs.buf-language-server + pkgs.cargo + pkgs.clippy + pkgs.rust-analyzer + pkgs.rustc + pkgs.rustfmt + pkgs.protobuf + ]; + }; + + meta.ci.targets = [ "shell" ]; } diff --git a/tvix/shell.nix b/tvix/shell.nix deleted file mode 100644 index e8d1e5e383ea..000000000000 --- a/tvix/shell.nix +++ /dev/null @@ -1,17 +0,0 @@ -{ depot ? import ../. { } -, pkgs ? depot.third_party.nixpkgs -, ... -}: - -pkgs.mkShell { - name = "tvix-eval-dev-env"; - packages = [ - pkgs.buf-language-server - pkgs.cargo - pkgs.clippy - pkgs.rust-analyzer - pkgs.rustc - pkgs.rustfmt - pkgs.protobuf - ]; -} -- cgit 1.4.1