« get me outta code hell

http-music - Command-line music player + utils (not a server!)
about summary refs log tree commit diff
path: root/src/play.js
diff options
context:
space:
mode:
Diffstat (limited to 'src/play.js')
-rwxr-xr-xsrc/play.js7
1 files changed, 3 insertions, 4 deletions
diff --git a/src/play.js b/src/play.js
index 28fd2c7..0b521b4 100755
--- a/src/play.js
+++ b/src/play.js
@@ -114,7 +114,7 @@ async function main(args) {
     [['delete'], 'skipUpNext'],
     [['s'], 'skipAhead'], [['S'], 'skipAhead'],
     [['i'], 'showTrackInfo'], [['I'], 'showTrackInfo'],
-    [['t'], 'showTrackInfo'], [['T'], 'showTrackInfo'],
+    [['t'], 'showTrackInfo', 0, 0], [['T'], 'showTrackInfo', 0, 0],
     [['q'], 'quit'], [['Q'], 'quit']
   ]
 
@@ -788,10 +788,9 @@ async function main(args) {
         })
       },
 
-      // TODO: Number of history/up-next tracks to show.
-      'showTrackInfo': function() {
+      'showTrackInfo': function(previousTrackCount = 3, upNextTrackCount = undefined) {
         clearConsoleLine()
-        playController.logTrackInfo()
+        playController.logTrackInfo(previousTrackCount, upNextTrackCount)
       },
 
       'runShellCommand': async function(command, args) {