balena-cli/bin/resin-write

19 lines
428 B
Plaintext
Raw Normal View History

2015-01-29 16:04:48 +00:00
#!/usr/bin/env node
// http://coffeescript.org/documentation/docs/register.html
require('coffee-script/register');
var device = require('../lib/actions/device.coffee');
var errors = require('../lib/errors/errors');
2015-01-29 17:17:26 +00:00
// TODO: Do some error handling when image or device are incorrect
2015-01-29 16:04:48 +00:00
device.init.action({
image: process.argv[2],
device: process.argv[3]
}, {
yes: true
}, function(error) {
return errors.handle(error);
});