From 3c3c631a450106e7936b717d0170b4eadd3b0fb3 Mon Sep 17 00:00:00 2001 From: "Jason \"Don\" O'Conal" Date: Mon, 16 Sep 2013 21:34:49 +1000 Subject: [PATCH] vimPlugins.vimshell: add expression vimPlugins.vimproc: add expression close #978 --- pkgs/misc/vim-plugins/default.nix | 62 +++++++++++++++++++++++++++++-- 1 file changed, 59 insertions(+), 3 deletions(-) diff --git a/pkgs/misc/vim-plugins/default.nix b/pkgs/misc/vim-plugins/default.nix index af4363f9217e..b17b8490a0b1 100644 --- a/pkgs/misc/vim-plugins/default.nix +++ b/pkgs/misc/vim-plugins/default.nix @@ -1,4 +1,4 @@ -{ fetchurl, stdenv, python, cmake, vim, perl, ruby, unzip }: +{ fetchurl, stdenv, python, cmake, vim, perl, ruby, unzip, which }: /* About Vim and plugins @@ -90,14 +90,13 @@ let vimHelpTags = '' installPhase = '' target=$out/vim-plugins/$path ensureDir $out/vim-plugins - ls -l cp -r . $target ${vimHelpTags} vimHelpTags $target ''; }); -in +in rec { @@ -251,4 +250,61 @@ in path = "xdebug"; postInstall = false; }; + + vimshell = simpleDerivation rec { + version = "9.2"; + name = "vimshell-${version}"; + + meta = with stdenv.lib; { + description = "An extreme shell that doesn't depend on external shells and is written completely in Vim script"; + homepage = https://github.com/Shougo/vimshell.vim; + repositories.git = https://github.com/Shougo/vimshell.vim.git; + license = licenses.gpl3; + maintainers = with maintainers; [ lovek323 ]; + platforms = platforms.unix; + }; + + src = fetchurl { + url = "https://github.com/Shougo/vimshell.vim/archive/ver.${version}.tar.gz"; + sha256 = "1pbwxdhpv6pr09b6hwkgy7grpmpwlqpsgsawl38r40q6yib8zb4a"; + }; + + buildInputs = [ vimproc ]; + + preBuild = '' + sed -ie '1 i\ + set runtimepath+=${vimproc}/vim-plugins/vimproc\ + ' autoload/vimshell.vim + ''; + + path = "vimshell"; + }; + + vimproc = simpleDerivation rec { + version = "5cf4c6bfe9bf0649159b5648d736d54c96e99b3e"; + name = "vimproc-${version}"; + + meta = with stdenv.lib; { + description = "An asynchronous execution library for Vim"; + homepage = https://github.com/Shougo/vimproc.vim; + repositories.git = https://github.com/Shougo/vimproc.vim.git; + license = licenses.gpl3; + maintainers = with maintainers; [ lovek323 ]; + platforms = platforms.unix; + }; + + src = fetchurl { + url = "${meta.homepage}/archive/${version}.tar.gz"; + sha256 = "0f76mc7v3656sf9syaq1rxzk3dqz6i5w190wgj15sjjnapzd956p"; + }; + + buildInputs = [ which ]; + + buildPhase = '' + sed -i 's/vimproc_mac\.so/vimproc_unix\.so/' autoload/vimproc.vim + make -f make_unix.mak + ''; + + path = "vimproc"; + }; }