Skip to main content
Module

x/denops_std/option/mod.ts>pyxversion

📚 Standard module for denops.vim
Go to Latest
variable pyxversion
import { pyxversion } from "https://deno.land/x/denops_std@v4.1.7/option/mod.ts";

Specifies the python version used for pyx* functions and commands python_x. The default value is as follows:

    Compiled with                Default
    `+python` and `+python3`        0
    only `+python`                  2
    only `+python3`                 3

Available values are 0, 2 and 3. If 'pyxversion' is 0, it is set to 2 or 3 after the first execution of any python2/3 commands or functions. E.g. :py sets to 2, and :py3 sets to 3. :pyx sets it to 3 if Python 3 is available, otherwise sets to 2 if Python 2 is available. See also: has-pythonx

If Vim is compiled with only +python or +python3 setting 'pyxversion' has no effect. The pyx* functions and commands are always the same as the compiled version.

This option cannot be set from a modeline or in the sandbox, for security reasons.

(default depends on the build)

only available when compiled with the +python or the +python3 feature

type

{ get(denops: Denops): Promise<number>; set(denops: Denops, value: number): Promise<void>; reset(denops: Denops): Promise<void>; getGlobal(denops: Denops): Promise<number>; setGlobal(denops: Denops, value: number): Promise<void>; resetGlobal(denops: Denops): Promise<void>; }