Code Monkey home page Code Monkey logo

vapoursynth-plugins-stub-generator's Introduction

VapourSynth-Plugins-Stub-Generator

An unofficial stub generator for vapoursynth and its plugins, which is helpful to autocomplete code in VSCode.

Two way of Generating stub file

1.(Onekey install) Place the whole folder VapourSynth-Plugins-Stub-Generator at the same path of python.exe of vapoursynth.

run the onekey install.bat.

Done!

2.(Install manually) At first, you need to have a python with vapoursynth installed. You can check it with

python -c 'from vapoursynth import core
print(core.version())'

Then run the command:

python vs_plugins_helper.py

A file called vapoursynth.pyi should be created. Move it to where your language server or library like Jedi can recognize.

Generating stub file for VSCode

For VSCode users, there are some simpler way to generate the stub file.

For Pylance or Microsoft Python Language Server users, run the command to install the stub file:

python vs_plugins_helper.py install vapoursynth

For Jedi or JediLSP users, run the command to install the stub file:

python vs_plugins_helper.py install vscode

Setting up VSCode

Files in .vscode folder might be helpful to set up VSCode.

  1. Install VSCode, then install Python extension and Pylance in VSCode extension market.

  2. Paste the settings.json to the user settings folder1 or work area settings folder2. This will enable the python code highlighting and autocompletion.

  3. Paste the tasks.json to the user settings folder1 or work area settings folder2, and paste the keybindings.json to your vscode user settings folder1. This will enable shift+f5/f6 hotkeys as f5/f6 in vsedit.

  4. Remember to change "path\\to\\your\\VapourSynth\\python.exe" in settings.json and tasks.json to your own python interpreter.

1: Usually refer to %APPDATA%\Code\User\ on Windows and $HOME/.config/Code/User/ on Linux

2: Usually refer to /path/to/your/workdir/.vscode/

vapoursynth-plugins-stub-generator's People

Contributors

saltychiang avatar huangruixiao-eng avatar vxzms avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.