File tree Expand file tree Collapse file tree 2 files changed +21
-5
lines changed Expand file tree Collapse file tree 2 files changed +21
-5
lines changed Original file line number Diff line number Diff line change @@ -37,7 +37,9 @@ class tmux(object):
37
37
proc = tmux('new-session', '-s%' % 'my session')
38
38
39
39
if proc.stderr:
40
- raise exc.TmuxpException('Command: %s returned error: %s' % (proc.cmd, proc.stderr))
40
+ raise exc.TmuxpException(
41
+ 'Command: %s returned error: %s' % (proc.cmd, proc.stderr)
42
+ )
41
43
42
44
print('tmux command returned %s' % proc.stdout)
43
45
@@ -113,6 +115,7 @@ def __delitem__(self, key):
113
115
self .dirty = True
114
116
115
117
def keys (self ):
118
+ """Return list of keys."""
116
119
return self ._TMUX .keys ()
117
120
118
121
def __iter__ (self ):
@@ -281,7 +284,10 @@ def oh_my_zsh_auto_title():
281
284
if 'SHELL' in os .environ and 'zsh' in os .environ .get ('SHELL' ):
282
285
if os .path .exists (os .path .expanduser ('~/.oh-my-zsh' )):
283
286
# oh-my-zsh exists
284
- if 'DISABLE_AUTO_TITLE' not in os .environ or os .environ .get ('DISABLE_AUTO_TITLE' ) == "false" :
287
+ if (
288
+ 'DISABLE_AUTO_TITLE' not in os .environ or
289
+ os .environ .get ('DISABLE_AUTO_TITLE' ) == "false"
290
+ ):
285
291
print ('Please set:\n \n '
286
292
'\t export DISABLE_AUTO_TITLE = \' true\' \n \n '
287
293
'in ~/.zshrc or where your zsh profile is stored.\n '
Original file line number Diff line number Diff line change @@ -256,7 +256,12 @@ def freeze(session):
256
256
wconf ['layout' ] = w .get ('window_layout' )
257
257
wconf ['panes' ] = []
258
258
259
- if all (w .panes [0 ].get ('pane_current_path' ) == p .get ('pane_current_path' ) for p in w .panes ):
259
+ if (
260
+ all (
261
+ w .panes [0 ].get ('pane_current_path' ) ==
262
+ p .get ('pane_current_path' ) for p in w .panes
263
+ )
264
+ ):
260
265
wconf ['start_directory' ] = w .panes [0 ].get ('pane_current_path' )
261
266
262
267
for p in w .panes :
@@ -270,8 +275,13 @@ def freeze(session):
270
275
271
276
current_cmd = p .get ('pane_current_command' )
272
277
273
- if current_cmd .startswith ('-' ) or \
274
- any (current_cmd .endswith (cmd ) for cmd in ['python' , 'ruby' , 'node' ]):
278
+ if (
279
+ current_cmd .startswith ('-' ) or
280
+ any (
281
+ current_cmd .endswith (cmd )
282
+ for cmd in ['python' , 'ruby' , 'node' ]
283
+ )
284
+ ):
275
285
current_cmd = None
276
286
277
287
if current_cmd :
You can’t perform that action at this time.
0 commit comments