diff --git a/.travis.yml b/.travis.yml index 08e9a4b55e..77f2e11968 100644 --- a/.travis.yml +++ b/.travis.yml @@ -2,7 +2,6 @@ language: python sudo: false python: - - 2.6 - 2.7 - 3.3 - 3.4 diff --git a/README.rst b/README.rst index fe33926a1c..93ca5f8715 100644 --- a/README.rst +++ b/README.rst @@ -137,8 +137,8 @@ Project details --------------- ============== ========================================================== -tmux support 1.8, 1.9a, 2.0, 2.1, 2.2, 2.3 -python support 2.6, 2.7, >= 3.3, pypy, pypy3 +tmux support 1.8, 1.9a, 2.0, 2.1, 2.2, 2.3, 2.4 +python support 2.7, >= 3.3, pypy, pypy3 config support yaml, json, python dict Source https://github.com/tony/tmuxp Docs http://tmuxp.git-pull.com diff --git a/requirements/base.txt b/requirements/base.txt index 39c85b8836..daea08343e 100644 --- a/requirements/base.txt +++ b/requirements/base.txt @@ -1,4 +1,4 @@ kaptan>=0.5.7 -libtmux==0.6.5 # Updated from 0.6.4 +libtmux==0.7.1 # Updated from 0.6.5 click==6.7 colorama==0.3.9 diff --git a/setup.py b/setup.py index d8c8ad6ddf..bfaf71dd57 100644 --- a/setup.py +++ b/setup.py @@ -61,7 +61,6 @@ def run_tests(self): 'Environment :: Web Environment', 'Intended Audience :: Developers', 'Programming Language :: Python', - 'Programming Language :: Python :: 2.6', 'Programming Language :: Python :: 2.7', 'Programming Language :: Python :: 3.3', 'Programming Language :: Python :: 3.4', diff --git a/tests/test_workspacebuilder.py b/tests/test_workspacebuilder.py index ea8adfa321..a8e958614c 100644 --- a/tests/test_workspacebuilder.py +++ b/tests/test_workspacebuilder.py @@ -12,6 +12,7 @@ from . import fixtures_dir from libtmux import Window +from libtmux.common import has_gte_version from libtmux.test import temp_session from tmuxp import config, exc from tmuxp._compat import text_type @@ -242,6 +243,9 @@ def test_window_options(session): sconfig = sconfig.import_config(yaml_config).get() sconfig = config.expand(sconfig) + if has_gte_version('2.3'): + sconfig['windows'][0]['options']['pane-border-format'] = ' #P ' + builder = WorkspaceBuilder(sconf=sconfig) window_count = len(session._windows) # current window count @@ -253,6 +257,8 @@ def test_window_options(session): assert len(s._windows) == window_count assert isinstance(w, Window) assert w.show_window_option('main-pane-height') == 5 + if has_gte_version('2.3'): + assert w.show_window_option('pane-border-format') == ' #P ' assert len(s._windows) == window_count window_count += 1 @@ -262,7 +268,6 @@ def test_window_options(session): @pytest.mark.flaky(reruns=5) def test_window_options_after(session): yaml_config = loadfixture("workspacebuilder/window_options_after.yaml") - s = session sconfig = kaptan.Kaptan(handler='yaml') sconfig = sconfig.import_config(yaml_config).get() sconfig = config.expand(sconfig) @@ -274,8 +279,8 @@ def assert_last_line(p, s): correct = False for _ in range(10): pane_out = p.cmd('capture-pane', '-p', '-J').stdout - # delete trailing empty lines for tmux 1.8... - while not pane_out[-1].strip(): pane_out.pop() + while not pane_out[-1].strip(): # delete trailing lines tmux 1.8 + pane_out.pop() if len(pane_out) > 1 and pane_out[-2].strip() == s: correct = True break @@ -291,10 +296,11 @@ def assert_last_line(p, s): for i, pane in enumerate(session.attached_window.panes): assert assert_last_line(pane, str(i)), \ "Initial command did not execute properly/" + str(i) - pane.cmd('send-keys', 'Up') # Will repeat echo - pane.enter() # in each iteration - assert assert_last_line(pane, str(i)), \ - "Repeated command did not execute properly/" + str(i) + pane.cmd('send-keys', 'Up') # Will repeat echo + pane.enter() # in each iteration + assert assert_last_line(pane, str(i)), ( + "Repeated command did not execute properly/" + str(i) + ) session.cmd('send-keys', ' echo moo') session.cmd('send-keys', 'Enter') diff --git a/tmuxp/cli.py b/tmuxp/cli.py index 70296a7f67..7159b350a2 100644 --- a/tmuxp/cli.py +++ b/tmuxp/cli.py @@ -14,7 +14,7 @@ import click import kaptan from click.exceptions import FileError -from libtmux.common import has_required_tmux_version, which +from libtmux.common import has_minimum_version, which from libtmux.exc import TmuxCommandNotFound from libtmux.server import Server @@ -318,7 +318,7 @@ def cli(log_level): See detailed documentation and examples at: http://tmuxp.readthedocs.io/en/latest/""" try: - has_required_tmux_version() + has_minimum_version() except TmuxCommandNotFound: click.echo('tmux not found. tmuxp requires you install tmux first.') sys.exit() diff --git a/tox.ini b/tox.ini index c3102c4c0c..cf419f3250 100644 --- a/tox.ini +++ b/tox.ini @@ -1,5 +1,5 @@ [tox] -envlist = py26, py27, py33, py34, py35 +envlist = py27, py33, py34, py35, py36 [testenv] commands = make test []