From 992911a021e2f2cccfbc63e554a3f34bd997cd91 Mon Sep 17 00:00:00 2001 From: Florrie Date: Tue, 26 Jun 2018 12:01:43 -0300 Subject: Pass YouTube playlist URLs directly to mtui Or any other crawler argument, and it'll (try to) guess which crawler you want to use automatically. Handy! --- general-util.js | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'general-util.js') diff --git a/general-util.js b/general-util.js index 2ce7ed4..7156274 100644 --- a/general-util.js +++ b/general-util.js @@ -1,6 +1,10 @@ const { spawn } = require('child_process') +const { promisify } = require('util') +const fs = require('fs') const npmCommandExists = require('command-exists') +const readFile = promisify(fs.readFile) + module.exports.promisifyProcess = function(proc, showLogging = true) { // Takes a process (from the child_process module) and returns a promise // that resolves when the process exits (or rejects, if the exit code is -- cgit 1.3.0-6-gf8a5