fixes for noe-pixel to check more thoroughly for new libs

while supporting old ones also.
This commit is contained in:
Dave Conway-Jones
2017-09-01 15:22:35 +01:00
parent 39fd3b85cd
commit e376802ff4
7 changed files with 40 additions and 20 deletions

View File

@@ -1,13 +1,13 @@
#!/usr/bin/env node
var fs = require('fs');
if (!fs.existsSync('/usr/local/lib/python2.7/dist-packages/neopixel/')) {
console.warn("WARNING : Can't find neopixel.py python library");
if (!fs.existsSync('/usr/local/lib/python2.7/dist-packages/unicornhat.py')) {
console.warn("WARNING : Can't find required python library");
console.warn("WARNING : Please install using the following command");
console.warn("WARNING : Note: this uses root...");
console.warn("WARNING : curl -sS get.pimoroni.com/unicornhat | bash\n");
//process.exit(1);
}
else {
console.log("Neopixel Python library found OK.\n")
console.log("Python library found OK.\n")
}