Visual Studio Code snippets for Nuke Python API.
Download Marketplace: Nuke Tools
The Nuke Tools extension includes python stubs file generated with type annotations and more, so there are very few reasons to keep using the snippets.
If you don't want to use Nuke Tools but would like to use the python stubs, you can download the github project. You can then add the path to python.analysis.extraPaths
.
The Nuke Python API documentation converted to snippets. Snippets include description and arguments with vscode snippet style placeholders:
- The documentation does not always list the arguments or makes it clear to which is optional. Some of the snippets include a long description where you can understand better, but some of them won't (again it depends on the web documentation).
This extension is helpful to disable/enable snippets from the status bar or command.
- The nuke modules available locally are missing from the snippets, as you could obtain a better autocomplete if you reference them.
- Classes magic methods are not included.
- Class methods snippets are included but they should be better used as a peak view in the API. An example would be
nuke.Node().method()
; yes you can add an argument toNode()
and create one, but is likely that you already have a variable with that type of object:n = nuke.createNode('Tracker')
. In that case you could "sneak peak" the API to see what methods are available for aNode
object
Because snippets are automatically generated from the online documentation, is likely that is going to be bloated with a lot of text, so I would suggest to enable the extension only in your Nuke scripting directory/workspace.
Initial release of nuke-python-snippets