diff options
author | Alyssa Ross <hi@alyssa.is> | 2020-05-14 18:16:07 +0000 |
---|---|---|
committer | Alyssa Ross <hi@alyssa.is> | 2020-05-14 18:17:03 +0000 |
commit | d2753504ef2bd591ade35851dad31d3aac117e19 (patch) | |
tree | 7e76ce6002ca857231dd0e49f6b041629a99a1da /shells | |
parent | aea52af2b062986b840ff4e6f4bef84a1ac8e0a1 (diff) | |
download | nixlib-d2753504ef2bd591ade35851dad31d3aac117e19.tar nixlib-d2753504ef2bd591ade35851dad31d3aac117e19.tar.gz nixlib-d2753504ef2bd591ade35851dad31d3aac117e19.tar.bz2 nixlib-d2753504ef2bd591ade35851dad31d3aac117e19.tar.lz nixlib-d2753504ef2bd591ade35851dad31d3aac117e19.tar.xz nixlib-d2753504ef2bd591ade35851dad31d3aac117e19.tar.zst nixlib-d2753504ef2bd591ade35851dad31d3aac117e19.zip |
shells: init
Diffstat (limited to 'shells')
-rw-r--r-- | shells/README | 27 | ||||
-rw-r--r-- | shells/linux.nix | 15 |
2 files changed, 42 insertions, 0 deletions
diff --git a/shells/README b/shells/README new file mode 100644 index 000000000000..388ce777448e --- /dev/null +++ b/shells/README @@ -0,0 +1,27 @@ + ======== + <shells> + ======== + +This is a collection of Nix expressions for use with nix-shell. + +The idea is that if I'm working on a bunch of Rust programs, I don't +want to have to copy or write a shell.nix with all the standard Rust +stuff for every program -- rustc, cargo, rust-analyzer, etc. + +So instead of doing that, I have a "shells" directory in my NIX_PATH, +containing a "rust.nix" file. When I just want to build some program +as a one off, I'll just do this: + + nix-shell rust.nix + +And if it's something I'm going to be working on long term, and I want +to use lorri and stuff, I can create a shell.nix that just contains + + import <shells/rust.nix> + +I could even extend it with project-specific dependencies like +pkg-config or OpenSSL. + +Either way, I can now just modify rust.nix to add things to all my +Rust environments at once, and store these environments with all my +other Nix configuration. Yay! diff --git a/shells/linux.nix b/shells/linux.nix new file mode 100644 index 000000000000..35d3532a1c16 --- /dev/null +++ b/shells/linux.nix @@ -0,0 +1,15 @@ +{ pkgs ? import ../. {} }: +with pkgs; + +mkShell { + buildInputs = [ + bison flex bc libelf openssl + + # For make {n,menu}config + ncurses pkgconfig + + # For documentation + graphviz imagemagick python3Packages.sphinx python3Packages.sphinx_rtd_theme + texlive.combined.scheme-minimal + ]; +} |