{"id":13858833,"url":"https://github.com/mmcclimon/mr_poole","last_synced_at":"2025-07-31T11:13:16.173Z","repository":{"id":10716226,"uuid":"12965363","full_name":"mmcclimon/mr_poole","owner":"mmcclimon","description":"A butler for Jekyll","archived":false,"fork":false,"pushed_at":"2015-04-26T18:28:00.000Z","size":424,"stargazers_count":155,"open_issues_count":1,"forks_count":3,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-06-24T18:11:33.903Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Ruby","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/mmcclimon.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGES.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2013-09-20T04:10:58.000Z","updated_at":"2023-06-22T20:19:01.000Z","dependencies_parsed_at":"2022-09-02T06:11:37.101Z","dependency_job_id":null,"html_url":"https://github.com/mmcclimon/mr_poole","commit_stats":null,"previous_names":[],"tags_count":16,"template":false,"template_full_name":null,"purl":"pkg:github/mmcclimon/mr_poole","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mmcclimon%2Fmr_poole","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mmcclimon%2Fmr_poole/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mmcclimon%2Fmr_poole/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mmcclimon%2Fmr_poole/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/mmcclimon","download_url":"https://codeload.github.com/mmcclimon/mr_poole/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mmcclimon%2Fmr_poole/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":267464401,"owners_count":24091494,"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","status":"online","status_checked_at":"2025-07-28T02:00:09.689Z","response_time":68,"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-08-05T03:02:22.406Z","updated_at":"2025-07-31T11:13:16.141Z","avatar_url":"https://github.com/mmcclimon.png","language":"Ruby","funding_links":[],"categories":["Ruby"],"sub_categories":[],"readme":"# Mr. Poole\n\nA butler for Jekyll. Provides a command-line interface (called `poole`) for\ncreating and publishing posts and drafts for [Jekyll](http://jekyllrb.com)\nblogs.\n\nThe literary Mr. Poole is Jekyll's butler, who \"serves Jekyll faithfully, and\nattempts to do a good job and be loyal to his master\"\n([Wikipedia](http://en.wikipedia.org/wiki/Jekyll_and_hyde#Mr._Poole)), and the\nMr. Poole gem looks to be the same thing.\n\n[![Gem Version](https://badge.fury.io/rb/mr_poole.png)](http://badge.fury.io/rb/mr_poole)\n\n[![Build Status](https://travis-ci.org/mmcclimon/mr_poole.png?branch=master)](https://travis-ci.org/mmcclimon/mr_poole)\n[![Code Climate](https://codeclimate.com/github/mmcclimon/mr_poole.png)](https://codeclimate.com/github/mmcclimon/mr_poole)\n[![Coverage Status](https://coveralls.io/repos/mmcclimon/mr_poole/badge.png)](https://coveralls.io/r/mmcclimon/mr_poole)\n\n## Usage\n\nMr. Poole is primarily a command-line application: the gem installs an\nexecutable called `poole` in your path. It has four subcommands: post, draft,\npublish, and unpublish. All four of these commands echo a filename to STDOUT,\nso you can do something like `poole post \"Title\" | vim` and start editing\nimmediately. Alternatively, you can also have Mr. Poole auto open new posts in your preferred `$EDITOR` (see [Configuration](#configuration)).\n\n### Post\n\n    poole post [OPTIONS] TITLE\n\nGenerates a timestamped post in your `_posts` directory, with the format\n`YYYY-MM-DD-slug.md`. With no options, will generate a slug based on your title\nby replacing spaces with underscores, downcasing, and removing any special\ncharacter (see configuration section if you don't like the underscores).\n\nOptions:\n\n```\n-s, --slug      Define a custom slug for post, used for generated file name\n\n-t, --title     Define a title for post. This option may be omitted provided\n                that TITLE is given as the last argument to poole\n\n-l, --layout    Path to a custom layout file to use\n```\n\nBy default, poole generates a simple file that looks like this (but see section\non configuration for more options).\n\n```yaml\n---\ntitle: (your title automatically inserted here)\nlayout: post\ndate: (current date automatically inserted here)\n---\n```\n\n### Draft\n\n    poole draft [OPTIONS] TITLE\n\nJust like `poole post`, except that it creates an untimestamped post in your\n`_drafts` directory (creating it if it doesn't exist yet). Uses same options\nas `post`. In the generated file, no date is inserted.\n\n### Publish\n\n    poole publish [OPTIONS] DRAFT_PATH\n\nPublishes a draft from your _drafts folder to your _posts folder By default,\nrenames the file and updates the date in the header, but see options:\n\n```\n-d, --keep-draft        Do not delete the draft post'\n-t, --keep-timestamp    Do not update the draft timestamp'\n```\n\nGiven this file (called `_drafts/test_draft.md`):\n\n```\n---\ntitle: My awesome blog post\nlayout: post\ndate:\n---\n\nThe life, universe, and everything.\n```\n\nA call to `poole publish _drafts/test_draft.md` will generate a file named\n`_posts/yyyy-mm-dd-test_draft.md` and delete the draft. Also updates the date\nfiled in the header with a date, and HH:MM, producing this file:\n\n```\n---\ntitle: My awesome blog post\nlayout: post\ndate: 2010-01-02 16:00\n---\n\nThe life, universe, and everything.\n```\n\n### Unpublish\n\n    poole unpublish POST_PATH\n\nThe reverse of publish: moves a file from your _posts folder to the _drafts\nfolder, renaming the file and removing the date in the header. This will\nrename a file called `_posts/yyyy-mm-dd-test_post.md` to\n`_drafts/test_post.md`.\n\n```\n-p, --keep-post         Do not delete the existing post'\n-t, --keep-timestamp    Do not update the existing timestamp'\n```\n\n### Script usage\n\nThe actual work is done in `MrPoole::Commands`: calls into that class return\nthe path name for newly created files, so you can do something useful with\nthem if you want to. This should get better in the future.\n\n## Configuration\n\nYou may also include directives for `poole` in Jekyll's `_config.yml` file. You\nshould provide a `poole` key, which may take the following subkeys:\n\n- `default_layout` - path to a default layout to use\n- `default_extension` - file extension to use\n- `word_separator` - character to use for slug generation\n- `time_format` - a percent-formatted string suitable for passing to Ruby's [Time.strftime](http://www.ruby-doc.org/core-2.1.1/Time.html#method-i-strftime) method\n- `auto_open` - set to `true`to automatically open new posts in your `$EDITOR`\n\nAny options you provide in `_config.yml` will override poole's built-in\ndefaults. Mr. Poole defaults to using Markdown (with extension \"md\"), and the\ndefault layout is given above in the \"Post\" section. The default layout is\nactually just YAML front matter for Jekyll, so it can be used with any\nextension.\n\nNote that command-line options override anything set in your config file. For\nexample, if you have your default extension set to `textile`, but then pass the\n`--layout` flag to post/draft with a Markdown template, the generated post will\nuse the Markdown extension.\n\n*Important!* Certain characters have special meaning in YAML, which means\nyou'll need to be careful using certain options.\n\nIf you want to use hyphens for the `word_separator` option, you'll\nneed to escape it (because a single dash is the beginning a YAML bulleted\nlist). If you don't, the YAML parser will choke (I don't have any control over\nthis).\n\n```\npoole:\n  word_separator: \"-\"   # correct\n  word_separator: -     # WRONG...don't do this!\n```\n\nLikewise, Ruby's\n[`strftime`](http://www.ruby-doc.org/core-2.1.1/Time.html#method-i-strftime)\nuses percent-formatted strings. The percent sign is special in YAML, so you\nhave to put the time format in quotation marks.\n\n```\npoole:\n  time_format: \"%Y-%m-%d\"   # correct\n  time_format: %Y-%m-%d     # WRONG...poole will exit\n```\n\n\n## To do\n\n- Configuration: hooking into jekyll's `_config.yml` (mostly done)\n- Support for multiple output formats (done, but needs better tests)\n- Better option handling (more flexible date substitution)\n- Better documentation (this is an open source project, after all)\n\n## Installation\n\nAdd this line to your application's Gemfile:\n\n    gem 'mr_poole'\n\nAnd then execute:\n\n    $ bundle\n\nOr install it yourself as:\n\n    $ gem install mr_poole\n\n## Contact\n\nContact me on Github, at michael@mcclimon.org, or on twitter, @mmcclimon.\n\n## Contributing\n\n1. Fork it\n2. Create your feature branch (`git checkout -b my-new-feature`)\n3. Commit your changes (`git commit -am 'Add some feature'`)\n4. Push to the branch (`git push origin my-new-feature`)\n5. Create new Pull Request\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmmcclimon%2Fmr_poole","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmmcclimon%2Fmr_poole","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmmcclimon%2Fmr_poole/lists"}