diff options
author | Kamil Chmielewski <kamil.chm@gmail.com> | 2016-06-02 21:21:45 +0200 |
---|---|---|
committer | Kamil Chmielewski <kamil.chm@gmail.com> | 2016-06-09 11:21:30 +0200 |
commit | dbf48cd10baf816d1ce48829f169a531165a8f2d (patch) | |
tree | 1b8a51fe7d38e81041936972969312f6c682a15e /pkgs/tools/misc/fzf | |
parent | dfe1064b4e49fcda317021e183e85e419b33b473 (diff) |
fzf: application extracted from goPackages
Diffstat (limited to 'pkgs/tools/misc/fzf')
-rw-r--r-- | pkgs/tools/misc/fzf/default.nix | 33 | ||||
-rw-r--r-- | pkgs/tools/misc/fzf/deps.json | 20 |
2 files changed, 53 insertions, 0 deletions
diff --git a/pkgs/tools/misc/fzf/default.nix b/pkgs/tools/misc/fzf/default.nix new file mode 100644 index 0000000000000..08def70ecb6eb --- /dev/null +++ b/pkgs/tools/misc/fzf/default.nix @@ -0,0 +1,33 @@ +# This file was generated by go2nix. +{ stdenv, lib, ncurses, goPackages, fetchgit, fetchhg, fetchbzr, fetchsvn }: + +with goPackages; + +buildGoPackage rec { + name = "fzf-${version}"; + version = "0.12.2"; + rev = "${version}"; + + goPackagePath = "github.com/junegunn/fzf"; + + src = fetchgit { + inherit rev; + url = "https://github.com/junegunn/fzf"; + sha256 = "02qqcnijv8z3736iczbx082yizpqk02g5k746k7sdgfkgyxydppk"; + }; + + buildInputs = [ ncurses ]; + + goDeps = ./deps.json; + + patchPhase = '' + sed -i -e "s|expand('<sfile>:h:h').'/bin/fzf'|'$bin/bin/fzf'|" plugin/fzf.vim + sed -i -e "s|expand('<sfile>:h:h').'/bin/fzf-tmux'|'$bin/bin/fzf-tmux'|" plugin/fzf.vim + ''; + + postInstall= '' + cp $src/bin/fzf-tmux $bin/bin + mkdir -p $out/share/vim-plugins + ln -s $out/share/go/src/github.com/junegunn/fzf $out/share/vim-plugins/${(builtins.parseDrvName fzf.name).name} + ''; +} diff --git a/pkgs/tools/misc/fzf/deps.json b/pkgs/tools/misc/fzf/deps.json new file mode 100644 index 0000000000000..a856d2d5fa817 --- /dev/null +++ b/pkgs/tools/misc/fzf/deps.json @@ -0,0 +1,20 @@ +[ + { + "goPackagePath": "github.com/junegunn/go-runewidth", + "fetch": { + "type": "git", + "url": "https://github.com/junegunn/go-runewidth", + "rev": "63c378b851290989b19ca955468386485f118c65", + "sha256": "1z5mhfrpqdssn3603vwd95w69z28igwq96lh7b9rrdcx440i822d" + } + }, + { + "goPackagePath": "github.com/junegunn/go-shellwords", + "fetch": { + "type": "git", + "url": "https://github.com/junegunn/go-shellwords", + "rev": "35d512af75e283aae4ca1fc3d44b159ed66189a4", + "sha256": "08la0axabk9hiba9mm4ypp6a116qhvdlxa1jvkxhv3d4zpjsp4n7" + } + } +] |