README.md in nutrella-1.5.4 vs README.md in nutrella-1.6.0

- old
+ new

@@ -1,10 +1,9 @@ # Nutrella [![Gem Version](http://img.shields.io/gem/v/nutrella.svg?style=flat)](https://rubygems.org/gems/nutrella) [![Code Climate](https://codeclimate.com/github/amckinnell/nutrella/badges/gpa.svg)](https://codeclimate.com/github/amckinnell/nutrella) -[![Build Status](https://travis-ci.org/amckinnell/nutrella.svg?branch=master)](https://travis-ci.org/amckinnell/nutrella) A command line tool for associating a Trello board with the current git branch. ## Table of Contents @@ -43,11 +42,11 @@ **Step 5**: Update configuration file If your haven't already done so, insert your `key`, `secret`, and `token` into your `~/.nutrella.yml` file. -The configuration file should look like the following (don't use the keys below, they won't work): +The configuration file should look like the following (don't use the keys below as they won't work for you): ```yaml # Trello Developer API Keys key: c2fc703429da08b6e7dcb0a878e35564 secret: 7fd865f372891afa93aabdb6b836254bcda10c8a320def2b3207e2ffb425bc0a @@ -57,10 +56,11 @@ organization: 542d76ac2fad4697c3e80448 launch_command: open $url$ enable_trello_app: false enable_logging: true cache_capacity: 5 + cache_first: '^PM-\d+' ``` **Step 6**: Adjust configuration file (Optional) Adjust the `launch_command` configuration to fit your needs. @@ -87,25 +87,46 @@ ```yaml cache_capacity: 15 ``` +Adjust the `cache_first` configuration to allow searching the cache first before creating or opening a Trello board: +```yaml + cache_first: '^(PM|QC)-\d+' +``` + +The string that you specify will be treated as a regular expression. + + + ## Usage -Create or open a Trello board based on the name of the current git branch: +There are three ways to invoke the nutrella command: -```sh +1. Create or open a Trello board based on the name of the current git branch: + + ```sh $ nutrella -``` + ``` + + This is the command invocation that should meet your needs 90% of the time. -Create or open a named Trello board: -```sh +1. Create or open a named Trello board using the full git branch name: + + ```sh $ nutrella <git-branch-name> -``` + ``` -Note: you can invoke `nutrella` from your project directory or from any subdirectory. + +2. Create or open a previously created Trello board using a JIRA ticket like `PM-9423`: + + ```sh + $ nutrella <JIRA Ticket> + ``` + + This behaviour relies on the `cache_first` configuration setting. Invoking `nutrella` with a JIRA ticket number is for those situations where you make multiple git branches for the same JIRA ticket with a different suffix. ## Troubleshooting 1. If an unexpected Trello board is opening try clearing your cache: