cache | ||
config | ||
.gitignore | ||
App.go | ||
client.go | ||
fileBrowser.go | ||
go.mod | ||
go.sum | ||
imageUtils.go | ||
lastfm.go | ||
LICENSE | ||
main.go | ||
notification.go | ||
progressBar.go | ||
README.md | ||
render.go | ||
sample_config.yml | ||
utils.go |
goMP
MPD client inspired by ncmpcpp written in GO
Roadmap
- Add Functionality to Sort out most played songs
- Add a config parser
- Image Previews
- User Key Mappings
- Querying LastFM API for getting Album Art
- Fuzzy Searching [ checkout this pull request ]
- Visual Mode (like vim) for updating playlists
Setting Up
- Music Player Daemon must be setup
- Go Should Be Installed ( for building )
- Make a YAML/TOML file in
$HOME/.config/goMP
named config.yml / config.toml - Read the sample_config.yml for config options
Installing / Building
git clone https://github.com/aditya-K2/goMP &&
cd goMP &&
go build
Configuration
Image Rendering :
The Default Position of the Image without any configuration assumes that you have no padding or margin so Image will be rendered at different places in different terminals, Also the TUI calculates positions with the help of rows and columns and the image is rendered at pixel positions so the exact position can't be defined [ the app tries its best by calculating the font width and then predicting the position but it is best that you define extra padding and own image width ratio in config.yml. Please Read more about it in the sample_config
Key Mappings
Following Keys can be used for Mappings
Keys | Using them in Config |
---|---|
a-z | a-z |
A-Z | A-z |
{,},(,),[,],<,> | {,},(,),[,],<,> |
Enter(Return) | ENTER/RETURN |
Tab | TAB |
Space | SPACE |
See config/kMap.go for more information
For mapping a key to some function use the following format:
Function: [ firstMapping, secondMapping, thirdMapping]
for.eg
togglePlayBack : [ "p", "TAB", "[" ] # using the quotes is neccessary.
Following functions are provided :
Functions |
---|
showChildrenContent |
togglePlayBack |
showParentContent |
nextSong |
clearPlaylist |
previousSong |
addToPlaylist |
toggleRandom |
toggleRepeat |
decreaseVolume |
increaseVolume |
navigateToFiles |
navigateToPlaylist |
navigateToMostPlayed |
navigateToSearch |
quit |
stop |
updateDB |
deleteSongFromPlaylist |
FocusSearch |
Getting Album Art from LastFm API
-
Generate API Key here
-
Add the api key and api secret to config.yml
GET_COVER_ART_FROM_LAST_FM : "TRUE" # Turn On Getting Album art from lastfm api
LASTFM_API_KEY: "YOUR API KEY HERE"
LASTFM_API_SECRET: "YOUR API SECRET HERE"
- Auto correct
LASTFM_AUTO_CORRECT: 1 # 0 means it is turned off
Tested on following terminals:
- Alacritty
- ST
- URXVT ( URXVT sometimes crashes when downloading coverart from lastfm )