2013-11-17 15:00:12 +01:00
|
|
|
{ fetchurl, stdenv, go }:
|
|
|
|
|
|
|
|
let
|
2015-02-21 18:36:07 +01:00
|
|
|
version = "2.6.0";
|
2013-11-17 15:00:12 +01:00
|
|
|
in
|
|
|
|
stdenv.mkDerivation {
|
|
|
|
name = "direnv-${version}";
|
|
|
|
src = fetchurl {
|
|
|
|
url = "http://github.com/zimbatm/direnv/archive/v${version}.tar.gz";
|
|
|
|
name = "direnv-${version}.tar.gz";
|
2015-02-21 18:36:07 +01:00
|
|
|
sha256 = "b85aac4d6a4ddf2daf193aabb3b2faf89e56507d33d763ab74cc7eb0b524ac03";
|
2013-11-17 15:00:12 +01:00
|
|
|
};
|
|
|
|
|
|
|
|
buildInputs = [ go ];
|
|
|
|
|
|
|
|
buildPhase = "make";
|
|
|
|
installPhase = "make install DESTDIR=$out";
|
|
|
|
|
|
|
|
meta = {
|
|
|
|
description = "a shell extension that manages your environment";
|
|
|
|
longDescription = ''
|
|
|
|
Once hooked into your shell direnv is looking for an .envrc file in your
|
|
|
|
current directory before every prompt.
|
|
|
|
|
|
|
|
If found it will load the exported environment variables from that bash
|
|
|
|
script into your current environment, and unload them if the .envrc is
|
|
|
|
not reachable from the current path anymore.
|
|
|
|
|
|
|
|
In short, this little tool allows you to have project-specific
|
|
|
|
environment variables.
|
|
|
|
'';
|
|
|
|
homepage = http://direnv.net;
|
|
|
|
license = stdenv.lib.licenses.mit;
|
|
|
|
maintainers = [ stdenv.lib.maintainers.zimbatm ];
|
2014-07-03 20:15:09 +02:00
|
|
|
platforms = go.meta.platforms;
|
2013-11-17 15:00:12 +01:00
|
|
|
};
|
|
|
|
}
|