Update README.md with GitHub-flavored Markdown syntax highlighting

This commit is contained in:
Rémi Prévost 2011-12-10 08:11:36 -05:00
parent 11af9bfe85
commit 4a6abd75a8

View File

@ -4,11 +4,13 @@ Teamocil is a simple tool used to automatically create sessions, windows and spl
## Usage ## Usage
$ gem install teamocil ```bash
$ mkdir ~/.teamocil $ gem install teamocil
$ teamocil --edit sample $ mkdir ~/.teamocil
$ tmux $ teamocil --edit sample
$ teamocil sample $ tmux
$ teamocil sample
```
## Options ## Options
@ -30,10 +32,12 @@ You can wrap your entire layout file in a `session` and Teamocil will rename the
#### Example #### Example
session: ```yaml
name: my-awesome-session session:
name: "my-awesome-session"
windows: windows:
[windows list] [windows list]
```
### Windows ### Windows
@ -49,27 +53,27 @@ If you are not using a top-level `session` key, then the first key of your layou
#### Example #### Example
windows: ```yaml
- name: my-first-window windows:
- name: "my-first-window"
options: options:
synchronize-panes: true synchronize-panes: true
root: ~/Projects/foo-www root: "~/Projects/foo-www"
filters: filters:
before: before:
- "echo 'Lets use ruby-1.9.2 for each split in this window.'" - "echo 'Lets use ruby-1.9.2 for each split in this window.'"
- "rvm use 1.9.2" - "rvm use 1.9.2"
splits: splits:
[splits list] [splits list]
- name: my-second-window - name: "my-second-window"
root: ~/Projects/foo-api root: "~/Projects/foo-api"
filters:
after: "rvm use 1.9.2"
splits: splits:
[splits list] [splits list]
- name: my-third-window - name: "my-third-window"
root: ~/Projects/foo-daemons root: "~/Projects/foo-daemons"
splits: splits:
[splits list] [splits list]
```
### Splits ### Splits
@ -84,9 +88,10 @@ Every window must define an array of splits that will be created within it. A ve
#### Example #### Example
windows: ```yaml
- name: my-first-window windows:
root: ~/Projects/foo-www - name: "my-first-window"
root: "~/Projects/foo-www"
filters: filters:
before: "rvm use 1.9.2" before: "rvm use 1.9.2"
after: "echo 'I am done initializing this split.'" after: "echo 'I am done initializing this split.'"
@ -95,9 +100,10 @@ Every window must define an array of splits that will be created within it. A ve
- cmd: "bundle exec rails server --port 4000" - cmd: "bundle exec rails server --port 4000"
width: 50 width: 50
- cmd: - cmd:
- sudo service memcached start - "sudo service memcached start"
- sudo service mongodb start - "sudo service mongodb start"
height: 50 height: 50
```
## Layout examples ## Layout examples
@ -107,15 +113,16 @@ See more example files in the `examples` directory.
#### Content of `~/.teamocil/sample-1.yml` #### Content of `~/.teamocil/sample-1.yml`
windows: ```yaml
- name: sample-two-splits windows:
root: ~/Code/sample/www - name: "sample-two-splits"
root: "~/Code/sample/www"
splits: splits:
- cmd: - cmd: ["pwd", "ls -la"]
- pwd - cmd: "rails server --port 3000"
- ls -la
- cmd: rails server --port 3000
width: 50 width: 50
```
#### Result of `$ teamocil sample-1` #### Result of `$ teamocil sample-1`
@ -135,19 +142,21 @@ See more example files in the `examples` directory.
#### Content of `~/.teamocil/sample-2.yml` #### Content of `~/.teamocil/sample-2.yml`
windows: ```yaml
- name: sample-four-splits windows:
root: ~/Code/sample/www - name: "sample-four-splits"
root: "~/Code/sample/www"
splits: splits:
- cmd: pwd - cmd: "pwd"
- cmd: pwd - cmd: "pwd"
width: 50 width: 50
- cmd: pwd - cmd: "pwd"
height: 50 height: 50
target: bottom-right target: "bottom-right"
- cmd: pwd - cmd: "pwd"
height: 50 height: 50
target: bottom-left target: "bottom-left"
```
#### Result of `$ teamocil sample-2` #### Result of `$ teamocil sample-2`
@ -169,7 +178,9 @@ See more example files in the `examples` directory.
To get autocompletion when typing `teamocil <Tab>` in a zsh session, add this line to your `~/.zshrc` file: To get autocompletion when typing `teamocil <Tab>` in a zsh session, add this line to your `~/.zshrc` file:
compctl -g '~/.teamocil/*(:t:r)' teamocil ```zsh
compctl -g '~/.teamocil/*(:t:r)' teamocil
```
## Todo list ## Todo list