{"id":20592422,"url":"https://github.com/valodim/mpdzen","last_synced_at":"2026-03-02T04:04:23.420Z","repository":{"id":2455460,"uuid":"3427038","full_name":"Valodim/mpdzen","owner":"Valodim","description":"mpd status notification using dzen2, including a tiny but functional cover art fetcher","archived":false,"fork":false,"pushed_at":"2012-04-29T22:21:09.000Z","size":144,"stargazers_count":6,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-04-14T22:54:28.462Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Shell","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Valodim.png","metadata":{"files":{"readme":"readme.mkd","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2012-02-13T04:05:38.000Z","updated_at":"2016-11-21T11:49:25.000Z","dependencies_parsed_at":"2022-09-09T01:01:10.856Z","dependency_job_id":null,"html_url":"https://github.com/Valodim/mpdzen","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/Valodim/mpdzen","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Valodim%2Fmpdzen","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Valodim%2Fmpdzen/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Valodim%2Fmpdzen/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Valodim%2Fmpdzen/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Valodim","download_url":"https://codeload.github.com/Valodim/mpdzen/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Valodim%2Fmpdzen/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29992286,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-03-02T01:47:34.672Z","status":"online","status_checked_at":"2026-03-02T02:00:07.342Z","response_time":60,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-16T07:43:52.012Z","updated_at":"2026-03-02T04:04:23.403Z","avatar_url":"https://github.com/Valodim.png","language":"Shell","funding_links":[],"categories":[],"sub_categories":[],"readme":"mpdzen\n======\n\nThis is just me flexing my zsh muscles a little, creating some things\nmarginally useful in the process.\n\n./mpc_parse\n-----------\n\nSimple parser for mpc status. Not useful on its own, this can be sourced\nfrom other scripts to get that data.\n\n./mpdzen\n---------\n\nThis script fetches data using mpc_parse and displays it in a nice dialogue\nusing dzen2. Note this requires a development version of dzen2, the one from\ndebian package in particular will not suffice!\nThe dialogue will also include a cover art image, if there is one in xpm format\nin ./covers/$ARTIST/$ALBUM.xpm or ~/.cache/covers/$ARTIST/$ALBUM.xmp\n\nHave a screenshot:\n\n![Screenshot](https://github.com/Valodim/mpdzen/raw/master/shot.png) \n\n./mpdzen_loop\n-------------\n\nVery small utility that listens for mpd events using mpc idleloop, and when\na player event happens, calls mpdzen. Basically, this will show the mpdzen\nnotification everytime a new song is played.\n\n./cover_fetcher ARTIST ALBUM\n----------------------------\n\nThis script will attempt to download a cover for $ALBUM by $ARTIST using curl,\nand convert it to a 64x64 xpm image using ImageMagick's convert. For my nicely\nsorted collection of data in its ARTIST/ALBUM/TITLES hierarchy, this worked\nvery well (zsh, obviously):\n\n    p=/path/to/mp3/\n    for i in ${~p}/*/*(/); do\n        i=${i#$p};\n        ./cover_fetcher ${i%/*} ${i#*/}; \n        echo; \n    done\n\n./dzenlines\n-----------\n\nThis script wraps dzen2, and will adjust the __-y__ parameter for subsequent\ncalls depending on the __-p__, __-y__ and __-h__ parameters, so that they don't\noverlap. For example, if you call three times `dzenlines -y 50 -h 30 -p 3`, it\nwill move the __-y__ further down by *34* pixels, which is the __-h__ parameter\nplus a bit of padding. Once the timeout given by __-p__ is reached, the offset\nis reset to zero.\n\nBe wary of non key-value arguments for dzen (ie, __-m__ and __-u__), they may\nconfuse the script. Just put them on the tail end of the arguments and it\nshould be fine.\n\nThe script keeps track of state for each pair of __-x__,__-y__ parameters, and\nwill move up or down the screen depending on the sign of __-y__.\n\npatches\n-------\n\nThis is a quilt patches dir that can be applied to dzen2, to allow escaping of\nclosing parantheses for ^i() syntax. This is necessary if album names contain\nany ), which will blow it up otherwise.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fvalodim%2Fmpdzen","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fvalodim%2Fmpdzen","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fvalodim%2Fmpdzen/lists"}