By: CS2103-AY1819S1-T13-3
Since: Aug 2018
Licence: MIT
- 1. Introduction
- 2. Quick Start
- 3. Features
- 3.1. Viewing help :
help
- 3.2. Playing a track :
play t/
- 3.3. Playing a playlist :
play p/
- 3.4. Pausing a playing track :
pause
- 3.5. Continuing a paused track :
play
- 3.6. Stopping a play :
stop
- 3.7. Getting the duration of current playing/paused/stopped track:
duration
- 3.8. Seeking time point :
seek
- 3.9. Listing all playlists :
playlist list
- 3.10. Searching for a playlist :
playlist search
- 3.11. Creating a playlist :
playlist new
- 3.12. Deleting a playlist :
playlist del
- 3.13. Listing all tracks :
track list
- 3.14. Searching for a track :
track search
- 3.15. Adding a track into a playlist :
track add
- 3.16. Deleting a track from a playlist :
track del
- 3.17. Stepping a track :
step
[coming in v2.0] - 3.18. Stepping back :
stepback
[coming in v2.0] - 3.19. Replay a track :
replay
[coming in v2.0] - 3.20. Skipping to the next track :
next
[coming in v2.0] - 3.21. Skipping to the previous track :
prev
[coming in v2.0] - 3.22. Repeatedly playing a track :
repeat track
[coming in v2.0] - 3.23. Repeatedly playing a playlist :
repeat playlist
[coming in v2.0] - 3.24. Turning off repeat mode :
repeat off
[coming in v2.0] - 3.25. Shuffling a playlist :
shuffle
[coming in v2.0] - 3.26. Turning off shuffle mode :
shuffle off
[coming in v2.0] - 3.27. Clearing all entries :
clear
- 3.28. Exiting the program :
exit
- 3.1. Viewing help :
- 4. FAQ
- 5. Command Summary
1. Introduction
The JxMusic is a music platform that lets you add to, organize and play your digital audio collection on your computer. The player is optimized for those who prefer to work with a Command Line Interface (CLI) while still having the benefits of a Graphical User Interface (GUI).
2. Quick Start
-
Ensure you have Java version
9
or later installed in your Computer. -
Download the latest
jxmusic.jar
here. -
Copy the file to the folder you want to use as the home folder for your JxMusic player.
-
Open a terminal in the folder, enter the command
java -jar jxmusic.jar
.-
The command should generate a
library
folder next to the jar file containing several sample mp3 files. -
Otherwise, enter
unzip jxmusic.jar "library/*"
-
Alternatively, download the library.zip file and unzip it next to the jar.
-
Ensure that you have the library folder with the sample mp3 files otherwise jxmusic won’t start.
-
Then run
java -jar jxmusic.jar
-
-
The GUI should appear in a few seconds.
-
Type the command in the command box and press Enter to execute it.
e.g. typinghelp
and pressing Enter will open the help window. -
Some example commands you can try with build-in tracks and playlists:
-
playlist list
: lists all playlists -
playlist new
p/playlist1 t/Marbles
: creates a new playlist namedplaylist1
with mp3 fileMarbles
to the JxMusic Player. -
playlist play
p/playlist1
: plays theplaylist1
-
exit
: exits the app
-
-
Refer to Section 3, “Features” for details of each command.
-
To add the new tracks to the library, add the mp3 files to the
library
folder. -
Restart the file so that your new tracks could be scanned and showed in UI.
3. Features
Command Format
-
Words in
UPPER_CASE
are the parameters to be supplied by the user e.g. inplaylist new p/PLAYLIST
,PLAYLIST
is a parameter which can be used asplaylist new p/playlist1
. -
Items in square brackets are optional e.g
stepback [s/SECONDS]
can be used asstepback
or asstepback s/20
.
3.1. Viewing help : help
Format: help
3.2. Playing a track : play t/
Plays a track. If there is a playlist or track playing, it will be stopped and the track will be played.
Format: play t/[TRACK]
Examples:
-
play t/
Plays the first track in the library folder sorted by file name if there is any. -
play t/Some Song
Plays the track named "Some Song" if it exists in the library folder.
3.3. Playing a playlist : play p/
Plays a playlist. Similarly to playing a track, if there is a playlist or track playing, it will be stopped and the playlist will be played.
Format: play p/[PLAYLIST]
Examples:
-
play p/
Plays the first playlist in the library folder if there is any. -
play p/Favourites
Plays the playlist named "Favourites" if it exists in the library folder.
3.4. Pausing a playing track : pause
Pauses a playing track.
Format: pause
Examples:
-
play t/Some Song
pause
The track is paused.
3.5. Continuing a paused track : play
Continues a paused track.
Format: play
Examples:
-
play t/Some Song
pause
play
"Some Song" will continue playing from where it is paused.
3.6. Stopping a play : stop
Stops the track from playing.
Format: stop
Examples:
-
play t/Some Song
stop
play
"Some song" stops playing and replays from the beginning.
3.7. Getting the duration of current playing/paused/stopped track: duration
Displays the duration of current playing/paused/stopped track.
Format: duration
-
play t/Some Song
duration
The duration of the "Some Song" is displayed onResultDisplay
pane.
3.8. Seeking time point : seek
Steps to the specified time point of the current track.
Format: seek d/TIME
Examples:
-
play t/Some Song
seek d/1 10
The track seeks to the 1 min 10 sec point and starts from there. -
play t/Some Song
seek d/100
The track seeks to the 1 min 40 sec point and starts from there. -
play t/Some Song
seek d/200000
IfTIME
is longer than the song duration, the seek command fails.
3.9. Listing all playlists : playlist list
Shows the list of all playlists in the library.
Format: playlist list
3.10. Searching for a playlist : playlist search
Searches for playlists by names.
Format: playlist search QUERY
Examples:
-
playlist search Fav
Searches for playlists that has Fav in their names.
3.11. Creating a playlist : playlist new
Creates a new playlist with specific tracks and saves it into the library.
Format: playlist new p/PLAYLIST [t/TRACK]…
Examples:
-
playlist new p/Favourites t/Some Song t/Some Song 2
Creates a new playlist with the name Favourites and adds the tracks named Some Song and Some Song 2.
3.12. Deleting a playlist : playlist del
Removes an existing playlist from the library.
Format: playlist del INDEX
Examples:
-
playlist del 1
Deletes the first playlist in the panel if it exists.
3.13. Listing all tracks : track list
Shows a list of all tracks in the library.
Format: track list
3.14. Searching for a track : track search
Searches for tracks by names.
Format: track search QUERY
Examples:
-
track search aliez
Searches for tracks that has aliez in their names.
3.15. Adding a track into a playlist : track add
Adds a track into a playlist. Track can be chosen by using its name or its index in the track list panel.
Format: track add p/PLAYLIST [t/TRACK]…
Format: track add p/PLAYLIST [i/INDEX]…
Examples:
-
track add p/Favourites t/Some Song t/Some Song2
Adds the track named "Some Song" and "Some Song2" to the "Favourites" playlist. -
track add p/Favourites i/1 2
Adds the first and second track in the track list panel to the "Favourites" playlist.
3.16. Deleting a track from a playlist : track del
Removes a track from a playlist. Track can is chosen by using its appeared sequence in playlist card.
Format: track del p/PLAYLIST INDEX
Track is selected by its index not its name. |
Examples:
-
track del p/Favourites i/3
Deletes the 3rd track in "Favourites" playlist.
3.17. Stepping a track : step
[coming in v2.0]
Steps forward by default 10 seconds or specified time in seconds.
Format: step [s/SECONDS]
Examples:
-
play t/Some Song
step
The track moves forward to 10 seconds later of the track and keeps playing. -
play t/Some Song
step s/100
Stepping forward 100 seconds. -
play t/Some Song
stop s/-100
Using negative value forSECONDS
will apply the same behaviour asstepback
. The track steps backward 100 seconds.
3.18. Stepping back : stepback
[coming in v2.0]
Steps back by default 10 seconds or specified time in seconds.
Format: stepback [s/SECONDS]
Examples:
-
play t/Some Song
stepback
The track moves backward 10 seconds earlier of the track and keeps playing. If the track has just played for less than 10 seconds, the track replays. -
play t/Some Song
stepback s/100
Stepping back 100 seconds. -
play t/Some Song
stepback s/-100
Using negative value forSECONDS
will apply the same behaviour asstep
. The track steps forward 100 seconds.
3.19. Replay a track : replay
[coming in v2.0]
Replays a track before the track ends to start from the beginning.
Format: replay
Examples:
-
play t/Some Song
seek t/100
replay
The track plays from the beginning.
3.20. Skipping to the next track : next
[coming in v2.0]
Plays the next track.
Format: next
Examples:
-
play p/Favourites
next
If the last track is being played, the playlist ends and stops. -
play t/Some Song
repeat track
next
“Some Song” will replay. -
play p/Favourites
repeat playlist
next
Go to the next track. Sincerepeat playlist
is on, if it is the last track of the playlist playing, the first track of the playlist will play. -
play p/Favourites
shuffle
repeat playlist
next
Go to the next track. Sinceshuffle
andrepeat playlist
are on, if it is the last track playing, the next shuffled repeat will play.
3.21. Skipping to the previous track : prev
[coming in v2.0]
Plays the previous track.
Format: prev
Examples:
-
play p/Favourites
prev
Plays the previous track. If the current track is first track in playlist, replays the same track since there is no previous track. -
play t/Some Song
repeat track
prev
“Some Song” will replay. -
play p/Favourites
repeat playlist
prev
Go to the previous track. Sincerepeat playlist
is on, if it is the first track of the playlist playing, the last track of the playlist will play. -
play p/Favourites
shuffle
repeat playlist
prev
Go to the previous track. Sinceshuffle
andrepeat playlist
are on, if it is the first track playing and there was no previous track, the same track repeats.
3.22. Repeatedly playing a track : repeat track
[coming in v2.0]
Switches the repeat mode to repeatedly play a single track. The command works even without any track playing. Upon running this command, any subsequent track will be played on repeat.
Format: repeat track
Examples:
-
play p/Favourites
repeat playlist
repeat track
Switches to repeat track mode. The currently playing track will be on repeat. -
repeat track
play t/Some Song
“Some Song” will play on repeat. -
repeat track
play p/Favourites
The first track of the “Favourites” playlist will play on repeat.
3.23. Repeatedly playing a playlist : repeat playlist
[coming in v2.0]
Switches the repeat mode to repeatedly play a single playlist. The command works even without any playlist playing. Upon running this command, any subsequent playlist will be played on repeat.
Format: repeat playlist
Examples:
-
play p/Favourites
repeat track
repeat playlist
Switches to repeat playlist mode. “Favourites” will play on repeat. -
repeat playlist
play p/Favourites
“Favourites” will play on repeat. -
repeat playlist
play t/Some Song
“Some Song” will play on repeat.
3.24. Turning off repeat mode : repeat off
[coming in v2.0]
Turns off the repeat mode
Format: repeat off
Examples:
-
play p/Favourites
repeat playlist
repeat off
Switches off repeating mode.
3.25. Shuffling a playlist : shuffle
[coming in v2.0]
Switches on shuffle mode to play tracks in random order.
Format: shuffle
Examples:
-
shuffle
play p/Favourites
“Favourites” will play in random order. -
play p/Favourites
repeat playlist
shuffle
Subsequent tracks will be played in random order. When all the tracks in the playlist has been played, the next repeat will be shuffled. -
play p/Favourites
repeat track
shuffle
The track being repeated will continue to play untilrepeat off
only then subsequent tracks will play in random order from the remaining unplayed tracks in the playlist.
3.26. Turning off shuffle mode : shuffle off
[coming in v2.0]
Turns off the shuffle mode
Format: shuffle off
Examples:
-
play p/Favourites
shuffle
shuffle off
Switches off shuffling mode.
3.27. Clearing all entries : clear
Clears all entries from the library.
Format: clear
3.28. Exiting the program : exit
Exits the program.
Format: exit
4. FAQ
Q: How do I transfer my data to another Computer?
A: Install the app in the other computer and overwrite the library
folder it creates with the file that contains the data of your previous library
folder.
5. Command Summary
5.1. Commands for controlling playback
-
Play track :
play t/[TRACK]
-
Play playlist :
play p/[PLAYLIST]
-
Pause track :
pause
-
Continue track :
play
-
Stop playing :
stop
-
Seek time point :
seek d/TIME
eg.seek d/1 10
-
Step :
step [s/SECONDS]
eg.step s/100
-
Stepback :
stepback [s/SECONDS]
eg.stepback s/100
-
Replay :
replay
5.2. Commands for aiding the use of playback commands
-
Get duration :
duration
5.3. Commands for controlling sequence of playback
-
Skip to next track :
next
-
Skip to previous track :
prev
-
Repeat track :
repeat track
-
Repeat playlist :
repeat playlist
-
Turn off repeat mode :
repeat off
-
Shuffle playlist :
shuffle
-
Turn off shuffle mode :
shuffle off
5.4. Commands for managing playlists in library
-
List all playlists :
playlist list
-
Search for playlist :
playlist search QUERY
eg.playlist search Fav
-
Create playlist :
playlist new p/PLAYLIST [t/TRACK]…
eg.playlist new p/Favourites t/Some Song t/Some Song 2
-
Delete playlist :
playlist del INDEX
eg.playlist del INDEX
5.5. Commands for managing tracks in playlist
-
Add track to playlist :
track add p/PLAYLIST t/TRACK
eg.track add p/Favourites t/Some Song
-
Delete track from playlist :
track del p/PLAYLIST i/INDEX
eg.track del p/PLAYLIST i/1
-
List all tracks :
track list
-
Search for tracks :
track search QUERY
eg.track search Fav