I have just discovered the virtualFile component but I’m not sure I understand how to use it properly. Each file is linked to a file on disk. But there is no Pulse button to reload the file into the virtual file system when the contents on disk have changed or is there? Also, why is this so complicated? Why not give each operator that loads contents from a file a toggle for embedding the contents in the toe or tox? Am I missing something? Do people use relative paths instead of virtualFiles and then bundle the referenced files with their tox or toe?
the virtual file system is for embedding external files in a project or component, making it independent from the file on disc. The only reference to the original file is path string.
To make it easier to manage virtual files in TouchDesigner, there is a “virtualFile“ component in the Palette>Tools folder which allows to add, remove, and rename them.
Updating a vfs file from disc is not part of the vfs Class or vfsFile Class itself. You would have to destroy the vfs file first and then store the file again. This could be further automated by watching these files on disc with a Folder DAT.
Depending on what you are planning to deliver, it mostly will be more useful to have a folder structure with the relevant files available in there. vfs files become useful if a component absolutely depends on certain files, like font files or perhaps files for a web server build in TD.