From 4234ef550c6646ef34b6888730b05173a8648334 Mon Sep 17 00:00:00 2001 From: Jason Miller Date: Sun, 8 Mar 2020 00:16:53 -0500 Subject: vimacs: init at 2016-03-24 --- pkgs/applications/editors/vim/vimacs.nix | 34 ++++++++++++++++++++++++++++++++ 1 file changed, 34 insertions(+) create mode 100644 pkgs/applications/editors/vim/vimacs.nix (limited to 'pkgs/applications/editors/vim/vimacs.nix') diff --git a/pkgs/applications/editors/vim/vimacs.nix b/pkgs/applications/editors/vim/vimacs.nix new file mode 100644 index 00000000000..d067b418121 --- /dev/null +++ b/pkgs/applications/editors/vim/vimacs.nix @@ -0,0 +1,34 @@ +{ stdenv, config, vim_configurable, macvim, vimPlugins +, useMacvim ? stdenv.isDarwin && (config.vimacs.macvim or true) +, vimacsExtraArgs ? "" }: + +stdenv.mkDerivation rec { + pname = "vimacs"; + version = vimPackage.version; + vimPackage = if useMacvim then macvim else vim_configurable; + + buildInputs = [ vimPackage vimPlugins.vimacs ]; + + buildCommand = '' + mkdir -p "$out"/bin + cp "${vimPlugins.vimacs}"/share/vim-plugins/vimacs/bin/vim $out/bin/vimacs + substituteInPlace "$out"/bin/vimacs \ + --replace '-vim}' '-@bin@/bin/vim}' \ + --replace '-gvim}' '-@bin@/bin/vim -g}' \ + --replace '--cmd "let g:VM_Enabled = 1"' \ + '--cmd "let g:VM_Enabled = 1" --cmd "set rtp^=@rtp@" ${vimacsExtraArgs}' \ + --replace @rtp@ ${vimPlugins.vimacs.rtp} \ + --replace @bin@ ${vimPackage} + for prog in vm gvm gvimacs vmdiff vimacsdiff + do + ln -s "$out"/bin/vimacs $out/bin/$prog + done + ''; + + meta = with stdenv.lib; { + description = "Vim-Improved eMACS: Emacs emulation for Vim"; + homepage = "http://algorithm.com.au/code/vimacs"; + license = licenses.gpl2Plus; + maintainers = with stdenv.lib.maintainers; [ millerjason ]; + }; +} -- cgit 1.4.1