Skip to content

Commit

Permalink
vim-configurable: Change python versioning
Browse files Browse the repository at this point in the history
Instead of explicitly stating "I want version 3" or "I want version 2"
you now simply specify what the python argument will be, and
vim_configurable will set up the flags for you. config.vim.python must
be set, still.
  • Loading branch information
KaiSforza committed Jan 6, 2016
1 parent 222f4b9 commit c21707e
Showing 1 changed file with 4 additions and 17 deletions.
21 changes: 4 additions & 17 deletions pkgs/applications/editors/vim/configurable.nix
Expand Up @@ -108,26 +108,14 @@ composableDerivation {

// edf {
name = "python";
feat = "pythoninterp";
feat = "python${if python ? isPy3 then "3" else ""}interp";
enable = {
nativeBuildInputs = [ python ];
} // lib.optionalAttrs stdenv.isDarwin {
configureFlags
= [ "--enable-pythoninterp=yes"
"--with-python-config-dir=${python}/lib" ];
};
}

// edf {
name = "python3";
feat = "python3interp";
enable = {
nativeBuildInputs = [ pkgs.python3 ];
} // lib.optionalAttrs stdenv.isDarwin {
configureFlags
= [ "--enable-python3interp=yes"
"--with-python3-config-dir=${pkgs.python3}/lib"
"--disable-pythoninterp" ];
= [ "--enable-python${if python ? isPy3 then "3" else ""}interp=yes"
"--with-python${if python ? isPy3 then "3" else ""}-config-dir=${python}/lib"
"--disable-python${if python ? isPy3 then "" else "3"}interp" ];
};
}

Expand Down Expand Up @@ -160,7 +148,6 @@ composableDerivation {
cfg = {
luaSupport = config.vim.lua or true;
pythonSupport = config.vim.python or true;
python3Support = config.vim.python3 or false;
rubySupport = config.vim.ruby or true;
nlsSupport = config.vim.nls or false;
tclSupport = config.vim.tcl or false;
Expand Down

0 comments on commit c21707e

Please sign in to comment.