{"id":21905067,"url":"https://github.com/kenjyco/mocp-cli","last_synced_at":"2025-07-20T07:33:58.419Z","repository":{"id":54612226,"uuid":"82987367","full_name":"kenjyco/mocp-cli","owner":"kenjyco","description":"CLI tools for finding, organizing, and playing audio files","archived":false,"fork":false,"pushed_at":"2024-11-30T17:00:05.000Z","size":54,"stargazers_count":7,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-06-21T16:49:15.033Z","etag":null,"topics":["cli","console-audio","kenjyco","moc","python","repl"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/kenjyco.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.txt","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,"zenodo":null}},"created_at":"2017-02-24T01:12:12.000Z","updated_at":"2024-11-30T17:00:09.000Z","dependencies_parsed_at":"2025-04-15T23:43:45.467Z","dependency_job_id":null,"html_url":"https://github.com/kenjyco/mocp-cli","commit_stats":{"total_commits":76,"total_committers":1,"mean_commits":76.0,"dds":0.0,"last_synced_commit":"b22ea0217ebc9d99fc7245bcd9bffa400f3909c6"},"previous_names":[],"tags_count":22,"template":false,"template_full_name":null,"purl":"pkg:github/kenjyco/mocp-cli","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kenjyco%2Fmocp-cli","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kenjyco%2Fmocp-cli/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kenjyco%2Fmocp-cli/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kenjyco%2Fmocp-cli/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/kenjyco","download_url":"https://codeload.github.com/kenjyco/mocp-cli/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kenjyco%2Fmocp-cli/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":266085763,"owners_count":23874481,"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":["cli","console-audio","kenjyco","moc","python","repl"],"created_at":"2024-11-28T16:28:22.680Z","updated_at":"2025-07-20T07:33:58.380Z","avatar_url":"https://github.com/kenjyco.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"## Install\n\nInstall the actual [MOC player/server](https://moc.daper.net/)\n\n```\n% sudo apt-get install -y moc\n\nor\n\n% brew install moc\n```\n\nIf you **don't have [docker](https://docs.docker.com/get-docker) installed**,\ninstall Redis and start server\n\n```\n% sudo apt-get install -y redis-server\n\nor\n\n% brew install redis\n% brew services start redis\n```\n\nInstall with `pip`\n\n```\n% pip3 install mocp-cli\n```\n\n## Optional Installs\n\n### yt-helper\n\nA lot of what powers the cool interactive features are provided by the\n`COMMENTS` and `FILES` `redis_helper.Collections` defined in `yt_helper`.\n\nInstall with `pip`\n\n```\n% pip3 install yt-helper\n\nor\n\n% pip3 install \"mocp-cli[extras]\"\n```\n\n## Usage\n\nThe `mocplayer` script is provided\n\n```\n$ venv/bin/mocplayer --help\nUsage: mocplayer [OPTIONS] [GLOB_PATTERNS]...\n\n  Start a REPL to control music on console player (mocp)\n\nOptions:\n  --help  Show this message and exit.\n```\n\nCalling `mocplayer` will start a REPL that will send commands to the running\ninstance of `mocp --server`. Any arguments passed to `mocplayer` are assumed to\nbe glob patterns that should be passed to the `moc.find_and_play` function.\n\n```\n% venv/bin/mocplayer\n:docstrings to see all colon commands\n:shortcuts to see all hotkeys\n\nmocplayer\u003e ?\n Loop forever, receiving character input from user and performing actions\n\n    - ^d or ^c to break the loop\n    - ':' to enter a command (and any arguments)\n        - any method defined on GetCharLoop (or a sub-class) will be callable\n          as a \"colon command\" (if its name does not start with '_')\n        - the method for the `:command` should only accept `*args`\n    - '-' to allow user to provide input that will be processed by the `input_hook`\n    - '?' to show the class docstring(s) and the startup message\n\nA wrapper to control moc (music on console) player with vim keybindings\n\n:docstrings to see all colon commands\n:shortcuts to see all hotkeys\n\nmocplayer\u003e :docstrings\n.:: delete ::.\nDelete current audio file and remove related data from COMMENTS\n\n.:: delete_comments ::.\nSelect comments/marks for currently playing file to delete\n\n.:: docstrings ::.\nPrint/return the docstrings of methods defined on this class\n\n.:: edit_timestamp ::.\nSelect comment/mark for currently playing file to edit the timestamp\n\n.:: errors ::.\nPrint/return any colon commands that raised exceptions (w/ traceback)\n\n.:: find ::.\nFind and select audio files at specified glob patterns\n\n.:: go ::.\nGo to a particular timestamp\n\n.:: history ::.\nPrint/return successful colon commands used\n\n.:: ipython ::.\nStart ipython shell. To continue back to the input loop, use 'ctrl + d'\n\n.:: jump ::.\nJump to a saved comment/mark\n\n.:: jumploop ::.\nLoop an unbuffered input session, jumping between selected marks (up to 62)\n\n.:: most_commented ::.\nSelect files that have been most commented and play (up to 62)\n\n.:: pdb ::.\nStart pdb (debugger). To continue back to the input loop, use 'c'\n\n.:: recent_files ::.\nSelect files that were most recently added and play (up to 62)\n\n.:: seek ::.\nSeek forward or backward\n\n.:: shortcuts ::.\nPrint/return any hotkey shortcuts defined on this class\n\n\nmocplayer\u003e :shortcuts\n' ' -- pause/unpause\n'i' -- show info about currently playing file\n'm' -- mark the current timestamp\n'c' -- show comments/marks (requires yt_helper package)\n'C' -- select files that have been most commented and play (requires yt_helper package)\n'R' -- select files that were most recently added and play (requires yt_helper package)\n'J' -- jump to a saved comment or mark (requires yt_helper package)\n'e' -- select comment/mark to edit timestamp (requires yt_helper package)\n'd' -- select comments/marks to delete (requires yt_helper package)\n'f' -- find and play audio files found in current directory\n'F' -- find, select, and play audio files found in current directory\n'q' -- quit\n'Q' -- stop MOC server and quit\n'n' -- next file in playlist\n'p' -- previous file in playlist\n'H' -- rewind 30 seconds\n'h' -- rewind 5 seconds\n'\\x1b[D' -- rewind 1 second (left arrow)\n'L' -- fast foward 30 seconds\n'l' -- fast foward 5 seconds\n'\\x1b[C' -- fast foward 1 second (right arrow)\n'j' -- lower volume\n'\\x1b[B' -- lower volume (down arrow)\n'k' -- raise volume\n'\\x1b[A' -- raise volume (up arrow)\n\nmocplayer\u003e i\n00:55 (55) of 43:03 into /tmp/Samurai_Champloo_-_Lofi_HipHop_Mix_Nujabes_inspired-kq7cQNO0gYc.mp3\nmocplayer\u003e :go 12:00\nmocplayer\u003e i\n12:00 (720) of 43:03 into /tmp/Samurai_Champloo_-_Lofi_HipHop_Mix_Nujabes_inspired-kq7cQNO0gYc.mp3\nmocplayer\u003e :go 500\nmocplayer\u003e i\n08:20 (500) of 43:03 into /tmp/Samurai_Champloo_-_Lofi_HipHop_Mix_Nujabes_inspired-kq7cQNO0gYc.mp3\nmocplayer\u003e :seek -45\nmocplayer\u003e i\n07:42 (462) of 43:03 into /tmp/Samurai_Champloo_-_Lofi_HipHop_Mix_Nujabes_inspired-kq7cQNO0gYc.mp3\nmocplayer\u003e L\nmocplayer\u003e L\nmocplayer\u003e L\nmocplayer\u003e i\n09:32 (572) of 43:03 into /tmp/Samurai_Champloo_-_Lofi_HipHop_Mix_Nujabes_inspired-kq7cQNO0gYc.mp3\n```\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkenjyco%2Fmocp-cli","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fkenjyco%2Fmocp-cli","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkenjyco%2Fmocp-cli/lists"}