UNPKG

particle-cli

Version:

Simple Node commandline application for working with your Particle devices and using the Particle Cloud

20 lines (16 loc) 557 B
#!/usr/bin/env node 'use strict'; global.verboseLevel = 1; // TODO(hmontero): Replace 'request' (uses deprecated 'punycode') with 'fetch'. process.noDeprecation = true; const hasValidNodeInstall = require('./lib/has-supported-node'); const CLI = require('./app/cli'); const credHelper = require('./docker-credential-helper'); if (hasValidNodeInstall()) { // if called as docker-credential-particle exec that instead if (process.argv0.includes('docker-credential-particle')) { void credHelper.run(); } else { void new CLI().run(process.argv); } }