Espruino command-line and NPM module #102
Replies: 22 comments
-
Posted at 2015-11-18 by @gfwilliams Thanks! It should just be |
Beta Was this translation helpful? Give feedback.
-
Posted at 2015-11-19 by @gfwilliams Thanks! Yes, writing to a file would be a good one - especially where the compiled/assembled code comes in. With the watch, it looks like it's just a few lines of code... For people that want it to 'just work' it might be a good idea to have built in - but yes, if it's more complex than that it'd make more sense to use something built for it. |
Beta Was this translation helpful? Give feedback.
-
Posted at 2015-11-19 by @gfwilliams Ok, there's now |
Beta Was this translation helpful? Give feedback.
-
Posted at 2015-12-11 by @gfwilliams Yes, it uses the serialport - if you're uploading code it does things like scanning for modules though. |
Beta Was this translation helpful? Give feedback.
-
Posted at 2015-12-11 by @gfwilliams
Yes, sorry - typo on my part. That's the lib it uses.
No, if there are >0 ports, it'll pick the first one. It isn't able to test to see if an Espruino is on that port - although if it were possible (reported back by the OS?) that'd be really cool. |
Beta Was this translation helpful? Give feedback.
-
Posted at 2015-12-11 by @gfwilliams Ahh, great! - I reckon you could probably check the USB Product and Vendor IDs pretty reliably, and presumably they are available in a similar way. If you did do it, it'd be great if you could submit it as a change for: https://github.com/espruino/EspruinoTools/blob/gh-pages/bin/espruino-cli.js#L273 |
Beta Was this translation helpful? Give feedback.
-
Posted at 2016-01-13 by @gfwilliams I'm afraid I'm not much of a node.js guru, but looking at the error messages it seems to be a problem installing contextify - presumably Maybe you could post up on the contextify issues page - or perhaps someone else has some ideas here? |
Beta Was this translation helpful? Give feedback.
-
Posted at 2016-01-13 by @gfwilliams Ok, glad you're getting somewhere... When I get time, I have plans to try and reduce some of the dependencies the Web IDE has - and hopefully that'll make the installation easier on all platforms. |
Beta Was this translation helpful? Give feedback.
-
Posted at 2015-11-18 by @gfwilliams
Hi,
Just to say that I finally got around to creating a NPM module for Espruino.
If you have node.js and NPM installed you can just do:
and you'll get the command-line tool.
Instructions here
You can also use it to do things from node.js on your PC:
It still needs a bit of work, but hopefully this will be a good start.
Beta Was this translation helpful? Give feedback.
All reactions