Apt-Get Wrapper for Node.js
$ npm install node-apt-get
A node wrapper for the functionality of apt-get
on Debian systems. Should support all commands and options (if not please PR the missing features), with a simple interface:
var apt = ;apt;
All method take options which will be transformed like so:
// apt-get install vim --assume-yesapt; // apt-get upgrade --simulateapt; // apt-get update --config-file /path/to/configapt;
All options will fall back to the value specified in apt.options
, so you can globally set options on all of your commands with the following:
aptoptions'assume-yes' = true;
Be careful with this because all options set this way are global. It is better to specify the options every time rather than accidentally setting --assume-yes
or --config-file
for all commands.
Note: Most apt-get
commands require root, but this module does not require or even check for that.
See man apt-get
for more info about supported commands and options.
Spawn Options
You can also overide the default behavior of inheriting the stdio for your child processes with the apt.spawnOptions
object.