Skip to content

Commit e788ab5

Browse files
committed
Move rest of tmuxinator configs to fixtures
1 parent 3141d81 commit e788ab5

File tree

8 files changed

+406
-390
lines changed

8 files changed

+406
-390
lines changed
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
from . import test1, test2, test3 # noqa
Lines changed: 49 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,49 @@
1+
from .._util import loadfixture
2+
3+
4+
tmuxinator_yaml = loadfixture('config_tmuxinator/test1.yaml')
5+
tmuxinator_dict = {
6+
'windows': [
7+
{
8+
'editor': {
9+
'layout': 'main-vertical',
10+
'panes': [
11+
'vim',
12+
'guard'
13+
]
14+
}
15+
},
16+
{
17+
'server': 'bundle exec rails s',
18+
},
19+
{
20+
'logs': 'tail -f logs/development.log'
21+
}
22+
]
23+
}
24+
25+
tmuxp_dict = {
26+
'session_name': None,
27+
'windows': [
28+
{
29+
'window_name': 'editor',
30+
'layout': 'main-vertical',
31+
'panes': [
32+
'vim',
33+
'guard'
34+
]
35+
},
36+
{
37+
'window_name': 'server',
38+
'panes': [
39+
'bundle exec rails s'
40+
]
41+
},
42+
{
43+
'window_name': 'logs',
44+
'panes': [
45+
'tail -f logs/development.log'
46+
]
47+
}
48+
]
49+
}
Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
windows:
2+
- editor:
3+
layout: main-vertical
4+
panes:
5+
- vim
6+
- guard
7+
- server: bundle exec rails s
8+
- logs: tail -f logs/development.log
Lines changed: 132 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,132 @@
1+
from .._util import loadfixture
2+
3+
4+
tmuxinator_yaml = loadfixture('config_tmuxinator/test2.yaml')
5+
6+
tmuxinator_dict = {
7+
'project_name': 'sample',
8+
'project_root': '~/test',
9+
'socket_name': 'foo',
10+
'pre': 'sudo /etc/rc.d/mysqld start',
11+
'rbenv': '2.0.0-p247',
12+
'cli_args': '-f ~/.tmux.mac.conf',
13+
'tabs': [
14+
{
15+
'editor': {
16+
'pre': [
17+
'echo "I get run in each pane, '
18+
'before each pane command!"',
19+
None
20+
],
21+
'layout': 'main-vertical',
22+
'panes': [
23+
'vim',
24+
None,
25+
'top'
26+
]
27+
}
28+
},
29+
{'shell': 'git pull', },
30+
{
31+
'guard': {
32+
'layout': 'tiled',
33+
'pre': [
34+
'echo "I get run in each pane."',
35+
'echo "Before each pane command!"'
36+
],
37+
'panes': [
38+
None,
39+
None,
40+
None
41+
]
42+
}
43+
},
44+
{'database': 'bundle exec rails db'},
45+
{'server': 'bundle exec rails s'},
46+
{'logs': 'tail -f log/development.log'},
47+
{'console': 'bundle exec rails c'},
48+
{'capistrano': None},
49+
{'server': 'ssh user@example.com'}
50+
]
51+
}
52+
53+
tmuxp_dict = {
54+
'session_name': 'sample',
55+
'socket_name': 'foo',
56+
'config': '~/.tmux.mac.conf',
57+
'start_directory': '~/test',
58+
'shell_command_before': [
59+
'sudo /etc/rc.d/mysqld start',
60+
'rbenv shell 2.0.0-p247'
61+
],
62+
'windows': [
63+
{
64+
'window_name': 'editor',
65+
'shell_command_before': [
66+
'echo "I get run in each pane, before each pane command!"',
67+
None
68+
],
69+
'layout': 'main-vertical',
70+
'panes': [
71+
'vim',
72+
None,
73+
'top'
74+
]
75+
},
76+
{
77+
'window_name': 'shell',
78+
'panes': [
79+
'git pull'
80+
]
81+
},
82+
{
83+
'window_name': 'guard',
84+
'layout': 'tiled',
85+
'shell_command_before': [
86+
'echo "I get run in each pane."',
87+
'echo "Before each pane command!"'
88+
],
89+
'panes': [
90+
None,
91+
None,
92+
None
93+
]
94+
},
95+
{
96+
'window_name': 'database',
97+
'panes': [
98+
'bundle exec rails db'
99+
]
100+
},
101+
{
102+
'window_name': 'server',
103+
'panes': [
104+
'bundle exec rails s'
105+
]
106+
},
107+
{
108+
'window_name': 'logs',
109+
'panes': [
110+
'tail -f log/development.log'
111+
]
112+
},
113+
{
114+
'window_name': 'console',
115+
'panes': [
116+
'bundle exec rails c'
117+
]
118+
},
119+
{
120+
'window_name': 'capistrano',
121+
'panes': [
122+
None
123+
]
124+
},
125+
{
126+
'window_name': 'server',
127+
'panes': [
128+
'ssh user@example.com'
129+
]
130+
}
131+
]
132+
}
Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
project_name: sample
2+
project_root: ~/test
3+
socket_name: foo # Remove to use default socket
4+
pre: sudo /etc/rc.d/mysqld start # Runs before everything
5+
rbenv: 2.0.0-p247
6+
cli_args: -f ~/.tmux.mac.conf # Pass arguments to tmux
7+
tabs:
8+
- editor:
9+
pre:
10+
- echo "I get run in each pane, before each pane command!"
11+
-
12+
layout: main-vertical
13+
panes:
14+
- vim
15+
- #empty, will just run plain bash
16+
- top
17+
- shell: git pull
18+
- guard:
19+
layout: tiled
20+
pre:
21+
- echo "I get run in each pane."
22+
- echo "Before each pane command!"
23+
panes:
24+
-
25+
- #empty, will just run plain bash
26+
-
27+
- database: bundle exec rails db
28+
- server: bundle exec rails s
29+
- logs: tail -f log/development.log
30+
- console: bundle exec rails c
31+
- capistrano:
32+
- server: ssh user@example.com
Lines changed: 137 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,137 @@
1+
from .._util import loadfixture
2+
3+
4+
tmuxinator_yaml = loadfixture('config_tmuxinator/test3.yaml')
5+
6+
tmuxinator_dict = {
7+
'name': 'sample',
8+
'root': '~/test',
9+
'socket_name': 'foo',
10+
'tmux_options': '-f ~/.tmux.mac.conf',
11+
'pre': 'sudo /etc/rc.d/mysqld start',
12+
'pre_window': 'rbenv shell 2.0.0-p247',
13+
'windows': [
14+
{
15+
'editor': {
16+
'pre': [
17+
'echo "I get run in each pane, '
18+
'before each pane command!"',
19+
None
20+
],
21+
'layout': 'main-vertical',
22+
'panes': [
23+
'vim',
24+
None,
25+
'top'
26+
]
27+
}
28+
},
29+
{
30+
'shell': [
31+
'git pull',
32+
'git merge'
33+
]
34+
},
35+
{
36+
'guard': {
37+
'layout': 'tiled',
38+
'pre': [
39+
'echo "I get run in each pane."',
40+
'echo "Before each pane command!"'
41+
],
42+
'panes': [
43+
None,
44+
None,
45+
None
46+
]
47+
}
48+
},
49+
{'database': 'bundle exec rails db'},
50+
{'server': 'bundle exec rails s'},
51+
{'logs': 'tail -f log/development.log'},
52+
{'console': 'bundle exec rails c'},
53+
{'capistrano': None},
54+
{'server': 'ssh user@example.com'}
55+
]
56+
}
57+
58+
tmuxp_dict = {
59+
'session_name': 'sample',
60+
'socket_name': 'foo',
61+
'config': '~/.tmux.mac.conf',
62+
'shell_command': 'sudo /etc/rc.d/mysqld start',
63+
'shell_command_before': [
64+
'rbenv shell 2.0.0-p247'
65+
],
66+
'windows': [
67+
{
68+
'window_name': 'editor',
69+
'shell_command_before': [
70+
'echo "I get run in each pane, before each pane command!"',
71+
None
72+
],
73+
'layout': 'main-vertical',
74+
'panes': [
75+
'vim',
76+
None,
77+
'top'
78+
]
79+
},
80+
{
81+
'window_name': 'shell',
82+
'panes': [
83+
'git pull',
84+
'git merge'
85+
]
86+
},
87+
{
88+
'window_name': 'guard',
89+
'layout': 'tiled',
90+
'shell_command_before': [
91+
'echo "I get run in each pane."',
92+
'echo "Before each pane command!"'
93+
],
94+
'panes': [
95+
None,
96+
None,
97+
None
98+
]
99+
},
100+
{
101+
'window_name': 'database',
102+
'panes': [
103+
'bundle exec rails db'
104+
]
105+
},
106+
{
107+
'window_name': 'server',
108+
'panes': [
109+
'bundle exec rails s'
110+
]
111+
},
112+
{
113+
'window_name': 'logs',
114+
'panes': [
115+
'tail -f log/development.log'
116+
]
117+
},
118+
{
119+
'window_name': 'console',
120+
'panes': [
121+
'bundle exec rails c'
122+
]
123+
},
124+
{
125+
'window_name': 'capistrano',
126+
'panes': [
127+
None
128+
]
129+
},
130+
{
131+
'window_name': 'server',
132+
'panes': [
133+
'ssh user@example.com'
134+
]
135+
}
136+
]
137+
}

0 commit comments

Comments
 (0)