aziz/tmuxinator — pull request #94 by dougnukem (2013-01-26 01:10:04+00:00)
Title: tmuxinator_completion on OSX not completing on project *.yml names

I'm having an issue with the tmuxinator_completion for version 0.5.0 on OSX. I've used rvm to install the gem, and have the tmuxinator_completion added to my .bashrc

When I use it to tab-complete the commands it works fine for the top-level actions:

```
$ mux
copy delete doctor help implode list open update_scripts version
```

But it doesn't seem to pickup any of the *.yml files in ~/.tmuxinator because the find command uses a trailing "/" which on OSX get's echoed:

```
$ find ~/.tmuxinator/ -name *.yml
/Users/ddaniels/.tmuxinator//project-dev-ops.yml
/Users/ddaniels/.tmuxinator//project.yml
```

Then it fails to cut properly because it's looking for the 5th field and it is actually the 6th.

I think the proper solution should avoid making assumptions on the exact path length (e.g. if some setup isn't under a "/home/user/.tmuxinator" but instead "/home/org/users/").

I suggest that piping the find results to basename would work (and I believe should be cross platform compatible)

```
find -L ~/.tmuxinator -name *.yml | xargs -I {} basename {} | sed s:.yml::g
```