Skip to content
🐶 HashiCorp CLI snippets for pet
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Type Name Latest commit message Commit time
Failed to load latest commit information.


 _               _     _            _
| |__   __ _ ___| |__ (_)_ __   ___| |_ ___
| '_ \ / _` / __| '_ \| | '_ \ / _ \ __/ __|
| | | | (_| \__ \ | | | | |_) |  __/ |_\__ \
|_| |_|\__,_|___/_| |_|_| .__/ \___|\__|___/



hashipets is a collection of CLI snippets for use with HashiCorp tools like Consul, Nomad, Packer, Terraform, Vagrant, and Vault.

The snippets are kept in a TOML formatted file that is compatible with the simple command-line snippet manager pet.

NOTE: The commands in hashipets.toml should reflect those available in recent versions of the tool they apply to.


It's a tool and workflow for recalling and sharing complex CLI one-liners and seldom used but otherwise useful command line invocations.


Using the fantastic CLI utility pet and the hashipets.toml in this repository, you'll be commanding HashiCorp tools like a pro in no time!

Quick Start for macOS

  1. Clone this repository within some $DIR
  2. Install pet: brew install knqyf263/pet/pet
  3. Configure: pet configure
  4. Point snippetfile to $DIR/hashipets/hashipets.toml, save, and exit
  5. 🎉

What's Next?

You can optionally customize the peco fuzzy finder tool like so:

$ mkdir $HOME/.config/peco && \
  cp $DIR/hashipets/peco_config.json $_/config.json

Then use pet in awesome ways:

List all snippets

$ pet list

Search snippets

$ pet search

Add search result to clipboard on macOS

$ pet search | pbcopy

Execute a snippet

$ pet exec

Interactively add a snippet

$ pet new
Command> curl -s <consul_http_addr>/v1/status/peers
Description> Get Consul server peers from HTTP API

See the pet documentation for more ways to use it!


Here are some links to resources for the technologies used in this project:


hashipets was created by Brian Shumate and made possible through the generous time of the good people named in

Special Thanks

Thanks to Teppei Fukuda for making pet!

You can’t perform that action at this time.