Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/traviskaufman/cake-autocomplete

Autocompletion for CoffeeScript's cake build system
https://github.com/traviskaufman/cake-autocomplete

Last synced: about 22 hours ago
JSON representation

Autocompletion for CoffeeScript's cake build system

Awesome Lists containing this project

README

        

Autocompletion for Cakefiles
============================
This very very small script provides autocompletion for cake, the
coffee-script build tool. It was inspired by @sgruhier's [rake
autocomplete](https://github.com/sgruhier/rake_cap_bash_autocomplete) as well
as my own personal quest towards as little keystrokes as possible.

Installation
------------
First
```sh
$ git clone git://github.com/traviskaufman/cake-autocomplete.git
```
or
```sh
$ curl -k https://raw.github.com/traviskaufman/cake-autocomplete/master/cake-autocomplete.sh > cake-autocomplete.sh
```
then,
```sh
# put a command to source the script in your startup script
$ cat>>~/.bashrc<<"EOF" # alternatively use ~/.bash_profile
> source /path/to/cake-autocomplete.sh
> EOF
$ source ~/.bashrc
```

Usage
-----
Let's say you have a `Cakefile` containing the following:
```CoffeeScript
option '-o', '--output [DIR]', 'directory to output to'

task "lint", "lint the code", ->
# ....

task "compile", "compile the code", ->
# ....

task "test", "runs unit tests", ->
# ....
```

Now in the directory where you have your `Cakefile`, if you type
```sh
$ cake [TAB]
```
you'll get
```
lint compile test
```

If you type
```sh
$ cake l[TAB]
```
you'll get
```
lint
```
If you type
```sh
$ cake compile [TAB]
```
you'll get
```
--output -o lint compile test
```
Hope this comes in handy!

License
-------
Creative
<br />Commons License
cake-autocomplete is licensed under
a Creative Commons
Attribution 3.0 Unported License