thelounge/src/command-line/config.js

15 lines
315 B
JavaScript
Raw Normal View History

2014-08-19 03:53:17 +02:00
var program = require("commander");
var child = require("child_process");
var Helper = require("../helper");
2014-08-19 03:53:17 +02:00
program
.command("config")
.description("Edit config: " + Helper.CONFIG_PATH)
2014-08-19 03:53:17 +02:00
.action(function() {
child.spawn(
process.env.EDITOR || "vi",
[Helper.CONFIG_PATH],
2014-08-19 03:53:17 +02:00
{stdio: "inherit"}
);
});