balena-cli/bin/resin-write

17 lines
332 B
Plaintext
Raw Permalink Normal View History

2015-01-29 12:04:48 -04:00
#!/usr/bin/env node
2015-03-03 12:38:45 -04:00
var os = require('../build/actions/os');
var errors = require('../build/errors');
2015-01-29 12:04:48 -04:00
2015-01-29 13:17:26 -04:00
// TODO: Do some error handling when image or device are incorrect
2015-02-10 13:09:05 -04:00
os.install.action({
2015-01-29 12:04:48 -04:00
image: process.argv[2],
device: process.argv[3]
}, {
2015-03-03 12:38:45 -04:00
yes: true,
fromScript: true
2015-01-29 12:04:48 -04:00
}, function(error) {
return errors.handle(error);
});