{"id":26088809,"url":"https://github.com/fuzzyideas/musicdecoy","last_synced_at":"2025-04-06T12:07:22.968Z","repository":{"id":204928370,"uuid":"712787043","full_name":"FuzzyIdeas/MusicDecoy","owner":"FuzzyIdeas","description":null,"archived":false,"fork":false,"pushed_at":"2025-03-07T19:16:02.000Z","size":253,"stargazers_count":150,"open_issues_count":0,"forks_count":1,"subscribers_count":4,"default_branch":"main","last_synced_at":"2025-03-30T11:06:17.731Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Objective-C","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/FuzzyIdeas.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":"2023-11-01T07:35:15.000Z","updated_at":"2025-03-28T03:58:55.000Z","dependencies_parsed_at":null,"dependency_job_id":"6125f6a6-8236-4220-984f-6e1f653eee0a","html_url":"https://github.com/FuzzyIdeas/MusicDecoy","commit_stats":null,"previous_names":["fuzzyideas/musicdecoy"],"tags_count":2,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/FuzzyIdeas%2FMusicDecoy","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/FuzzyIdeas%2FMusicDecoy/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/FuzzyIdeas%2FMusicDecoy/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/FuzzyIdeas%2FMusicDecoy/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/FuzzyIdeas","download_url":"https://codeload.github.com/FuzzyIdeas/MusicDecoy/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247478318,"owners_count":20945266,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","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":"2025-03-09T08:19:43.725Z","updated_at":"2025-04-06T12:07:22.943Z","avatar_url":"https://github.com/FuzzyIdeas.png","language":"Objective-C","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003cp align=\"center\"\u003e\n    \u003ca href=\"https://files.lowtechguys.com/MusicDecoy.zip\"\u003e\u003cimg width=\"128\" height=\"128\" src=\"Music/Assets.xcassets/AppIcon.appiconset/icon_256x256.png\" style=\"filter: drop-shadow(0px 2px 4px rgba(80, 50, 6, 0.2));\"\u003e\u003c/a\u003e\n    \u003ch1 align=\"center\"\u003e\u003ccode style=\"text-shadow: 0px 3px 10px rgba(8, 0, 6, 0.35); font-size: 3rem; font-family: ui-monospace, Menlo, monospace; font-weight: 800; background: transparent; color: #4d3e56; padding: 0.2rem 0.2rem; border-radius: 6px\"\u003eMusic Decoy\u003c/code\u003e\u003c/h1\u003e\n    \u003ch4 align=\"center\" style=\"padding: 0; margin: 0; font-family: ui-monospace, monospace;\"\u003eStop launching the Music app\u003cbr\u003ewhenever you press \u003cb\u003e▶ Play\u003c/b\u003e\u003c/h4\u003e\n\u003c/p\u003e\n\n\u003cp align=\"center\"\u003e\n    \u003ca href=\"https://files.lowtechguys.com/MusicDecoy.zip\"\u003e\n        \u003cimg width=300 src=\"https://files.alinpanaitiu.com/download-button-dark.svg\"\u003e\n    \u003c/a\u003e\n\u003c/p\u003e\n\n## Installation\n\n- Download, unzip, move to `/Applications`\n- or.. `brew install music-decoy`\n\n\n## What does this do?\n\nNothing. The app does absolutely nothing while running. 0% CPU all day long.\n\nBut by simply having it running, the macOS system won't launch the Music app whenever you accidentally press Play.\n\nIt won't launch Music even if you try to launch it manually! *that might not actually be a good thing, but.. oh well*\n\n## How does it achieve that?\n\nBy having the same bundle identifier as the system Music app: `com.apple.Music`\n\nIn more technical terms, this is what I found out about how the **▷ Play** mechanism works:\n\n1. The `Play` event is caught by the `rcd` daemon (living at `/System/Library/CoreServices/rcd.app/Contents/MacOS/rcd`)\n2. The daemon checks if there is any app playing something and forwards the event to that app\n3. If there is no such app, `rcd` checks if any running app has `com.apple.Music` as its bundle identifier\n    - Without a running `com.apple.Music` app, `rcd` launches the system Music app\n    - *But if there is such an app, the event is forwarded to it instead*\n\n## Uh.. how do I quit this app?\n\nThe app has no Dock icon and no menubar icon so to quit it you'd need to do *one of the following*:\n\n- Launch **Activity Monitor**, find **Music Decoy** and press the ❌ button at the top\n- Run the following command in the Terminal: `killall 'Music Decoy'`\n\n## Configuration\n\nSince v1.1 you can configure Music Decoy to launch another app when the **▷ Play** button is pressed.\n\nTo do that, run the following command in the Terminal *(example for Spotify)*:\n\n```sh\ndefaults write com.lowtechguys.MusicDecoy mediaAppPath /Applications/Spotify.app\n```\n\nTo reset the configuration, run:\n\n```sh\ndefaults delete com.lowtechguys.MusicDecoy mediaAppPath\n```\n\n## Alternatives\n\nBased on [this StackExchange answer](https://apple.stackexchange.com/questions/372948/how-can-i-prevent-music-app-from-starting-automatically-randomly), there are a few different ways to achieve the same effect:\n\n- `launchctl unload -w /System/Library/LaunchAgents/com.apple.rcd.plist`\n    - Problem: *disables the Play button completely*\n- [noTunes](https://github.com/tombonez/noTunes) which listens for launched apps and kills Music as soon as it is launched\n    - Problem: *it does use a tiny bit of CPU in the background* although checking for launched apps is very little work\n\n## *Frequently* asked questions?\n\nI think they were only asked once, and they might not even be questions but I might as well record the info for posterity.\n\n### VLC crashes\n\nLooks like VLC tries to use [ScriptingBridge](https://developer.apple.com/documentation/scriptingbridge) to send commands to the Music app.\n\n```sh\nwarning: failed to get scripting definition from /Applications/Music Decoy.app; it may not be scriptable.\n-[SBApplication playerState]: unrecognized selector sent to instance 0x600003399050\n```\n\nYou can fix this by configuring the following setting:\n\n![vlc setting for music decoy](https://files.lowtechguys.com/vlc-music-decoy-setting.png)\n\n### How do I launch Music?\n\nYou can use this macOS Shortcut: [Music.shortcut](https://github.com/FuzzyIdeas/MusicDecoy/raw/main/Assets/Music.shortcut)\n\nIt will quit Music Decoy and launch the Music app, with a small delay between the two actions.\n\nYou can add it to your Dock for easy access:\n\n![add to dock option](Assets/add-to-dock.png)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffuzzyideas%2Fmusicdecoy","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ffuzzyideas%2Fmusicdecoy","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffuzzyideas%2Fmusicdecoy/lists"}