From 27e5be1d838b3e0586bb076708eebdd28bb8f971 Mon Sep 17 00:00:00 2001 From: Clinton Ebadi Date: Thu, 12 Dec 2013 15:32:31 -0500 Subject: [PATCH] Command line interface to abcddb-tool Punts to `cddb-tool' for commands other than parse --- abcddb-tool | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/abcddb-tool b/abcddb-tool index 334486b..414839d 100755 --- a/abcddb-tool +++ b/abcddb-tool @@ -133,6 +133,13 @@ of (disc-number . tag-value)" (map (lambda (ttitle) (list (1+ (first ttitle)) (escape-for-shell (second ttitle)))) (cddb-query-tracks cddb 'TITLE))))) +(define (main args) + (cond ((string= (second args) "parse") + (call-with-input-file (third args) + (lambda (f) (cddb->export (read-cddb f))))) + (else + (apply execlp "cddb-tool" args)))) - +(when (batch-mode?) + (exit (main (program-arguments)))) \ No newline at end of file -- 2.20.1