Yes, although due to the long tail, 3 video sketches with individual /code folders will take up more space than pre-installing the top 30-50 libraries. I’d say you could probably do something curated pretty easily, and for everything else there is /code. Maybe make the install optional – so processing sketches have no library support by default, but there is a convenience script to add support for n common libraries.
Actually, it just occurred to me that video might already be built-in to the PI Processing install? not sure, but if it is that would make a batch of common libraries even smaller / faster to add.
Maybe I misunderstood – I thought when you pushed a sketch to OpenFrame it came with a bundled install script – or that the frame had a generic install script for a sketch of type “Processing” that it ran on any Processing push.
How does it currently work?
So my assumption was that the install was something like:
- download zip
- unzip and copy sketch to sketch-place
- register with frame
So the addition, after unzipping, would be something like:
- for file in sketch folder ending with .pde or .java:
- for entry in line in file beginning with “import”:
- if entry in map of downloads:
- if download is not on disk:
- download / install zip to JAVA_PATH
- if download is not on disk:
- if entry in map of downloads:
- for entry in line in file beginning with “import”:
If you go with the default sketch code folder, another option might be to add a “pool libraries” cleanup script – it loops over sketch folders and copies duplicate libraries to shared location found in JAVA_PATH.