Skip to content

Commit 94142f4

Browse files
committed
README updates, doc/quickstart updates
1 parent 87f4dd2 commit 94142f4

File tree

2 files changed

+67
-30
lines changed

2 files changed

+67
-30
lines changed

README.rst

Lines changed: 49 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -16,35 +16,48 @@ Open to testers
1616

1717
tmuxp is still **alpha** code and needs a few more weeks until stable.
1818
See the `Issues tracker`_ to see known issues and for any other concerns.
19-
20-
``tmuxp``, a novel approach to managing `tmux(1)`_ workspaces through
21-
python objects. Features:
22-
23-
- Load + switch to new session from inside tmux.
24-
- bash / zsh / tcsh completion
25-
- JSON, YAML and `python dict`_ configuration.
26-
- Support for pre-commands with ``shell_command_before`` to load
27-
virtualenv / rvm / any other commands.
28-
- Session resuming from config file if already running.
29-
- Per-project tmux sessions
30-
- uses tmux 1.8's ``pane_id``, ``window_id`` and ``session_id`` to build
31-
create python objects to build workspaces with the freshest data.
3219

33-
tmuxp works in 3 ways:
3420

35-
- a pythonic `abstraction layer`_ on top of tmux' CLI commands
36-
- an `ORM`_ that internally orchestrates relations between servers,
37-
sessions, windows and panes for good and evil purposes.
38-
- CLI tmux session manager, similar to `teamocil`_ and `tmuxinator`_, with
39-
support for YAML, JSON and python dicts.
21+
tmux bash completion
22+
--------------------
23+
24+
.. code-block:: bash
4025
41-
Get started
42-
-----------
26+
$ tmuxp attach-session<tab>
27+
$ tmuxp kill-session<tab>
28+
$ tmuxp load<tab>
29+
30+
.. seealso:: `bash completion`_
31+
32+
load tmux sessions from yaml and json
33+
--------------------------------------
34+
35+
.. code-block:: bash
36+
37+
$ tmuxp load .
38+
39+
Load from ``~/.tmuxp.yaml`` or ``~/.tmuxp.json`` in current directory.
40+
41+
.. code-block:: bash
4342
44-
Get the prerequisites:
43+
$ tmuxp load myconfig.yaml
4544
46-
1. installed ``tmux``, at least version **1.8**
47-
2. libyaml is installed for your distribution.
45+
Load ``myconfig.yaml``, checking current directory, then
46+
``$HOME/.tmuxp/myconfig.yaml``.
47+
48+
tmuxp will prompt you if session is already running, press ``[Enter]``
49+
to attach the session automatically.
50+
51+
If you load a config from *inside* tmux, tmuxp will offer to attach it
52+
for you.
53+
54+
.. seealso:: `Examples`_
55+
56+
Install
57+
-------
58+
59+
- install ``tmux``, at least version **1.8**
60+
- libyaml is installed for your distribution.
4861

4962
Install ``tmuxp``:
5063

@@ -59,17 +72,28 @@ Install ``tmuxp``:
5972
session_name: my session
6073
windows:
6174
- window_name: my test window
75+
shell_command_before: cd ~
6276
panes:
6377
- pwd
6478
- pwd
6579
80+
6681
Now with ``tmuxp``:
6782

6883
.. code-block:: bash
6984
7085
$ tmuxp test.yaml
7186
72-
Check out our `Examples`_, `Quickstart`_ and `bash completion`_ support.
87+
.. seealso:: `Quickstart`_
88+
89+
tmuxp works in 3 ways:
90+
91+
- a pythonic `abstraction layer`_ on top of tmux' CLI commands
92+
- an `ORM`_ that internally orchestrates relations between servers,
93+
sessions, windows and panes for good and evil purposes.
94+
- CLI tmux session manager, similar to `teamocil`_ and `tmuxinator`_, with
95+
support for YAML, JSON and python dicts.
96+
7397

7498
Advanced tmux workflow:
7599

doc/quickstart.rst

Lines changed: 18 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -71,12 +71,15 @@ For zsh:
7171
Python ORM + AL
7272
---------------
7373

74-
ORM - Object Relational Mapper
74+
`ORM` - Object Relational Mapper
7575

76-
AL - Abstraction Layer
76+
`AL`_ - Abstraction Layer
7777

78-
Conventions
79-
"""""""""""
78+
.. _abstraction layer: http://en.wikipedia.org/wiki/Abstraction_layer
79+
.. _ORM: http://en.wikipedia.org/wiki/Object-relational_mapping
80+
81+
python abstraction layer
82+
""""""""""""""""""""""""
8083

8184
.. module:: tmuxp
8285

@@ -98,8 +101,18 @@ Conventions
98101
tmux ORM
99102
""""""""
100103

101-
tmuxp's main internal feature is to abstract tmux into relational objects.
104+
tmuxp's core internal feature is the object relation and orchestration of
105+
the tmux server (think an `engine`_ in `SQLAlchemy`_) and the server's
106+
sessions, so on...
102107

103108
- :class:`Server` holds :class:`Session` objects.
104109
- :class:`Session` holds :class:`Window` objects.
105110
- :class:`Window` holds :class:`Pane` objects.
111+
112+
instances of tmux objects use tmux `1.8`_'s ``pane_id``, ``window_id`` and
113+
``session_id`` to build create python objects to build workspaces with the
114+
freshest data.
115+
116+
.. _engine: http://docs.sqlalchemy.org/en/rel_0_8/core/engines.html
117+
.. _sqlalchemy: http://www.sqlalchemy.org/
118+
.. _1.8: http://sourceforge.net/projects/tmux/files/tmux/tmux-1.8/

0 commit comments

Comments
 (0)