{"id":22866843,"url":"https://github.com/insomnimus/ps-mpd","last_synced_at":"2026-02-18T05:01:41.863Z","repository":{"id":136923219,"uuid":"527315093","full_name":"insomnimus/ps-mpd","owner":"insomnimus","description":"Powershell commands for the Music Player Daemon (MPD) with tab completions.","archived":false,"fork":false,"pushed_at":"2024-10-27T19:39:04.000Z","size":135,"stargazers_count":3,"open_issues_count":1,"forks_count":1,"subscribers_count":1,"default_branch":"main","last_synced_at":"2026-02-13T08:47:58.014Z","etag":null,"topics":["mpc","mpd","powershell","tab-completion"],"latest_commit_sha":null,"homepage":null,"language":"C#","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/insomnimus.png","metadata":{"files":{"readme":"readme.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2022-08-21T20:07:20.000Z","updated_at":"2025-11-10T17:33:26.000Z","dependencies_parsed_at":null,"dependency_job_id":"1f99a3b1-9d17-42fc-913b-6db84422f1a3","html_url":"https://github.com/insomnimus/ps-mpd","commit_stats":null,"previous_names":[],"tags_count":7,"template":false,"template_full_name":null,"purl":"pkg:github/insomnimus/ps-mpd","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/insomnimus%2Fps-mpd","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/insomnimus%2Fps-mpd/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/insomnimus%2Fps-mpd/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/insomnimus%2Fps-mpd/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/insomnimus","download_url":"https://codeload.github.com/insomnimus/ps-mpd/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/insomnimus%2Fps-mpd/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29569853,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-18T04:18:28.490Z","status":"ssl_error","status_checked_at":"2026-02-18T04:13:49.018Z","response_time":162,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"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":["mpc","mpd","powershell","tab-completion"],"created_at":"2024-12-13T12:17:39.972Z","updated_at":"2026-02-18T05:01:41.847Z","avatar_url":"https://github.com/insomnimus.png","language":"C#","funding_links":[],"categories":[],"sub_categories":[],"readme":"# PS-MPD\nThis Powershell module allows you to manage and control your [MPD](https://github.com/MusicPlayerDaemon/MPD) library and playback.\n\n## Features\n- Cross platform: runs on Linux, MacOSX and Windows.\n- Full playback control.\n- Structured access to your library: classes for tracks with their metadata, artists, albums and playlists.\n- Cmdlets for managing MPD outputs.\n- No external dependencies: the MPD protocol is implemented from scratch.\n- Comes with great tab completions.\n- As efficient as reasonable with a heavier emphasis on speed.\n- New on version 2.0: ability to synchronize state in the background.\n\n## Important\nFor many cmdlets from this module to work properly, you need to synchronize your session with the MPD server using the `Sync-MPD` cmdlet.\n\nAlso since you're likely going to be doing more things than control MPD on Powershell, this module does not keep a permanent connection to the MPD server; it connects when needed and then closes the connection.\nThis means that if you synchronized your session but modified MPD outside the module, you'll have to synchronize again, although no harm should be possible if you don't.\n\n### Note on cmdlet naming\nAs you might know, Powershell wants everyone to name cmdlets (or functions) fitting the `Verb-Noun` format.\nWhile every cmdlet in this module does that, Powershell also doesn't like if you use verbs unknown to it.\nIt will generate a warning upon loading modules with such cmdlet names:\n\u003e WARNING: The names of some imported commands from the module 'MPD' include unapproved verbs that might make them less discoverable. To find the commands with unapproved verbs, run the Import-Module command again with the Verbose parameter. For a list of approved verbs, type Get-Verb.                                                                            \n\nWhile the list of verbs it knows is usually sufficient, it wasn't the case with this module. I had to choose between awkwardly named cmdlets and getting a warning (nobody would like `Start-Pause`).\nAlthough the awkwardness could be avoided by changing the API (e.g. not `Pause-Playback` but `Set-Playback pause`), it isn't ergonomic for this module, especially if you do not wish to use a different MPD client like me.\n\nThe good news is there's a way to tell Powershell not to generate a warning. In your Powershell profile file, import the module like so:\n```powershell\nImport-Module MPD -DisableNameChecking\n```\n\n### Note on aliases\nThis module intentionally does not define any aliases. I expect people to have different opinions on naming so I'll leave you to define your own aliases in your Powershell profile.\n\n## Tips\n- You can have the module sync itself in the background when you start a new Powershell session without incurring the delay by adding to your profile:\n\t```powershell\n\t# The assignment to $null will prevent the output (which is an async Task) from being logged on your screen\n\t$null = Sync-MPD -Async\n\t```\n- You might want to set some default parameter values for `Sync-MPD` as well:\n\t```powershell\n\t$PSDefaultParameterValues[\"Sync-MPD:PlaylistsDir\" = \"D:\\Music\\Playlists\"]\n\t$PSDefaultParameterValues[\"Sync-MPD:MpdPassword\"] = \"1234\"\n\t$PSDefaultParameterValues[\"Sync-MPD:MpdHost\"] = \"raspberrypi.local\"\n\t# And so on\n\t```\n- Many cmdlets in this module report back information messages using Powershell's information pipes. Since by default Powershell won't display these, I recommend setting these in your profile:\n\t```powershell\n\t$PSDefaultParameterValues[\"Play-Track:InformationAction\"] = \"Continue\"\n\t$PSDefaultParameterValues[\"Play-Artist:InformationAction\"] = \"Continue\"\n\t$PSDefaultParameterValues[\"Play-Album:InformationAction\"] = \"Continue\"\n\t$PSDefaultParameterValues[\"Play-Playlist:InformationAction\"] = \"Continue\"\n\t$PSDefaultParameterValues[\"Save-Playing:InformationAction\"] = \"Continue\"\n\t$PSDefaultParameterValues[\"Enable-MPDOutput:InformationAction\"] = \"Continue\"\n\t$PSDefaultParameterValues[\"Disable-MPDOutput:InformationAction\"] = \"Continue\"\n\t$PSDefaultParameterValues[\"Switch-MPDOutput:InformationAction\"] = \"Continue\"\n\t$PSDefaultParameterValues[\"Set-MPDOutputAttribute:InformationAction\"] = \"Continue\"\n\t$PSDefaultParameterValues[\"Set-MPDVolume:InformationAction\"] = \"Continue\"\n\t$PSDefaultParameterValues[\"Seek-Queue:InformationAction\"] = \"Continue\"\n\t```\n\n\tIf you find that horrible to look at, you can simplify it by getting every command from this module and setting values:\n\t```powershell\n\t# Make sure `MPD` is loaded\n\tGet-Command -Module MPD | Foreach-Object {\n\t\t$PSDefaultParameterValues[\"$($_.Name):InformationAction\"] = \"Continue\"\n\t}\n\t```\n- If you use PSReadline (you likely do if you're on Powershell 7), you can assign key binds to virtually any action, including toggling playback:\n\t```powershell\n\t\tSet-PSReadLineKeyHandler -Chord Ctrl+Enter -Description \"Toggle MPD playback\" -ScriptBlock { Toggle-Playback }\n\t```\n\n## Installation\n### (Windows) With [Scoop](https://github.com/ScoopInstaller/Scoop)\n1. Register my Scoop bucket:\\\n\t`scoop bucket add insomnia https://github.com/insomnimus/scoop-bucket`\n2. Install:\\\n\t`scoop install ps-mpd`\n3. The module will automatically load on new Powershell sessions but you can load it now with `Import-Module MPD -DisableNameChecking`.\n\nScoop will take care of updates of the module from then onwards.\n\n### Manually download an archive\n1. Go to the [releases page](https://github.com/insomnimus/ps-mpd) and download the most recent archive.\n2. Go to a directory where Powershell looks for modules (check the `PSMODULEPATH` environment variable) and extract the archive into a directory called `MPD`. the directory should directly contain `MPD.psd1`.\n3. The module will automatically load on new Powershell sessions but you can load it now with `Import-Module MPD -DisableNameChecking`.\n4. You're responsible for updating it (remove old version, download and extract the archive, move to the same place).\n\n### Build the module yourself\nPrerequisites:\n- The `dotnet` command line tool, version 8 or newer (might work on older versions but isn't tested)\n- Powershell, to run the build script\n\n1. Clone the repository:\\\n\t`git clone https://github.com/insomnimus/ps-mpd`\n2. Run the build script:\n\t```powershell\n\tcd ps-mpd\n\t./build.ps1\n\t```\n3. If the build was successful, you'll have a directory containing the module written to `bin/MPD`.\n4. Copy `bin/MPD` into a directory where Powershell looks for modules (check the `PSMODULEPATH` environment varaible).\n5. The module will automatically load on new Powershell sessions but you can load it now with `Import-Module MPD -DisableNameChecking`.\n6. You're responsible for updating it (remove old version, build, copy to the same place).\n\n## Usage and documentation\nThe cmdlets come with built-in help which you can access by running `help \u003ccmdlet-name\u003e`.\nOther than that, the cmdlet names are self explanatory.\n\nFor available parameters for a cmdlet, you should use the tab completion offered natively by Powershell.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Finsomnimus%2Fps-mpd","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Finsomnimus%2Fps-mpd","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Finsomnimus%2Fps-mpd/lists"}