2021-02-05 12:39:41 +00:00
|
|
|
{ lib
|
|
|
|
, stdenv
|
2021-04-13 19:19:01 +01:00
|
|
|
|
|
|
|
# nixpkgs functions
|
|
|
|
, buildGoModule
|
|
|
|
, buildVimPluginFrom2Nix
|
2021-02-05 12:39:41 +00:00
|
|
|
, fetchFromGitHub
|
|
|
|
, fetchpatch
|
2021-04-13 19:19:01 +01:00
|
|
|
, fetchurl
|
|
|
|
, substituteAll
|
|
|
|
|
|
|
|
# Language dependencies
|
|
|
|
, python
|
|
|
|
, python3
|
2021-02-05 12:39:41 +00:00
|
|
|
, rustPlatform
|
2021-04-13 19:19:01 +01:00
|
|
|
|
|
|
|
# Misc dependencies
|
|
|
|
, Cocoa
|
|
|
|
, code-minimap
|
|
|
|
, dasht
|
|
|
|
, direnv
|
2021-02-05 12:39:41 +00:00
|
|
|
, fzf
|
2021-05-07 22:18:14 +01:00
|
|
|
, gnome
|
2021-06-01 16:59:57 +01:00
|
|
|
, himalaya
|
2021-04-13 19:19:01 +01:00
|
|
|
, khard
|
|
|
|
, languagetool
|
|
|
|
, llvmPackages
|
|
|
|
, meson
|
|
|
|
, nim
|
|
|
|
, nodePackages
|
2021-02-05 12:39:41 +00:00
|
|
|
, skim
|
2021-04-13 19:19:01 +01:00
|
|
|
, sqlite
|
2021-10-27 22:29:45 +01:00
|
|
|
, statix
|
2021-02-05 12:39:41 +00:00
|
|
|
, stylish-haskell
|
2021-04-13 19:19:01 +01:00
|
|
|
, tabnine
|
|
|
|
, vim
|
|
|
|
, which
|
|
|
|
, xkb-switch
|
|
|
|
, ycmd
|
2021-09-29 02:40:30 +01:00
|
|
|
, nodejs
|
2021-04-13 19:19:01 +01:00
|
|
|
|
2021-09-16 17:46:27 +01:00
|
|
|
# test dependencies
|
|
|
|
, neovim-unwrapped
|
|
|
|
|
2021-04-13 19:19:01 +01:00
|
|
|
# command-t dependencies
|
|
|
|
, rake
|
|
|
|
, ruby
|
|
|
|
|
|
|
|
# cpsm dependencies
|
2021-02-05 12:39:41 +00:00
|
|
|
, boost
|
2021-04-13 19:19:01 +01:00
|
|
|
, cmake
|
2021-02-05 12:39:41 +00:00
|
|
|
, icu
|
|
|
|
, ncurses
|
|
|
|
|
2021-04-13 19:19:01 +01:00
|
|
|
# LanguageClient-neovim dependencies
|
2021-02-05 12:39:41 +00:00
|
|
|
, CoreFoundation
|
|
|
|
, CoreServices
|
|
|
|
|
2021-09-06 10:23:03 +01:00
|
|
|
# nvim-treesitter dependencies
|
2021-03-16 18:39:23 +00:00
|
|
|
, tree-sitter
|
|
|
|
|
2021-04-13 19:19:01 +01:00
|
|
|
# sved dependencies
|
|
|
|
, glib
|
|
|
|
, gobject-introspection
|
|
|
|
, wrapGAppsHook
|
2018-10-31 17:46:59 +00:00
|
|
|
|
2021-04-13 19:19:01 +01:00
|
|
|
# vim-clap dependencies
|
|
|
|
, curl
|
|
|
|
, libgit2
|
|
|
|
, libiconv
|
|
|
|
, openssl
|
|
|
|
, pkg-config
|
2019-08-03 00:20:54 +01:00
|
|
|
|
2021-09-06 10:23:03 +01:00
|
|
|
# vim-go dependencies
|
2021-02-05 12:39:41 +00:00
|
|
|
, asmfmt
|
|
|
|
, delve
|
|
|
|
, errcheck
|
2021-04-13 19:19:01 +01:00
|
|
|
, gnused
|
|
|
|
, go-motion
|
|
|
|
, go-tools
|
|
|
|
, gocode
|
|
|
|
, gocode-gomod
|
2021-02-05 12:39:41 +00:00
|
|
|
, godef
|
2021-04-13 19:19:01 +01:00
|
|
|
, gogetdoc
|
|
|
|
, golangci-lint
|
2021-02-05 12:39:41 +00:00
|
|
|
, golint
|
|
|
|
, gomodifytags
|
2021-04-13 19:19:01 +01:00
|
|
|
, gopls
|
2021-02-05 12:39:41 +00:00
|
|
|
, gotags
|
|
|
|
, gotools
|
|
|
|
, iferr
|
2021-04-13 19:19:01 +01:00
|
|
|
, impl
|
|
|
|
, reftools
|
2021-09-06 10:23:03 +01:00
|
|
|
# must be lua51Packages
|
2021-08-08 15:55:24 +01:00
|
|
|
, luaPackages
|
2018-09-14 05:36:29 +01:00
|
|
|
}:
|
|
|
|
|
2018-12-27 10:12:48 +00:00
|
|
|
self: super: {
|
2018-09-14 05:36:29 +01:00
|
|
|
|
2021-02-05 12:39:41 +00:00
|
|
|
clang_complete = super.clang_complete.overrideAttrs (old: {
|
2018-09-14 05:36:29 +01:00
|
|
|
# In addition to the arguments you pass to your compiler, you also need to
|
|
|
|
# specify the path of the C++ std header (if you are using C++).
|
|
|
|
# These usually implicitly set by cc-wrapper around clang (pkgs/build-support/cc-wrapper).
|
|
|
|
# The linked ruby code shows generates the required '.clang_complete' for cmake based projects
|
|
|
|
# https://gist.github.com/Mic92/135e83803ed29162817fce4098dec144
|
|
|
|
preFixup = ''
|
2021-09-02 00:20:05 +01:00
|
|
|
substituteInPlace "$out"/plugin/clang_complete.vim \
|
llvmPackages: Multuple outputs for everythting
Also begin to start work on cross compilation, though that will have to
be finished later.
The patches are based on the first version of
https://reviews.llvm.org/D99484. It's very annoying to do the
back-porting but the review has uncovered nothing super major so I'm
fine sticking with what I've got.
Beyond making the outputs work, I also strove to re-sync the packages,
as they have been drifting pointlessly apart for some time.
----
Other misc notes, highly incomplete
- lvm-config-native and llvm-config are put in `dev` because they are
tools just for build time.
- Clang no longer has an lld dep. That was introduced in
db29857eb391ed002046090851a44c452b80bdbd, but if clang needs help
finding lld when it is used we should just pass it flags / put in the
resource dir. Providing it at build time increases critical path
length for no good reason.
----
A note on `nativeCC`:
`stdenv` takes tools from the previous stage, so:
1. `pkgsBuildBuild`: `(?1, x, x)`
2. `pkgsBuildBuild.stdenv.cc`: `(?0, ?1, x)`
while:
1. `pkgsBuildBuild`: `(?1, x, x)`
2. `pkgsBuildBuild.targetPackages`: `(x, x, ?2)`
3. `pkgsBuildBuild.targetPackages.stdenv.cc`: `(?1, x, x)`
2020-10-15 09:23:57 +01:00
|
|
|
--replace "let g:clang_library_path = '' + "''" + ''" "let g:clang_library_path='${llvmPackages.libclang.lib}/lib/libclang.so'"
|
2018-06-17 16:39:02 +01:00
|
|
|
|
2021-09-02 00:20:05 +01:00
|
|
|
substituteInPlace "$out"/plugin/libclang.py \
|
2018-06-17 16:39:02 +01:00
|
|
|
--replace "/usr/lib/clang" "${llvmPackages.clang.cc}/lib/clang"
|
2018-09-14 05:36:29 +01:00
|
|
|
'';
|
|
|
|
});
|
|
|
|
|
2021-02-05 12:39:41 +00:00
|
|
|
clighter8 = super.clighter8.overrideAttrs (old: {
|
2018-09-14 05:36:29 +01:00
|
|
|
preFixup = ''
|
2018-09-22 16:09:25 +01:00
|
|
|
sed "/^let g:clighter8_libclang_path/s|')$|${llvmPackages.clang.cc.lib}/lib/libclang.so')|" \
|
2021-09-02 00:20:05 +01:00
|
|
|
-i "$out"/plugin/clighter8.vim
|
2018-09-14 05:36:29 +01:00
|
|
|
'';
|
|
|
|
});
|
|
|
|
|
2021-10-01 19:26:44 +01:00
|
|
|
cmp-tabnine = super.cmp-tabnine.overrideAttrs (old: {
|
|
|
|
buildInputs = [ tabnine ];
|
|
|
|
|
|
|
|
postFixup = ''
|
|
|
|
mkdir -p $target/binaries/${tabnine.version}
|
|
|
|
ln -s ${tabnine}/bin/ $target/binaries/${tabnine.version}/${tabnine.passthru.platform}
|
|
|
|
'';
|
|
|
|
});
|
|
|
|
|
2021-02-05 12:39:41 +00:00
|
|
|
command-t = super.command-t.overrideAttrs (old: {
|
2018-09-14 05:36:29 +01:00
|
|
|
buildInputs = [ ruby rake ];
|
|
|
|
buildPhase = ''
|
|
|
|
rake make
|
|
|
|
rm ruby/command-t/ext/command-t/*.o
|
|
|
|
'';
|
|
|
|
});
|
|
|
|
|
2021-04-13 18:13:17 +01:00
|
|
|
compe-tabnine = super.compe-tabnine.overrideAttrs (old: {
|
|
|
|
buildInputs = [ tabnine ];
|
|
|
|
|
|
|
|
postFixup = ''
|
2021-08-13 23:13:40 +01:00
|
|
|
mkdir -p $target/binaries/${tabnine.version}
|
|
|
|
ln -s ${tabnine}/bin/ $target/binaries/${tabnine.version}/${tabnine.passthru.platform}
|
2021-04-13 18:13:17 +01:00
|
|
|
'';
|
|
|
|
});
|
|
|
|
|
2021-04-21 17:51:34 +01:00
|
|
|
completion-buffers = super.completion-buffers.overrideAttrs (old: {
|
|
|
|
dependencies = with self; [ completion-nvim ];
|
|
|
|
});
|
|
|
|
|
2021-04-13 18:13:17 +01:00
|
|
|
completion-tabnine = super.completion-tabnine.overrideAttrs (old: {
|
2021-04-21 17:51:34 +01:00
|
|
|
dependencies = with self; [ completion-nvim ];
|
2021-04-13 18:13:17 +01:00
|
|
|
buildInputs = [ tabnine ];
|
|
|
|
postFixup = ''
|
2021-09-17 17:13:26 +01:00
|
|
|
mkdir -p $target/binaries
|
2021-04-13 18:13:17 +01:00
|
|
|
ln -s ${tabnine}/bin/TabNine $target/binaries/TabNine_$(uname -s)
|
|
|
|
'';
|
|
|
|
});
|
|
|
|
|
2021-04-21 17:51:34 +01:00
|
|
|
completion-treesitter = super.completion-treesitter.overrideAttrs (old: {
|
|
|
|
dependencies = with self; [ completion-nvim nvim-treesitter ];
|
|
|
|
});
|
|
|
|
|
2021-02-05 12:39:41 +00:00
|
|
|
cpsm = super.cpsm.overrideAttrs (old: {
|
2018-09-14 05:36:29 +01:00
|
|
|
buildInputs = [
|
|
|
|
python3
|
|
|
|
stdenv
|
|
|
|
cmake
|
|
|
|
boost
|
|
|
|
icu
|
|
|
|
ncurses
|
|
|
|
];
|
|
|
|
buildPhase = ''
|
|
|
|
patchShebangs .
|
|
|
|
export PY3=ON
|
|
|
|
./install.sh
|
|
|
|
'';
|
|
|
|
});
|
|
|
|
|
2021-11-09 14:49:20 +00:00
|
|
|
crates-nvim = super.crates-nvim.overrideAttrs (old: {
|
|
|
|
dependencies = with self; [ plenary-nvim ];
|
|
|
|
});
|
|
|
|
|
2021-02-05 12:39:41 +00:00
|
|
|
ctrlp-cmatcher = super.ctrlp-cmatcher.overrideAttrs (old: {
|
2018-09-14 05:36:29 +01:00
|
|
|
buildInputs = [ python ];
|
|
|
|
buildPhase = ''
|
|
|
|
patchShebangs .
|
|
|
|
./install.sh
|
|
|
|
'';
|
|
|
|
});
|
|
|
|
|
2021-02-05 12:39:41 +00:00
|
|
|
defx-nvim = super.defx-nvim.overrideAttrs (old: {
|
2021-04-21 17:45:07 +01:00
|
|
|
dependencies = with self; [ nvim-yarp ];
|
2019-08-21 05:23:49 +01:00
|
|
|
});
|
|
|
|
|
2021-02-05 12:39:41 +00:00
|
|
|
deoplete-fish = super.deoplete-fish.overrideAttrs (old: {
|
2021-04-21 17:45:07 +01:00
|
|
|
dependencies = with self; [ deoplete-nvim vim-fish ];
|
2019-04-22 00:38:06 +01:00
|
|
|
});
|
|
|
|
|
2021-02-05 12:39:41 +00:00
|
|
|
deoplete-go = super.deoplete-go.overrideAttrs (old: {
|
2018-09-14 05:36:29 +01:00
|
|
|
buildInputs = [ python3 ];
|
|
|
|
buildPhase = ''
|
|
|
|
pushd ./rplugin/python3/deoplete/ujson
|
|
|
|
python3 setup.py build --build-base=$PWD/build --build-lib=$PWD/build
|
|
|
|
popd
|
|
|
|
find ./rplugin/ -name "ujson*.so" -exec mv -v {} ./rplugin/python3/ \;
|
2021-02-05 12:39:41 +00:00
|
|
|
'';
|
2018-09-14 05:36:29 +01:00
|
|
|
});
|
|
|
|
|
2021-02-05 12:39:41 +00:00
|
|
|
deoplete-khard = super.deoplete-khard.overrideAttrs (old: {
|
2021-04-21 17:45:07 +01:00
|
|
|
dependencies = with self; [ deoplete-nvim ];
|
2019-08-03 00:20:54 +01:00
|
|
|
passthru.python3Dependencies = ps: [ (ps.toPythonModule khard) ];
|
|
|
|
meta = {
|
|
|
|
description = "Address-completion for khard via deoplete";
|
|
|
|
homepage = "https://github.com/nicoe/deoplete-khard";
|
2021-01-15 13:21:58 +00:00
|
|
|
license = lib.licenses.mit;
|
|
|
|
maintainers = with lib.maintainers; [ jorsn ];
|
2019-08-03 00:20:54 +01:00
|
|
|
};
|
|
|
|
});
|
|
|
|
|
2021-04-13 18:13:17 +01:00
|
|
|
direnv-vim = super.direnv-vim.overrideAttrs (oa: {
|
|
|
|
preFixup = oa.preFixup or "" + ''
|
2021-09-02 00:20:05 +01:00
|
|
|
substituteInPlace $out/autoload/direnv.vim \
|
2021-04-13 18:13:17 +01:00
|
|
|
--replace "let s:direnv_cmd = get(g:, 'direnv_cmd', 'direnv')" \
|
|
|
|
"let s:direnv_cmd = get(g:, 'direnv_cmd', '${lib.getBin direnv}/bin/direnv')"
|
|
|
|
'';
|
|
|
|
});
|
|
|
|
|
2021-02-05 12:39:41 +00:00
|
|
|
ensime-vim = super.ensime-vim.overrideAttrs (old: {
|
2021-06-15 12:12:45 +01:00
|
|
|
passthru.python3Dependencies = ps: with ps; [ sexpdata websocket-client ];
|
2021-04-21 17:45:07 +01:00
|
|
|
dependencies = with self; [ vimproc-vim vimshell-vim self.self forms ];
|
2018-09-14 05:36:29 +01:00
|
|
|
});
|
|
|
|
|
2021-08-15 15:31:22 +01:00
|
|
|
fcitx-vim = super.fcitx-vim.overrideAttrs (old: {
|
|
|
|
passthru.python3Dependencies = ps: with ps; [ dbus-python ];
|
|
|
|
meta = {
|
|
|
|
description = "Keep and restore fcitx state when leaving/re-entering insert mode or search mode";
|
|
|
|
license = lib.licenses.mit;
|
|
|
|
};
|
|
|
|
});
|
|
|
|
|
2021-02-05 12:39:41 +00:00
|
|
|
forms = super.forms.overrideAttrs (old: {
|
2021-04-21 17:45:07 +01:00
|
|
|
dependencies = with self; [ self.self ];
|
2018-11-07 19:54:58 +00:00
|
|
|
});
|
|
|
|
|
2021-02-05 12:39:41 +00:00
|
|
|
fruzzy =
|
|
|
|
let
|
|
|
|
# until https://github.com/NixOS/nixpkgs/pull/67878 is merged, there's no better way to install nim libraries with nix
|
|
|
|
nimpy = fetchFromGitHub {
|
|
|
|
owner = "yglukhov";
|
|
|
|
repo = "nimpy";
|
|
|
|
rev = "4840d1e438985af759ddf0923e7a9250fd8ea0da";
|
|
|
|
sha256 = "0qqklvaajjqnlqm3rkk36pwwnn7x942mbca7nf2cvryh36yg4q5k";
|
|
|
|
};
|
|
|
|
binaryheap = fetchFromGitHub {
|
|
|
|
owner = "bluenote10";
|
|
|
|
repo = "nim-heap";
|
|
|
|
rev = "c38039309cb11391112571aa332df9c55f625b54";
|
|
|
|
sha256 = "05xdy13vm5n8dw2i366ppbznc4cfhq23rdcklisbaklz2jhdx352";
|
|
|
|
};
|
|
|
|
in
|
|
|
|
super.fruzzy.overrideAttrs (old: {
|
|
|
|
buildInputs = [ nim ];
|
|
|
|
patches = [
|
|
|
|
(substituteAll {
|
|
|
|
src = ./patches/fruzzy/get_version.patch;
|
|
|
|
version = old.version;
|
|
|
|
})
|
|
|
|
];
|
|
|
|
configurePhase = ''
|
|
|
|
substituteInPlace Makefile \
|
|
|
|
--replace \
|
|
|
|
"nim c" \
|
|
|
|
"nim c --nimcache:$TMP --path:${nimpy} --path:${binaryheap}"
|
|
|
|
'';
|
|
|
|
buildPhase = ''
|
|
|
|
make build
|
|
|
|
'';
|
|
|
|
});
|
2020-03-01 14:05:31 +00:00
|
|
|
|
2021-07-21 20:31:54 +01:00
|
|
|
fzf-checkout-vim = super.fzf-checkout-vim.overrideAttrs (old: {
|
|
|
|
# The plugin has a makefile which tries to run tests in a docker container.
|
|
|
|
# This prevents it.
|
|
|
|
prePatch = ''
|
|
|
|
rm Makefile
|
|
|
|
'';
|
|
|
|
});
|
|
|
|
|
2021-04-13 18:13:17 +01:00
|
|
|
fzf-vim = super.fzf-vim.overrideAttrs (old: {
|
2021-04-21 17:45:07 +01:00
|
|
|
dependencies = with self; [ fzfWrapper ];
|
2021-04-13 18:13:17 +01:00
|
|
|
});
|
|
|
|
|
|
|
|
# Mainly used as a dependency for fzf-vim. Wraps the fzf program as a vim
|
|
|
|
# plugin, since part of the fzf vim plugin is included in the main fzf
|
|
|
|
# program.
|
|
|
|
fzfWrapper = buildVimPluginFrom2Nix {
|
|
|
|
inherit (fzf) src version;
|
|
|
|
pname = "fzf";
|
|
|
|
postInstall = ''
|
|
|
|
ln -s ${fzf}/bin/fzf $target/bin/fzf
|
|
|
|
'';
|
|
|
|
};
|
|
|
|
|
2021-02-05 12:39:41 +00:00
|
|
|
ghcid = super.ghcid.overrideAttrs (old: {
|
2019-07-22 19:06:05 +01:00
|
|
|
configurePhase = "cd plugins/nvim";
|
|
|
|
});
|
|
|
|
|
2021-04-21 17:51:34 +01:00
|
|
|
gitsigns-nvim = super.gitsigns-nvim.overrideAttrs (old: {
|
|
|
|
dependencies = with self; [ plenary-nvim ];
|
|
|
|
});
|
|
|
|
|
2021-08-15 02:56:01 +01:00
|
|
|
# plenary-nvim = super.toVimPlugin(luaPackages.plenary-nvim);
|
2021-08-08 15:55:24 +01:00
|
|
|
|
2021-04-25 20:12:26 +01:00
|
|
|
gruvbox-nvim = super.gruvbox-nvim.overrideAttrs (old: {
|
|
|
|
dependencies = with self; [ lush-nvim ];
|
|
|
|
});
|
|
|
|
|
2021-04-13 18:13:17 +01:00
|
|
|
jedi-vim = super.jedi-vim.overrideAttrs (old: {
|
|
|
|
# checking for python3 support in vim would be neat, too, but nobody else seems to care
|
|
|
|
buildInputs = [ python3.pkgs.jedi ];
|
|
|
|
meta = {
|
|
|
|
description = "code-completion for python using python-jedi";
|
|
|
|
license = lib.licenses.mit;
|
2020-09-26 17:19:29 +01:00
|
|
|
};
|
|
|
|
});
|
|
|
|
|
2021-06-01 16:59:57 +01:00
|
|
|
himalaya-vim = buildVimPluginFrom2Nix {
|
|
|
|
pname = "himalaya-vim";
|
|
|
|
inherit (himalaya) src version;
|
|
|
|
dependencies = with self; [ himalaya ];
|
2021-09-06 10:23:03 +01:00
|
|
|
configurePhase = ''
|
|
|
|
cd vim
|
|
|
|
substituteInPlace plugin/himalaya.vim \
|
2021-06-01 16:59:57 +01:00
|
|
|
--replace 'if !executable("himalaya")' 'if v:false'
|
|
|
|
'';
|
|
|
|
postFixup = ''
|
|
|
|
mkdir -p $out/bin
|
|
|
|
ln -s ${himalaya}/bin/himalaya $out/bin/himalaya
|
|
|
|
'';
|
|
|
|
};
|
|
|
|
|
2021-04-13 18:13:17 +01:00
|
|
|
LanguageClient-neovim =
|
|
|
|
let
|
|
|
|
version = "0.1.161";
|
|
|
|
LanguageClient-neovim-src = fetchFromGitHub {
|
|
|
|
owner = "autozimu";
|
|
|
|
repo = "LanguageClient-neovim";
|
|
|
|
rev = version;
|
|
|
|
sha256 = "Z9S2ie9RxJCIbmjSV/Tto4lK04cZfWmK3IAy8YaySVI=";
|
|
|
|
};
|
|
|
|
LanguageClient-neovim-bin = rustPlatform.buildRustPackage {
|
|
|
|
pname = "LanguageClient-neovim-bin";
|
|
|
|
inherit version;
|
|
|
|
src = LanguageClient-neovim-src;
|
|
|
|
|
|
|
|
cargoSha256 = "H34UqJ6JOwuSABdOup5yKeIwFrGc83TUnw1ggJEx9o4=";
|
|
|
|
buildInputs = lib.optionals stdenv.isDarwin [ CoreServices ];
|
|
|
|
|
|
|
|
# FIXME: Use impure version of CoreFoundation because of missing symbols.
|
|
|
|
# Undefined symbols for architecture x86_64: "_CFURLResourceIsReachable"
|
|
|
|
preConfigure = lib.optionalString stdenv.isDarwin ''
|
|
|
|
export NIX_LDFLAGS="-F${CoreFoundation}/Library/Frameworks -framework CoreFoundation $NIX_LDFLAGS"
|
|
|
|
'';
|
|
|
|
};
|
|
|
|
in
|
|
|
|
buildVimPluginFrom2Nix {
|
|
|
|
pname = "LanguageClient-neovim";
|
|
|
|
inherit version;
|
|
|
|
src = LanguageClient-neovim-src;
|
|
|
|
|
|
|
|
propagatedBuildInputs = [ LanguageClient-neovim-bin ];
|
|
|
|
|
|
|
|
preFixup = ''
|
2021-09-02 00:20:05 +01:00
|
|
|
substituteInPlace "$out"/autoload/LanguageClient.vim \
|
2021-04-13 18:13:17 +01:00
|
|
|
--replace "let l:path = s:root . '/bin/'" "let l:path = '${LanguageClient-neovim-bin}' . '/bin/'"
|
|
|
|
'';
|
|
|
|
};
|
|
|
|
|
2021-11-02 20:54:44 +00:00
|
|
|
lean-nvim = super.lean-nvim.overrideAttrs (old: {
|
|
|
|
dependencies = with self; [ nvim-lspconfig plenary-nvim ];
|
|
|
|
});
|
|
|
|
|
2021-04-13 18:13:17 +01:00
|
|
|
lens-vim = super.lens-vim.overrideAttrs (old: {
|
|
|
|
# remove duplicate g:lens#animate in doc/lens.txt
|
|
|
|
# https://github.com/NixOS/nixpkgs/pull/105810#issuecomment-740007985
|
|
|
|
# https://github.com/camspiers/lens.vim/pull/40/files
|
|
|
|
patches = [
|
|
|
|
(substituteAll {
|
|
|
|
src = ./patches/lens-vim/remove_duplicate_g_lens_animate.patch;
|
|
|
|
inherit languagetool;
|
|
|
|
})
|
|
|
|
];
|
|
|
|
});
|
|
|
|
|
|
|
|
lf-vim = super.lf-vim.overrideAttrs (old: {
|
2021-04-21 17:45:07 +01:00
|
|
|
dependencies = with self; [ vim-floaterm ];
|
2018-09-14 05:36:29 +01:00
|
|
|
});
|
|
|
|
|
2021-08-16 14:11:22 +01:00
|
|
|
lir-nvim = super.lir-nvim.overrideAttrs (old: {
|
|
|
|
dependencies = with self; [ plenary-nvim ];
|
|
|
|
});
|
|
|
|
|
2021-09-29 02:40:30 +01:00
|
|
|
markdown-preview-nvim = super.markdown-preview-nvim.overrideAttrs (old: let
|
|
|
|
# We only need its dependencies `node-modules`.
|
|
|
|
nodeDep = nodePackages."markdown-preview-nvim-../../misc/vim-plugins/markdown-preview-nvim".overrideAttrs (old: {
|
|
|
|
dontNpmInstall = true;
|
|
|
|
});
|
|
|
|
in {
|
|
|
|
patches = [
|
|
|
|
(substituteAll {
|
|
|
|
src = ./markdown-preview-nvim/fix-node-paths.patch;
|
|
|
|
node = "${nodejs}/bin/node";
|
|
|
|
})
|
|
|
|
];
|
|
|
|
postInstall = ''
|
|
|
|
# The node package name is `*-vim` not `*-nvim`.
|
|
|
|
ln -s ${nodeDep}/lib/node_modules/markdown-preview-vim/node_modules $out/app
|
|
|
|
'';
|
|
|
|
|
|
|
|
nativeBuildInputs = [ nodejs ];
|
|
|
|
doInstallCheck = true;
|
|
|
|
installCheckPhase = ''
|
|
|
|
node $out/app/index.js --version
|
|
|
|
'';
|
|
|
|
});
|
|
|
|
|
2021-04-13 18:13:17 +01:00
|
|
|
meson = buildVimPluginFrom2Nix {
|
|
|
|
inherit (meson) pname version src;
|
|
|
|
preInstall = "cd data/syntax-highlighting/vim";
|
|
|
|
meta.maintainers = with lib.maintainers; [ vcunat ];
|
|
|
|
};
|
|
|
|
|
2021-02-05 12:39:41 +00:00
|
|
|
minimap-vim = super.minimap-vim.overrideAttrs (old: {
|
2021-01-29 20:51:30 +00:00
|
|
|
preFixup = ''
|
2021-09-02 00:20:05 +01:00
|
|
|
substituteInPlace $out/plugin/minimap.vim \
|
2021-01-29 20:51:30 +00:00
|
|
|
--replace "code-minimap" "${code-minimap}/bin/code-minimap"
|
2021-09-02 00:20:05 +01:00
|
|
|
substituteInPlace $out/bin/minimap_generator.sh \
|
2021-01-29 20:51:30 +00:00
|
|
|
--replace "code-minimap" "${code-minimap}/bin/code-minimap"
|
|
|
|
'';
|
2021-09-16 17:46:27 +01:00
|
|
|
|
|
|
|
doCheck = true;
|
|
|
|
checkPhase = ''
|
|
|
|
${neovim-unwrapped}/bin/nvim -n -u NONE -i NONE -V1 --cmd "set rtp+=$out" --cmd "runtime! plugin/*.vim" -c "MinimapToggle" +quit!
|
|
|
|
'';
|
|
|
|
|
2021-01-29 20:51:30 +00:00
|
|
|
});
|
|
|
|
|
2021-02-05 12:39:41 +00:00
|
|
|
ncm2 = super.ncm2.overrideAttrs (old: {
|
2021-04-21 17:45:07 +01:00
|
|
|
dependencies = with self; [ nvim-yarp ];
|
2018-09-14 05:36:29 +01:00
|
|
|
});
|
|
|
|
|
2021-02-05 12:39:41 +00:00
|
|
|
ncm2-jedi = super.ncm2-jedi.overrideAttrs (old: {
|
2021-04-21 17:45:07 +01:00
|
|
|
dependencies = with self; [ nvim-yarp ncm2 ];
|
2018-12-23 22:31:34 +00:00
|
|
|
passthru.python3Dependencies = ps: with ps; [ jedi ];
|
|
|
|
});
|
|
|
|
|
2021-02-05 12:39:41 +00:00
|
|
|
ncm2-neoinclude = super.ncm2-neoinclude.overrideAttrs (old: {
|
2021-04-21 17:45:07 +01:00
|
|
|
dependencies = with self; [ neoinclude-vim ];
|
2020-07-19 01:01:56 +01:00
|
|
|
});
|
|
|
|
|
2021-02-05 12:39:41 +00:00
|
|
|
ncm2-neosnippet = super.ncm2-neosnippet.overrideAttrs (old: {
|
2021-04-21 17:45:07 +01:00
|
|
|
dependencies = with self; [ neosnippet-vim ];
|
2020-07-19 01:01:56 +01:00
|
|
|
});
|
|
|
|
|
2021-02-05 12:39:41 +00:00
|
|
|
ncm2-syntax = super.ncm2-syntax.overrideAttrs (old: {
|
2021-04-21 17:45:07 +01:00
|
|
|
dependencies = with self; [ neco-syntax ];
|
2020-07-19 01:01:56 +01:00
|
|
|
});
|
|
|
|
|
2021-02-05 12:39:41 +00:00
|
|
|
ncm2-ultisnips = super.ncm2-ultisnips.overrideAttrs (old: {
|
2021-04-21 17:45:07 +01:00
|
|
|
dependencies = with self; [ ultisnips ];
|
2018-09-14 05:36:29 +01:00
|
|
|
});
|
|
|
|
|
2021-07-07 09:19:21 +01:00
|
|
|
neogit = super.neogit.overrideAttrs (old: {
|
|
|
|
dependencies = with self; [ plenary-nvim ];
|
|
|
|
});
|
|
|
|
|
2021-07-17 03:22:37 +01:00
|
|
|
null-ls-nvim = super.null-ls-nvim.overrideAttrs (old: {
|
2021-08-30 14:20:59 +01:00
|
|
|
dependencies = with self; [ plenary-nvim nvim-lspconfig ];
|
2021-07-17 03:22:37 +01:00
|
|
|
});
|
|
|
|
|
2021-02-05 12:39:41 +00:00
|
|
|
nvim-lsputils = super.nvim-lsputils.overrideAttrs (old: {
|
2021-04-21 17:45:07 +01:00
|
|
|
dependencies = with self; [ popfix ];
|
2020-11-29 11:47:49 +00:00
|
|
|
});
|
|
|
|
|
2021-11-29 20:43:14 +00:00
|
|
|
nvim-metals = super.nvim-metals.overrideAttrs (old: {
|
|
|
|
dontBuild = true;
|
|
|
|
});
|
|
|
|
|
2021-09-08 15:29:09 +01:00
|
|
|
nvim-spectre = super.nvim-spectre.overrideAttrs (old: {
|
|
|
|
dependencies = with self; [ plenary-nvim ];
|
|
|
|
});
|
|
|
|
|
2021-03-16 18:39:23 +00:00
|
|
|
# Usage:
|
|
|
|
# pkgs.vimPlugins.nvim-treesitter.withPlugins (p: [ p.tree-sitter-c p.tree-sitter-java ... ])
|
|
|
|
# or for all grammars:
|
|
|
|
# pkgs.vimPlugins.nvim-treesitter.withPlugins (_: tree-sitter.allGrammars)
|
|
|
|
nvim-treesitter = super.nvim-treesitter.overrideAttrs (old: {
|
|
|
|
passthru.withPlugins =
|
|
|
|
grammarFn: self.nvim-treesitter.overrideAttrs (_: {
|
|
|
|
postPatch =
|
|
|
|
let
|
|
|
|
grammars = tree-sitter.withPlugins grammarFn;
|
|
|
|
in
|
|
|
|
''
|
|
|
|
rm -r parser
|
|
|
|
ln -s ${grammars} parser
|
|
|
|
'';
|
|
|
|
});
|
|
|
|
});
|
|
|
|
|
2021-03-27 19:44:24 +00:00
|
|
|
onehalf = super.onehalf.overrideAttrs (old: {
|
|
|
|
configurePhase = "cd vim";
|
|
|
|
});
|
|
|
|
|
2021-08-19 21:03:51 +01:00
|
|
|
range-highlight-nvim = super.range-highlight-nvim.overrideAttrs (old: {
|
|
|
|
dependencies = with self; [ cmd-parser-nvim ];
|
|
|
|
});
|
|
|
|
|
2021-08-15 18:09:43 +01:00
|
|
|
refactoring-nvim = super.refactoring-nvim.overrideAttrs (old: {
|
|
|
|
dependencies = with self; [ nvim-treesitter plenary-nvim ];
|
|
|
|
});
|
|
|
|
|
2021-04-13 18:13:17 +01:00
|
|
|
skim = buildVimPluginFrom2Nix {
|
|
|
|
pname = "skim";
|
|
|
|
version = skim.version;
|
|
|
|
src = skim.vim;
|
|
|
|
};
|
|
|
|
|
2021-02-05 12:39:41 +00:00
|
|
|
skim-vim = super.skim-vim.overrideAttrs (old: {
|
2021-04-21 17:45:07 +01:00
|
|
|
dependencies = with self; [ skim ];
|
2020-04-01 04:15:17 +01:00
|
|
|
});
|
|
|
|
|
2021-09-03 22:02:27 +01:00
|
|
|
sqlite-lua = super.sqlite-lua.overrideAttrs (old: {
|
2021-09-07 01:21:01 +01:00
|
|
|
postPatch = let
|
|
|
|
libsqlite = "${sqlite.out}/lib/libsqlite3${stdenv.hostPlatform.extensions.sharedLibrary}";
|
|
|
|
in ''
|
2021-09-10 16:12:46 +01:00
|
|
|
substituteInPlace lua/sqlite/defs.lua \
|
2021-09-07 01:21:01 +01:00
|
|
|
--replace "path = vim.g.sqlite_clib_path" "path = vim.g.sqlite_clib_path or ${lib.escapeShellArg libsqlite}"
|
2021-01-31 10:01:50 +00:00
|
|
|
'';
|
2021-02-05 12:39:41 +00:00
|
|
|
});
|
|
|
|
|
2021-10-29 15:02:36 +01:00
|
|
|
statix = buildVimPluginFrom2Nix rec {
|
2021-10-27 22:29:45 +01:00
|
|
|
inherit (statix) pname src meta;
|
|
|
|
version = "0.1.0";
|
|
|
|
dependencies = with self; [ statix ];
|
|
|
|
postPatch = ''
|
2021-10-29 15:02:36 +01:00
|
|
|
# check that version is up to date
|
|
|
|
grep 'pname = "statix-vim"' -A 1 flake.nix \
|
2021-11-01 15:59:54 +00:00
|
|
|
| grep -F 'version = "${version}"'
|
2021-10-29 15:02:36 +01:00
|
|
|
|
2021-10-27 22:29:45 +01:00
|
|
|
cd vim-plugin
|
|
|
|
substituteInPlace ftplugin/nix.vim --replace statix ${statix}/bin/statix
|
|
|
|
substituteInPlace plugin/statix.vim --replace statix ${statix}/bin/statix
|
|
|
|
'';
|
|
|
|
};
|
|
|
|
|
2021-02-05 12:39:41 +00:00
|
|
|
sved =
|
|
|
|
let
|
|
|
|
# we put the script in its own derivation to benefit the magic of wrapGAppsHook
|
|
|
|
svedbackend = stdenv.mkDerivation {
|
|
|
|
name = "svedbackend-${super.sved.name}";
|
|
|
|
inherit (super.sved) src;
|
|
|
|
nativeBuildInputs = [ wrapGAppsHook ];
|
|
|
|
buildInputs = [
|
|
|
|
gobject-introspection
|
|
|
|
glib
|
|
|
|
(python3.withPackages (ps: with ps; [ pygobject3 pynvim dbus-python ]))
|
|
|
|
];
|
|
|
|
preferLocalBuild = true;
|
|
|
|
installPhase = ''
|
|
|
|
install -Dt $out/bin ftplugin/evinceSync.py
|
|
|
|
'';
|
|
|
|
};
|
|
|
|
in
|
|
|
|
super.sved.overrideAttrs (old: {
|
2018-12-31 13:47:57 +00:00
|
|
|
preferLocalBuild = true;
|
|
|
|
postPatch = ''
|
|
|
|
rm ftplugin/evinceSync.py
|
|
|
|
ln -s ${svedbackend}/bin/evinceSync.py ftplugin/evinceSync.py
|
|
|
|
'';
|
|
|
|
meta = {
|
|
|
|
description = "synctex support between vim/neovim and evince";
|
|
|
|
};
|
|
|
|
});
|
|
|
|
|
2021-10-17 16:25:59 +01:00
|
|
|
telescope-cheat-nvim = super.telescope-cheat-nvim.overrideAttrs (old: {
|
|
|
|
dependencies = with self; [ sqlite-lua telescope-nvim ];
|
|
|
|
});
|
|
|
|
|
2021-04-13 18:13:17 +01:00
|
|
|
telescope-frecency-nvim = super.telescope-frecency-nvim.overrideAttrs (old: {
|
2021-09-03 22:02:27 +01:00
|
|
|
dependencies = with self; [ sqlite-lua telescope-nvim ];
|
2021-04-21 17:51:34 +01:00
|
|
|
});
|
|
|
|
|
|
|
|
telescope-fzf-writer-nvim = super.telescope-fzf-writer-nvim.overrideAttrs (old: {
|
|
|
|
dependencies = with self; [ telescope-nvim ];
|
2020-03-08 05:16:53 +00:00
|
|
|
});
|
2018-12-31 13:47:57 +00:00
|
|
|
|
2021-07-17 21:07:29 +01:00
|
|
|
telescope-fzf-native-nvim = super.telescope-fzf-native-nvim.overrideAttrs (old: {
|
|
|
|
dependencies = with self; [ telescope-nvim ];
|
|
|
|
buildPhase = "make";
|
|
|
|
meta.platforms = lib.platforms.all;
|
|
|
|
});
|
|
|
|
|
2021-04-13 18:13:17 +01:00
|
|
|
telescope-fzy-native-nvim = super.telescope-fzy-native-nvim.overrideAttrs (old: {
|
2021-04-21 17:51:34 +01:00
|
|
|
dependencies = with self; [ telescope-nvim ];
|
2021-04-13 18:13:17 +01:00
|
|
|
preFixup =
|
|
|
|
let
|
|
|
|
fzy-lua-native-path = "deps/fzy-lua-native";
|
|
|
|
fzy-lua-native =
|
|
|
|
stdenv.mkDerivation {
|
|
|
|
name = "fzy-lua-native";
|
|
|
|
src = "${old.src}/${fzy-lua-native-path}";
|
|
|
|
# remove pre-compiled binaries
|
|
|
|
preBuild = "rm -rf static/*";
|
|
|
|
installPhase = ''
|
|
|
|
install -Dm 444 -t $out/static static/*
|
|
|
|
install -Dm 444 -t $out/lua lua/*
|
|
|
|
'';
|
|
|
|
};
|
|
|
|
in
|
|
|
|
''
|
|
|
|
rm -rf $target/${fzy-lua-native-path}/*
|
|
|
|
ln -s ${fzy-lua-native}/static $target/${fzy-lua-native-path}/static
|
|
|
|
ln -s ${fzy-lua-native}/lua $target/${fzy-lua-native-path}/lua
|
|
|
|
'';
|
|
|
|
meta.platforms = lib.platforms.all;
|
2018-09-14 05:36:29 +01:00
|
|
|
});
|
|
|
|
|
2021-04-21 17:51:34 +01:00
|
|
|
telescope-nvim = super.telescope-nvim.overrideAttrs (old: {
|
|
|
|
dependencies = with self; [ plenary-nvim popup-nvim ];
|
|
|
|
});
|
|
|
|
|
|
|
|
telescope-symbols-nvim = super.telescope-symbols-nvim.overrideAttrs (old: {
|
|
|
|
dependencies = with self; [ telescope-nvim ];
|
|
|
|
});
|
|
|
|
|
|
|
|
telescope-z-nvim = super.telescope-z-nvim.overrideAttrs (old: {
|
|
|
|
dependencies = with self; [ telescope-nvim ];
|
|
|
|
});
|
|
|
|
|
2021-04-13 18:13:17 +01:00
|
|
|
unicode-vim =
|
|
|
|
let
|
|
|
|
unicode-data = fetchurl {
|
|
|
|
url = "http://www.unicode.org/Public/UNIDATA/UnicodeData.txt";
|
|
|
|
sha256 = "16b0jzvvzarnlxdvs2izd5ia0ipbd87md143dc6lv6xpdqcs75s9";
|
|
|
|
};
|
|
|
|
in
|
|
|
|
super.unicode-vim.overrideAttrs (old: {
|
|
|
|
|
|
|
|
# redirect to /dev/null else changes terminal color
|
|
|
|
buildPhase = ''
|
|
|
|
cp "${unicode-data}" autoload/unicode/UnicodeData.txt
|
|
|
|
echo "Building unicode cache"
|
|
|
|
${vim}/bin/vim --cmd ":set rtp^=$PWD" -c 'ru plugin/unicode.vim' -c 'UnicodeCache' -c ':echohl Normal' -c ':q' > /dev/null
|
|
|
|
'';
|
|
|
|
});
|
|
|
|
|
|
|
|
vCoolor-vim = super.vCoolor-vim.overrideAttrs (old: {
|
|
|
|
# on linux can use either Zenity or Yad.
|
2021-05-07 22:18:14 +01:00
|
|
|
propagatedBuildInputs = [ gnome.zenity ];
|
2021-04-13 18:13:17 +01:00
|
|
|
meta = {
|
|
|
|
description = "Simple color selector/picker plugin";
|
|
|
|
license = lib.licenses.publicDomain;
|
|
|
|
};
|
2018-09-14 05:36:29 +01:00
|
|
|
});
|
|
|
|
|
2021-02-05 12:39:41 +00:00
|
|
|
vim-addon-actions = super.vim-addon-actions.overrideAttrs (old: {
|
2021-04-21 17:45:07 +01:00
|
|
|
dependencies = with self; [ vim-addon-mw-utils tlib_vim ];
|
2018-09-14 05:36:29 +01:00
|
|
|
});
|
|
|
|
|
2021-02-05 12:39:41 +00:00
|
|
|
vim-addon-async = super.vim-addon-async.overrideAttrs (old: {
|
2021-04-21 17:45:07 +01:00
|
|
|
dependencies = with self; [ vim-addon-signs ];
|
2018-09-14 05:36:29 +01:00
|
|
|
});
|
|
|
|
|
2021-02-05 12:39:41 +00:00
|
|
|
vim-addon-background-cmd = super.vim-addon-background-cmd.overrideAttrs (old: {
|
2021-04-21 17:45:07 +01:00
|
|
|
dependencies = with self; [ vim-addon-mw-utils ];
|
2018-09-14 05:36:29 +01:00
|
|
|
});
|
|
|
|
|
2021-02-05 12:39:41 +00:00
|
|
|
vim-addon-completion = super.vim-addon-completion.overrideAttrs (old: {
|
2021-04-21 17:45:07 +01:00
|
|
|
dependencies = with self; [ tlib_vim ];
|
2018-09-14 05:36:29 +01:00
|
|
|
});
|
|
|
|
|
2021-02-05 12:39:41 +00:00
|
|
|
vim-addon-goto-thing-at-cursor = super.vim-addon-goto-thing-at-cursor.overrideAttrs (old: {
|
2021-04-21 17:45:07 +01:00
|
|
|
dependencies = with self; [ tlib_vim ];
|
2018-09-14 05:36:29 +01:00
|
|
|
});
|
|
|
|
|
2021-04-13 18:13:17 +01:00
|
|
|
vim-addon-manager = super.vim-addon-manager.overrideAttrs (old: {
|
|
|
|
buildInputs = lib.optional stdenv.isDarwin Cocoa;
|
|
|
|
});
|
|
|
|
|
2021-02-05 12:39:41 +00:00
|
|
|
vim-addon-mru = super.vim-addon-mru.overrideAttrs (old: {
|
2021-04-21 17:45:07 +01:00
|
|
|
dependencies = with self; [ vim-addon-other vim-addon-mw-utils ];
|
2018-09-14 05:36:29 +01:00
|
|
|
});
|
|
|
|
|
2021-02-05 12:39:41 +00:00
|
|
|
vim-addon-nix = super.vim-addon-nix.overrideAttrs (old: {
|
2021-04-21 17:45:07 +01:00
|
|
|
dependencies = with self; [
|
2018-12-24 12:02:31 +00:00
|
|
|
vim-addon-completion
|
|
|
|
vim-addon-goto-thing-at-cursor
|
|
|
|
vim-addon-errorformats
|
|
|
|
vim-addon-actions
|
2021-02-05 12:39:41 +00:00
|
|
|
vim-addon-mw-utils
|
|
|
|
tlib_vim
|
2018-09-14 05:36:29 +01:00
|
|
|
];
|
|
|
|
});
|
|
|
|
|
2021-02-05 12:39:41 +00:00
|
|
|
vim-addon-sql = super.vim-addon-sql.overrideAttrs (old: {
|
2021-04-21 17:45:07 +01:00
|
|
|
dependencies = with self; [ vim-addon-completion vim-addon-background-cmd tlib_vim ];
|
2018-09-14 05:36:29 +01:00
|
|
|
});
|
|
|
|
|
2021-02-05 12:39:41 +00:00
|
|
|
vim-addon-syntax-checker = super.vim-addon-syntax-checker.overrideAttrs (old: {
|
2021-04-21 17:45:07 +01:00
|
|
|
dependencies = with self; [ vim-addon-mw-utils tlib_vim ];
|
2018-09-14 05:36:29 +01:00
|
|
|
});
|
|
|
|
|
2021-02-05 12:39:41 +00:00
|
|
|
vim-addon-toggle-buffer = super.vim-addon-toggle-buffer.overrideAttrs (old: {
|
2021-04-21 17:45:07 +01:00
|
|
|
dependencies = with self; [ vim-addon-mw-utils tlib_vim ];
|
2018-09-14 05:36:29 +01:00
|
|
|
});
|
|
|
|
|
2021-02-05 12:39:41 +00:00
|
|
|
vim-addon-xdebug = super.vim-addon-xdebug.overrideAttrs (old: {
|
2021-04-21 17:45:07 +01:00
|
|
|
dependencies = with self; [ webapi-vim vim-addon-mw-utils vim-addon-signs vim-addon-async ];
|
2018-09-14 05:36:29 +01:00
|
|
|
});
|
|
|
|
|
2021-02-05 12:39:41 +00:00
|
|
|
vim-bazel = super.vim-bazel.overrideAttrs (old: {
|
2021-04-21 17:45:07 +01:00
|
|
|
dependencies = with self; [ vim-maktaba ];
|
2018-09-14 05:36:29 +01:00
|
|
|
});
|
|
|
|
|
2021-02-05 12:39:41 +00:00
|
|
|
vim-beancount = super.vim-beancount.overrideAttrs (old: {
|
2020-05-03 02:00:58 +01:00
|
|
|
passthru.python3Dependencies = ps: with ps; [ beancount ];
|
|
|
|
});
|
|
|
|
|
2021-04-13 18:13:17 +01:00
|
|
|
vim-clap = super.vim-clap.overrideAttrs (old: {
|
|
|
|
preFixup =
|
|
|
|
let
|
|
|
|
maple-bin = rustPlatform.buildRustPackage {
|
|
|
|
name = "maple";
|
|
|
|
src = old.src;
|
|
|
|
|
|
|
|
nativeBuildInputs = [
|
|
|
|
pkg-config
|
|
|
|
];
|
|
|
|
|
|
|
|
buildInputs = [
|
|
|
|
openssl
|
|
|
|
] ++ lib.optionals stdenv.isDarwin [
|
|
|
|
CoreServices
|
|
|
|
curl
|
|
|
|
libgit2
|
|
|
|
libiconv
|
|
|
|
];
|
|
|
|
|
2021-12-07 10:36:03 +00:00
|
|
|
cargoSha256 = "sha256-zYm+7qAvhVGa/afddHhI2aQxmiLOkus5PHZBDP9S/Qg=";
|
2021-04-13 18:13:17 +01:00
|
|
|
};
|
|
|
|
in
|
|
|
|
''
|
|
|
|
ln -s ${maple-bin}/bin/maple $target/bin/maple
|
|
|
|
'';
|
|
|
|
|
|
|
|
meta.platforms = lib.platforms.all;
|
|
|
|
});
|
|
|
|
|
2021-02-05 12:39:41 +00:00
|
|
|
vim-codefmt = super.vim-codefmt.overrideAttrs (old: {
|
2021-04-21 17:45:07 +01:00
|
|
|
dependencies = with self; [ vim-maktaba ];
|
2018-09-14 05:36:29 +01:00
|
|
|
});
|
|
|
|
|
2021-02-05 12:39:41 +00:00
|
|
|
vim-dasht = super.vim-dasht.overrideAttrs (old: {
|
2020-04-07 15:14:44 +01:00
|
|
|
preFixup = ''
|
2021-09-02 00:20:05 +01:00
|
|
|
substituteInPlace $out/autoload/dasht.vim \
|
2020-04-07 15:14:44 +01:00
|
|
|
--replace "['dasht']" "['${dasht}/bin/dasht']"
|
|
|
|
'';
|
|
|
|
});
|
|
|
|
|
2021-02-05 12:39:41 +00:00
|
|
|
vim-easytags = super.vim-easytags.overrideAttrs (old: {
|
2021-04-21 17:45:07 +01:00
|
|
|
dependencies = with self; [ vim-misc ];
|
2020-03-01 19:40:44 +00:00
|
|
|
patches = [
|
2021-02-05 12:39:41 +00:00
|
|
|
(fetchpatch {
|
|
|
|
# https://github.com/xolox/vim-easytags/pull/170 fix version detection for universal-ctags
|
2020-04-01 02:11:51 +01:00
|
|
|
url = "https://github.com/xolox/vim-easytags/commit/46e4709500ba3b8e6cf3e90aeb95736b19e49be9.patch";
|
2020-03-01 19:40:44 +00:00
|
|
|
sha256 = "0x0xabb56xkgdqrg1mpvhbi3yw4d829n73lsnnyj5yrxjffy4ax4";
|
|
|
|
})
|
|
|
|
];
|
2018-09-14 05:36:29 +01:00
|
|
|
});
|
|
|
|
|
2021-11-11 15:23:02 +00:00
|
|
|
vim-fzf-coauthorship = super.vim-fzf-coauthorship.overrideAttrs (old: {
|
|
|
|
dependencies = with self; [ fzf-vim ];
|
|
|
|
});
|
|
|
|
|
2018-10-31 17:46:59 +00:00
|
|
|
# change the go_bin_path to point to a path in the nix store. See the code in
|
|
|
|
# fatih/vim-go here
|
|
|
|
# https://github.com/fatih/vim-go/blob/155836d47052ea9c9bac81ba3e937f6f22c8e384/autoload/go/path.vim#L154-L159
|
2021-02-05 12:39:41 +00:00
|
|
|
vim-go = super.vim-go.overrideAttrs (old:
|
|
|
|
let
|
|
|
|
binPath = lib.makeBinPath [
|
|
|
|
asmfmt
|
|
|
|
delve
|
|
|
|
errcheck
|
|
|
|
go-motion
|
|
|
|
go-tools
|
|
|
|
gocode
|
|
|
|
gocode-gomod
|
|
|
|
godef
|
|
|
|
gogetdoc
|
|
|
|
golint
|
|
|
|
golangci-lint
|
|
|
|
gomodifytags
|
|
|
|
gopls
|
|
|
|
gotags
|
|
|
|
gotools
|
|
|
|
iferr
|
|
|
|
impl
|
|
|
|
reftools
|
|
|
|
];
|
|
|
|
in
|
|
|
|
{
|
|
|
|
postPatch = ''
|
|
|
|
${gnused}/bin/sed \
|
|
|
|
-Ee 's@"go_bin_path", ""@"go_bin_path", "${binPath}"@g' \
|
|
|
|
-i autoload/go/config.vim
|
|
|
|
'';
|
|
|
|
});
|
2018-10-31 17:46:59 +00:00
|
|
|
|
2021-04-13 18:13:17 +01:00
|
|
|
vim-gist = super.vim-gist.overrideAttrs (old: {
|
2021-04-21 17:45:07 +01:00
|
|
|
dependencies = with self; [ webapi-vim ];
|
2021-04-13 18:13:17 +01:00
|
|
|
});
|
|
|
|
|
2021-02-05 12:39:41 +00:00
|
|
|
vim-grammarous = super.vim-grammarous.overrideAttrs (old: {
|
2018-09-14 05:36:29 +01:00
|
|
|
# use `:GrammarousCheck` to initialize checking
|
|
|
|
# In neovim, you also want to use set
|
|
|
|
# let g:grammarous#show_first_error = 1
|
|
|
|
# see https://github.com/rhysd/vim-grammarous/issues/39
|
|
|
|
patches = [
|
|
|
|
(substituteAll {
|
|
|
|
src = ./patches/vim-grammarous/set_default_languagetool.patch;
|
|
|
|
inherit languagetool;
|
|
|
|
})
|
|
|
|
];
|
|
|
|
});
|
|
|
|
|
2021-04-13 18:13:17 +01:00
|
|
|
vim-hexokinase = super.vim-hexokinase.overrideAttrs (old: {
|
|
|
|
preFixup =
|
|
|
|
let
|
|
|
|
hexokinase = buildGoModule {
|
|
|
|
name = "hexokinase";
|
|
|
|
src = old.src + "/hexokinase";
|
|
|
|
vendorSha256 = "pQpattmS9VmO3ZIQUFn66az8GSmB4IvYhTTCFn6SUmo=";
|
|
|
|
};
|
|
|
|
in
|
|
|
|
''
|
|
|
|
ln -s ${hexokinase}/bin/hexokinase $target/hexokinase/hexokinase
|
|
|
|
'';
|
|
|
|
|
|
|
|
meta.platforms = lib.platforms.all;
|
2020-12-04 10:52:29 +00:00
|
|
|
});
|
|
|
|
|
2021-02-05 12:39:41 +00:00
|
|
|
vim-hier = super.vim-hier.overrideAttrs (old: {
|
2018-09-14 05:36:29 +01:00
|
|
|
buildInputs = [ vim ];
|
|
|
|
});
|
|
|
|
|
2021-02-05 12:39:41 +00:00
|
|
|
vim-isort = super.vim-isort.overrideAttrs (old: {
|
2018-09-14 05:36:29 +01:00
|
|
|
postPatch = ''
|
|
|
|
substituteInPlace ftplugin/python_vimisort.vim \
|
2018-12-27 10:12:48 +00:00
|
|
|
--replace 'import vim' 'import vim; import sys; sys.path.append("${python.pkgs.isort}/${python.sitePackages}")'
|
2018-09-14 05:36:29 +01:00
|
|
|
'';
|
|
|
|
});
|
|
|
|
|
2020-11-04 20:14:25 +00:00
|
|
|
vim-markdown-composer =
|
2021-02-05 12:39:41 +00:00
|
|
|
let
|
|
|
|
vim-markdown-composer-bin = rustPlatform.buildRustPackage rec {
|
|
|
|
pname = "vim-markdown-composer-bin";
|
|
|
|
inherit (super.vim-markdown-composer) src version;
|
2021-05-07 12:00:49 +01:00
|
|
|
cargoSha256 = "1cvnjsw5dd02wrm1q5xi8b033rsn44f7fkmw5j7lhskv5j286zrh";
|
2021-02-05 12:39:41 +00:00
|
|
|
};
|
|
|
|
in
|
|
|
|
super.vim-markdown-composer.overrideAttrs (oldAttrs: rec {
|
|
|
|
preFixup = ''
|
2021-09-02 00:20:05 +01:00
|
|
|
substituteInPlace "$out"/after/ftplugin/markdown/composer.vim \
|
2021-02-05 12:39:41 +00:00
|
|
|
--replace "let l:args = [s:plugin_root . '/target/release/markdown-composer']" \
|
|
|
|
"let l:args = ['${vim-markdown-composer-bin}/bin/markdown-composer']"
|
|
|
|
'';
|
|
|
|
});
|
2020-11-04 20:14:25 +00:00
|
|
|
|
2021-02-05 12:39:41 +00:00
|
|
|
vim-metamath = super.vim-metamath.overrideAttrs (old: {
|
2019-11-07 18:46:35 +00:00
|
|
|
preInstall = "cd vim";
|
|
|
|
});
|
|
|
|
|
2021-02-05 12:39:41 +00:00
|
|
|
vim-snipmate = super.vim-snipmate.overrideAttrs (old: {
|
2021-04-21 17:45:07 +01:00
|
|
|
dependencies = with self; [ vim-addon-mw-utils tlib_vim ];
|
2018-09-14 05:36:29 +01:00
|
|
|
});
|
|
|
|
|
2021-06-16 18:33:13 +01:00
|
|
|
vim-speeddating = super.vim-speeddating.overrideAttrs (old: {
|
|
|
|
dependencies = with self; [ vim-repeat ];
|
|
|
|
});
|
|
|
|
|
2021-04-13 18:13:17 +01:00
|
|
|
vim-stylish-haskell = super.vim-stylish-haskell.overrideAttrs (old: {
|
|
|
|
postPatch = old.postPatch or "" + ''
|
|
|
|
substituteInPlace ftplugin/haskell/stylish-haskell.vim --replace \
|
|
|
|
'g:stylish_haskell_command = "stylish-haskell"' \
|
|
|
|
'g:stylish_haskell_command = "${stylish-haskell}/bin/stylish-haskell"'
|
|
|
|
'';
|
|
|
|
});
|
2018-09-14 05:36:29 +01:00
|
|
|
|
2021-06-16 18:33:13 +01:00
|
|
|
vim-surround = super.vim-surround.overrideAttrs (old: {
|
|
|
|
dependencies = with self; [ vim-repeat ];
|
|
|
|
});
|
|
|
|
|
2021-09-21 22:48:28 +01:00
|
|
|
vim-textobj-entire = super.vim-textobj-entire.overrideAttrs (old: {
|
|
|
|
dependencies = with self; [ vim-textobj-user ];
|
|
|
|
meta.maintainers = with lib.maintainers; [ farlion ];
|
|
|
|
});
|
|
|
|
|
2021-06-16 18:33:13 +01:00
|
|
|
vim-unimpaired = super.vim-unimpaired.overrideAttrs (old: {
|
|
|
|
dependencies = with self; [ vim-repeat ];
|
|
|
|
});
|
|
|
|
|
2021-02-05 12:39:41 +00:00
|
|
|
vim-wakatime = super.vim-wakatime.overrideAttrs (old: {
|
2018-09-14 05:36:29 +01:00
|
|
|
buildInputs = [ python ];
|
|
|
|
});
|
|
|
|
|
2021-02-05 12:39:41 +00:00
|
|
|
vim-xdebug = super.vim-xdebug.overrideAttrs (old: {
|
2021-08-18 01:14:20 +01:00
|
|
|
postInstall = null;
|
2018-09-14 05:36:29 +01:00
|
|
|
});
|
|
|
|
|
2021-02-05 12:39:41 +00:00
|
|
|
vim-xkbswitch = super.vim-xkbswitch.overrideAttrs (old: {
|
2018-09-14 05:36:29 +01:00
|
|
|
patchPhase = ''
|
|
|
|
substituteInPlace plugin/xkbswitch.vim \
|
2019-01-02 16:09:15 +00:00
|
|
|
--replace /usr/local/lib/libxkbswitch.so ${xkb-switch}/lib/libxkbswitch.so
|
2018-09-14 05:36:29 +01:00
|
|
|
'';
|
2019-01-02 16:09:15 +00:00
|
|
|
buildInputs = [ xkb-switch ];
|
2018-09-14 05:36:29 +01:00
|
|
|
});
|
|
|
|
|
2021-02-05 12:39:41 +00:00
|
|
|
vim-yapf = super.vim-yapf.overrideAttrs (old: {
|
2018-09-14 05:36:29 +01:00
|
|
|
buildPhase = ''
|
|
|
|
substituteInPlace ftplugin/python_yapf.vim \
|
2018-12-27 10:12:48 +00:00
|
|
|
--replace '"yapf"' '"${python3.pkgs.yapf}/bin/yapf"'
|
2018-09-14 05:36:29 +01:00
|
|
|
'';
|
|
|
|
});
|
|
|
|
|
2021-04-13 18:13:17 +01:00
|
|
|
vim2nix = buildVimPluginFrom2Nix {
|
|
|
|
pname = "vim2nix";
|
|
|
|
version = "1.0";
|
|
|
|
src = ./vim2nix;
|
2021-04-21 17:45:07 +01:00
|
|
|
dependencies = with self; [ vim-addon-manager ];
|
2021-04-13 18:13:17 +01:00
|
|
|
};
|
|
|
|
|
|
|
|
vimacs = super.vimacs.overrideAttrs (old: {
|
|
|
|
buildPhase = ''
|
|
|
|
substituteInPlace bin/vim \
|
|
|
|
--replace '/usr/bin/vim' 'vim' \
|
|
|
|
--replace '/usr/bin/gvim' 'gvim'
|
|
|
|
# remove unnecessary duplicated bin wrapper script
|
|
|
|
rm -r plugin/vimacs
|
|
|
|
'';
|
|
|
|
meta = with lib; {
|
|
|
|
description = "Vim-Improved eMACS: Emacs emulation plugin for Vim";
|
|
|
|
homepage = "http://algorithm.com.au/code/vimacs";
|
|
|
|
license = licenses.gpl2Plus;
|
|
|
|
maintainers = with lib.maintainers; [ millerjason ];
|
|
|
|
};
|
|
|
|
});
|
|
|
|
|
|
|
|
vimsence = super.vimsence.overrideAttrs (old: {
|
|
|
|
meta = with lib; {
|
|
|
|
description = "Discord rich presence for Vim";
|
|
|
|
homepage = "https://github.com/hugolgst/vimsence";
|
|
|
|
maintainers = with lib.maintainers; [ hugolgst ];
|
|
|
|
};
|
|
|
|
});
|
|
|
|
|
2021-02-05 12:39:41 +00:00
|
|
|
vimproc-vim = super.vimproc-vim.overrideAttrs (old: {
|
2018-09-14 05:36:29 +01:00
|
|
|
buildInputs = [ which ];
|
|
|
|
|
|
|
|
buildPhase = ''
|
|
|
|
substituteInPlace autoload/vimproc.vim \
|
|
|
|
--replace vimproc_mac.so vimproc_unix.so \
|
|
|
|
--replace vimproc_linux64.so vimproc_unix.so \
|
|
|
|
--replace vimproc_linux32.so vimproc_unix.so
|
|
|
|
make -f make_unix.mak
|
|
|
|
'';
|
|
|
|
});
|
|
|
|
|
2021-04-13 18:13:17 +01:00
|
|
|
vimshell-vim = super.vimshell-vim.overrideAttrs (old: {
|
2021-04-21 17:45:07 +01:00
|
|
|
dependencies = with self; [ vimproc-vim ];
|
2021-04-13 18:13:17 +01:00
|
|
|
});
|
|
|
|
|
2021-02-05 12:39:41 +00:00
|
|
|
YankRing-vim = super.YankRing-vim.overrideAttrs (old: {
|
2018-09-14 05:36:29 +01:00
|
|
|
sourceRoot = ".";
|
|
|
|
});
|
|
|
|
|
2021-02-05 12:39:41 +00:00
|
|
|
YouCompleteMe = super.YouCompleteMe.overrideAttrs (old: {
|
2018-09-14 05:36:29 +01:00
|
|
|
buildPhase = ''
|
|
|
|
substituteInPlace plugin/youcompleteme.vim \
|
2019-11-08 23:21:47 +00:00
|
|
|
--replace "'ycm_path_to_python_interpreter', '''" \
|
|
|
|
"'ycm_path_to_python_interpreter', '${python3}/bin/python3'"
|
2018-09-14 05:36:29 +01:00
|
|
|
|
|
|
|
rm -r third_party/ycmd
|
|
|
|
ln -s ${ycmd}/lib/ycmd third_party
|
|
|
|
'';
|
|
|
|
|
2021-01-11 07:54:33 +00:00
|
|
|
meta = with lib; {
|
2018-09-14 05:36:29 +01:00
|
|
|
description = "A code-completion engine for Vim";
|
2019-07-03 15:17:11 +01:00
|
|
|
homepage = "https://github.com/Valloric/YouCompleteMe";
|
|
|
|
license = licenses.gpl3;
|
|
|
|
maintainers = with maintainers; [ marcweber jagajaga ];
|
|
|
|
platforms = platforms.unix;
|
2018-09-14 05:36:29 +01:00
|
|
|
};
|
|
|
|
});
|
|
|
|
|
2020-09-03 02:47:21 +01:00
|
|
|
} // (
|
|
|
|
let
|
|
|
|
nodePackageNames = [
|
2021-02-22 00:52:51 +00:00
|
|
|
"coc-clangd"
|
|
|
|
"coc-cmake"
|
2020-09-03 02:47:21 +01:00
|
|
|
"coc-css"
|
2020-10-17 14:00:05 +01:00
|
|
|
"coc-diagnostic"
|
2020-09-03 02:47:21 +01:00
|
|
|
"coc-emmet"
|
|
|
|
"coc-eslint"
|
2021-04-13 18:25:54 +01:00
|
|
|
"coc-explorer"
|
2020-09-03 02:47:21 +01:00
|
|
|
"coc-git"
|
2020-11-27 19:14:31 +00:00
|
|
|
"coc-go"
|
2020-09-03 02:47:21 +01:00
|
|
|
"coc-highlight"
|
|
|
|
"coc-html"
|
|
|
|
"coc-imselect"
|
|
|
|
"coc-java"
|
|
|
|
"coc-jest"
|
|
|
|
"coc-json"
|
|
|
|
"coc-lists"
|
2020-11-27 19:14:31 +00:00
|
|
|
"coc-markdownlint"
|
2020-09-03 02:47:21 +01:00
|
|
|
"coc-metals"
|
|
|
|
"coc-pairs"
|
|
|
|
"coc-prettier"
|
2021-02-21 15:43:09 +00:00
|
|
|
"coc-pyright"
|
2021-02-22 00:52:51 +00:00
|
|
|
"coc-python"
|
2020-09-03 02:47:21 +01:00
|
|
|
"coc-r-lsp"
|
|
|
|
"coc-rls"
|
|
|
|
"coc-rust-analyzer"
|
|
|
|
"coc-smartf"
|
|
|
|
"coc-snippets"
|
|
|
|
"coc-solargraph"
|
|
|
|
"coc-stylelint"
|
|
|
|
"coc-tabnine"
|
2021-02-22 00:52:51 +00:00
|
|
|
"coc-texlab"
|
2020-09-03 02:47:21 +01:00
|
|
|
"coc-tslint"
|
|
|
|
"coc-tslint-plugin"
|
|
|
|
"coc-tsserver"
|
2021-11-14 04:51:19 +00:00
|
|
|
"coc-ultisnips"
|
2020-09-03 02:47:21 +01:00
|
|
|
"coc-vetur"
|
2020-11-27 19:21:43 +00:00
|
|
|
"coc-vimlsp"
|
2020-09-03 02:47:21 +01:00
|
|
|
"coc-vimtex"
|
|
|
|
"coc-wxml"
|
|
|
|
"coc-yaml"
|
|
|
|
"coc-yank"
|
|
|
|
];
|
|
|
|
nodePackage2VimPackage = name: buildVimPluginFrom2Nix {
|
|
|
|
pname = name;
|
2020-09-05 23:21:34 +01:00
|
|
|
inherit (nodePackages.${name}) version meta;
|
2020-09-03 02:47:21 +01:00
|
|
|
src = "${nodePackages.${name}}/lib/node_modules/${name}";
|
|
|
|
};
|
|
|
|
in
|
|
|
|
lib.genAttrs nodePackageNames nodePackage2VimPackage
|
|
|
|
)
|