From de043370ff70807342a7d0fa0a67d57b8526938e Mon Sep 17 00:00:00 2001 From: Spencer Baugh Date: Tue, 25 Aug 2020 23:22:18 -0400 Subject: [PATCH] add .envrc and shell.nix for direnv+Nix-based development With this .envrc and shell.nix, merely cd-ing into the trio directory sets up PATH and PYTHONPATH local to that directory, and runs setup.py develop, such that one can do trio development with all dependencies provided from Nix. The shell.nix is concise because it just takes advantage of the existing package for trio in Nixpkgs. I don't expect this commit to be accepted; just submitting this for reference. --- .envrc | 1 + shell.nix | 5 +++++ 2 files changed, 6 insertions(+) create mode 100644 .envrc create mode 100644 shell.nix diff --git a/.envrc b/.envrc new file mode 100644 index 0000000000..4a4726a5c7 --- /dev/null +++ b/.envrc @@ -0,0 +1 @@ +use_nix diff --git a/shell.nix b/shell.nix new file mode 100644 index 0000000000..a734f66572 --- /dev/null +++ b/shell.nix @@ -0,0 +1,5 @@ +{ pkgs ? import {}}: + +pkgs.python37Packages.trio.overrideAttrs (oldAttrs: { + src = ./.; +})