Module versioning #5038
Replies: 1 comment
-
Posted at 2015-10-03 by @allObjects @the1laz, the IDE has already a folder - sandbox - from where it can pick modules. I do though not know the priority, whether Web or sandbox folder first. Adding a repo folder in adition to the sandbox could be the answer. Posted at 2015-10-03 by DrAzzy Local sandbox has priority over internet. Which is good, just don't forget about it Posted at 2015-10-04 by the1laz Maybe using the sandbox should be the preferred method of keeping stable code for people needing it - local backups or downloads of specific github commits. @gfwilliams - Can EspruinoTools use local files? Posted at 2015-10-05 by @gfwilliams @the1laz yes - at least the sandbox keeps everything together. You mean via node.js? I'm not sure EspruinoTools can use local files yet. There should be a 'processor' type defined for getting files (and then various handlers see if they can find them by whatever means they can). If that's the case then it should be easy to add. If not I guess I should add it, but I'm running out of time again now :) Posted at 2015-10-05 by the1laz I don't need it myself, (I'm using a webserver for my own modules), but I might have a crack if I get around to it. I saw the section that it needs to work with, so I have an idea of what I have to do. Posted at 2015-10-05 by MichaelPralow are you sure that the local sandbox has priority over internet? i tried it with the ESP8266_v25 module, i copied it to the project/module folder, but require took always the internet version, after renaming (and using that name in require) it worked Posted at 2015-10-06 by @gfwilliams Hmm. That's odd - could it have been a capitalisation issue? I guess it's possible it does:
You could tweak it by changing the module load order in settings to ... that logic should probably be changed though. Posted at 2015-10-06 by MichaelPralow i will check it again i interpret your order, that i need to put the minified version local do get the local priority? Posted at 2015-10-06 by @gfwilliams Yes (or just rename the file). However the search order for file extensions can be specified in settings - you could even search for and prioritise |
Beta Was this translation helpful? Give feedback.
-
Posted at 2015-10-03 by the1laz
Npm handles it all, node just uses whatever is supplied.
Can the web IDE use local files without a http server? If it (optionally?) preferentially looked in a node_modules folder when loading modules, then people could just keep local copies of the modules they use if they want them to stay unchanged. Then they can use whatever method they wanted to manage versions (git, npm, etc.).
Beta Was this translation helpful? Give feedback.
All reactions