From 5532d7814b3bd9398229d5ea471c99e19cc2d972 Mon Sep 17 00:00:00 2001 From: edd Date: Sun, 17 Mar 2019 13:15:34 +0000 Subject: [PATCH] Update Python bindings to neovim to 0.3.2. Upstream has renamed the bindings, but for now we keep the old name. OK sthen@, thanks! --- editors/py-neovim/Makefile | 14 +-- editors/py-neovim/distinfo | 4 +- .../py-neovim/patches/patch-test_conftest_py | 14 +-- editors/py-neovim/pkg/PLIST | 112 ++++++++++-------- 4 files changed, 74 insertions(+), 70 deletions(-) diff --git a/editors/py-neovim/Makefile b/editors/py-neovim/Makefile index 0df576f636a..b9396eb4ff6 100644 --- a/editors/py-neovim/Makefile +++ b/editors/py-neovim/Makefile @@ -1,9 +1,10 @@ -# $OpenBSD: Makefile,v 1.3 2018/07/01 14:21:36 edd Exp $ +# $OpenBSD: Makefile,v 1.4 2019/03/17 13:15:34 edd Exp $ COMMENT = Python plugin support for Neovim -MODPY_EGG_VERSION = 0.2.6 -DISTNAME = py-neovim-${MODPY_EGG_VERSION} +MODPY_EGG_VERSION = 0.3.2 +DISTNAME = pynvim-${MODPY_EGG_VERSION} +PKGNAME = py-neovim-${MODPY_EGG_VERSION} CATEGORIES = editors devel HOMEPAGE = https://github.com/neovim/python-client @@ -14,10 +15,7 @@ PERMIT_PACKAGE_CDROM = Yes MODULES = lang/python MODPY_SETUPTOOLS = Yes - -# PyPI filename can clash with the main neovim distfile filename, so we host a -# renamed tarball. -MASTER_SITES = http://theunixzoo.co.uk/distfiles/ +MODPY_PI = Yes FLAVORS = python3 FLAVOR ?= @@ -29,8 +27,6 @@ TEST_DEPENDS = ${RUN_DEPENDS} \ devel/py-test${MODPY_FLAVOR} \ ${BASE_PKGPATH}=${MODPY_EGG_VERSION} -WRKDIST = ${WRKDIR}/neovim-${MODPY_EGG_VERSION} - # You may need to increase the file descriptor ulimits to run tests. do-test: cd ${WRKSRC} && ${LOCALBASE}/bin/py.test${MODPY_BIN_SUFFIX} diff --git a/editors/py-neovim/distinfo b/editors/py-neovim/distinfo index 2222102836b..270aed5930c 100644 --- a/editors/py-neovim/distinfo +++ b/editors/py-neovim/distinfo @@ -1,2 +1,2 @@ -SHA256 (py-neovim-0.2.6.tar.gz) = bOWKdC4EJ0kcDhyBCFVu5yujOEQgm9niJrjalTgpknY= -SIZE (py-neovim-0.2.6.tar.gz) = 36574 +SHA256 (pynvim-0.3.2.tar.gz) = z2SQxOWGydoBoy8+CuIcYTQtfqFx4GAlvaIQvclcvgU= +SIZE (pynvim-0.3.2.tar.gz) = 38164 diff --git a/editors/py-neovim/patches/patch-test_conftest_py b/editors/py-neovim/patches/patch-test_conftest_py index 36eafb303a3..a2b539184a9 100644 --- a/editors/py-neovim/patches/patch-test_conftest_py +++ b/editors/py-neovim/patches/patch-test_conftest_py @@ -1,4 +1,4 @@ -$OpenBSD: patch-test_conftest_py,v 1.1 2018/07/01 14:21:36 edd Exp $ +$OpenBSD: patch-test_conftest_py,v 1.2 2019/03/17 13:15:34 edd Exp $ Although this file is present in the upstream source tree, it was not included when the release tarball was created. This file is needed to @@ -13,15 +13,15 @@ Index: test/conftest.py +import os +import textwrap + -+import neovim ++import pynvim +import pytest + -+neovim.setup_logging("test") ++pynvim.setup_logging("test") + + +@pytest.fixture(autouse=True) +def cleanup_func(vim): -+ fun = textwrap.dedent(''':function BeforeEachTest() ++ fun = textwrap.dedent('''function! BeforeEachTest() + set all& + redir => groups + silent augroup @@ -58,7 +58,7 @@ Index: test/conftest.py + comclear + endfunction + ''') -+ vim.input(fun) ++ vim.command(fun) + vim.command('call BeforeEachTest()') + assert len(vim.tabpages) == len(vim.windows) == len(vim.buffers) == 1 + @@ -71,8 +71,8 @@ Index: test/conftest.py + child_argv = '["nvim", "-u", "NONE", "--embed"]' + + if child_argv is not None: -+ editor = neovim.attach('child', argv=json.loads(child_argv)) ++ editor = pynvim.attach('child', argv=json.loads(child_argv)) + else: -+ editor = neovim.attach('socket', path=listen_address) ++ editor = pynvim.attach('socket', path=listen_address) + + return editor diff --git a/editors/py-neovim/pkg/PLIST b/editors/py-neovim/pkg/PLIST index b99b42a3495..14894d2a31f 100644 --- a/editors/py-neovim/pkg/PLIST +++ b/editors/py-neovim/pkg/PLIST @@ -1,60 +1,68 @@ -@comment $OpenBSD: PLIST,v 1.3 2018/07/01 14:21:36 edd Exp $ +@comment $OpenBSD: PLIST,v 1.4 2019/03/17 13:15:34 edd Exp $ lib/python${MODPY_VERSION}/site-packages/neovim/ -lib/python${MODPY_VERSION}/site-packages/neovim-${MODPY_EGG_VERSION}-py${MODPY_VERSION}.egg-info/ -lib/python${MODPY_VERSION}/site-packages/neovim-${MODPY_EGG_VERSION}-py${MODPY_VERSION}.egg-info/PKG-INFO -lib/python${MODPY_VERSION}/site-packages/neovim-${MODPY_EGG_VERSION}-py${MODPY_VERSION}.egg-info/SOURCES.txt -lib/python${MODPY_VERSION}/site-packages/neovim-${MODPY_EGG_VERSION}-py${MODPY_VERSION}.egg-info/dependency_links.txt -lib/python${MODPY_VERSION}/site-packages/neovim-${MODPY_EGG_VERSION}-py${MODPY_VERSION}.egg-info/not-zip-safe -lib/python${MODPY_VERSION}/site-packages/neovim-${MODPY_EGG_VERSION}-py${MODPY_VERSION}.egg-info/requires.txt -lib/python${MODPY_VERSION}/site-packages/neovim-${MODPY_EGG_VERSION}-py${MODPY_VERSION}.egg-info/top_level.txt lib/python${MODPY_VERSION}/site-packages/neovim/__init__.py ${MODPY_COMMENT}lib/python${MODPY_VERSION}/site-packages/neovim/${MODPY_PYCACHE}/ lib/python${MODPY_VERSION}/site-packages/neovim/${MODPY_PYCACHE}__init__.${MODPY_PYC_MAGIC_TAG}pyc -lib/python${MODPY_VERSION}/site-packages/neovim/${MODPY_PYCACHE}compat.${MODPY_PYC_MAGIC_TAG}pyc -lib/python${MODPY_VERSION}/site-packages/neovim/${MODPY_PYCACHE}util.${MODPY_PYC_MAGIC_TAG}pyc lib/python${MODPY_VERSION}/site-packages/neovim/api/ lib/python${MODPY_VERSION}/site-packages/neovim/api/__init__.py ${MODPY_COMMENT}lib/python${MODPY_VERSION}/site-packages/neovim/api/${MODPY_PYCACHE}/ lib/python${MODPY_VERSION}/site-packages/neovim/api/${MODPY_PYCACHE}__init__.${MODPY_PYC_MAGIC_TAG}pyc -lib/python${MODPY_VERSION}/site-packages/neovim/api/${MODPY_PYCACHE}buffer.${MODPY_PYC_MAGIC_TAG}pyc -lib/python${MODPY_VERSION}/site-packages/neovim/api/${MODPY_PYCACHE}common.${MODPY_PYC_MAGIC_TAG}pyc -lib/python${MODPY_VERSION}/site-packages/neovim/api/${MODPY_PYCACHE}nvim.${MODPY_PYC_MAGIC_TAG}pyc -lib/python${MODPY_VERSION}/site-packages/neovim/api/${MODPY_PYCACHE}tabpage.${MODPY_PYC_MAGIC_TAG}pyc -lib/python${MODPY_VERSION}/site-packages/neovim/api/${MODPY_PYCACHE}window.${MODPY_PYC_MAGIC_TAG}pyc -lib/python${MODPY_VERSION}/site-packages/neovim/api/buffer.py -lib/python${MODPY_VERSION}/site-packages/neovim/api/common.py -lib/python${MODPY_VERSION}/site-packages/neovim/api/nvim.py -lib/python${MODPY_VERSION}/site-packages/neovim/api/tabpage.py -lib/python${MODPY_VERSION}/site-packages/neovim/api/window.py -lib/python${MODPY_VERSION}/site-packages/neovim/compat.py -lib/python${MODPY_VERSION}/site-packages/neovim/msgpack_rpc/ -lib/python${MODPY_VERSION}/site-packages/neovim/msgpack_rpc/__init__.py -${MODPY_COMMENT}lib/python${MODPY_VERSION}/site-packages/neovim/msgpack_rpc/${MODPY_PYCACHE}/ -lib/python${MODPY_VERSION}/site-packages/neovim/msgpack_rpc/${MODPY_PYCACHE}__init__.${MODPY_PYC_MAGIC_TAG}pyc -lib/python${MODPY_VERSION}/site-packages/neovim/msgpack_rpc/${MODPY_PYCACHE}async_session.${MODPY_PYC_MAGIC_TAG}pyc -lib/python${MODPY_VERSION}/site-packages/neovim/msgpack_rpc/${MODPY_PYCACHE}msgpack_stream.${MODPY_PYC_MAGIC_TAG}pyc -lib/python${MODPY_VERSION}/site-packages/neovim/msgpack_rpc/${MODPY_PYCACHE}session.${MODPY_PYC_MAGIC_TAG}pyc -lib/python${MODPY_VERSION}/site-packages/neovim/msgpack_rpc/async_session.py -lib/python${MODPY_VERSION}/site-packages/neovim/msgpack_rpc/event_loop/ -lib/python${MODPY_VERSION}/site-packages/neovim/msgpack_rpc/event_loop/__init__.py -${MODPY_COMMENT}lib/python${MODPY_VERSION}/site-packages/neovim/msgpack_rpc/event_loop/${MODPY_PYCACHE}/ -lib/python${MODPY_VERSION}/site-packages/neovim/msgpack_rpc/event_loop/${MODPY_PYCACHE}__init__.${MODPY_PYC_MAGIC_TAG}pyc -lib/python${MODPY_VERSION}/site-packages/neovim/msgpack_rpc/event_loop/${MODPY_PYCACHE}asyncio.${MODPY_PYC_MAGIC_TAG}pyc -lib/python${MODPY_VERSION}/site-packages/neovim/msgpack_rpc/event_loop/${MODPY_PYCACHE}base.${MODPY_PYC_MAGIC_TAG}pyc -lib/python${MODPY_VERSION}/site-packages/neovim/msgpack_rpc/event_loop/${MODPY_PYCACHE}uv.${MODPY_PYC_MAGIC_TAG}pyc -lib/python${MODPY_VERSION}/site-packages/neovim/msgpack_rpc/event_loop/asyncio.py -lib/python${MODPY_VERSION}/site-packages/neovim/msgpack_rpc/event_loop/base.py -lib/python${MODPY_VERSION}/site-packages/neovim/msgpack_rpc/event_loop/uv.py -lib/python${MODPY_VERSION}/site-packages/neovim/msgpack_rpc/msgpack_stream.py -lib/python${MODPY_VERSION}/site-packages/neovim/msgpack_rpc/session.py -lib/python${MODPY_VERSION}/site-packages/neovim/plugin/ -lib/python${MODPY_VERSION}/site-packages/neovim/plugin/__init__.py -${MODPY_COMMENT}lib/python${MODPY_VERSION}/site-packages/neovim/plugin/${MODPY_PYCACHE}/ -lib/python${MODPY_VERSION}/site-packages/neovim/plugin/${MODPY_PYCACHE}__init__.${MODPY_PYC_MAGIC_TAG}pyc -lib/python${MODPY_VERSION}/site-packages/neovim/plugin/${MODPY_PYCACHE}decorators.${MODPY_PYC_MAGIC_TAG}pyc -lib/python${MODPY_VERSION}/site-packages/neovim/plugin/${MODPY_PYCACHE}host.${MODPY_PYC_MAGIC_TAG}pyc -lib/python${MODPY_VERSION}/site-packages/neovim/plugin/${MODPY_PYCACHE}script_host.${MODPY_PYC_MAGIC_TAG}pyc -lib/python${MODPY_VERSION}/site-packages/neovim/plugin/decorators.py -lib/python${MODPY_VERSION}/site-packages/neovim/plugin/host.py -lib/python${MODPY_VERSION}/site-packages/neovim/plugin/script_host.py -lib/python${MODPY_VERSION}/site-packages/neovim/util.py +lib/python${MODPY_VERSION}/site-packages/pynvim/ +lib/python${MODPY_VERSION}/site-packages/pynvim-${MODPY_EGG_VERSION}-py${MODPY_VERSION}.egg-info/ +lib/python${MODPY_VERSION}/site-packages/pynvim-${MODPY_EGG_VERSION}-py${MODPY_VERSION}.egg-info/PKG-INFO +lib/python${MODPY_VERSION}/site-packages/pynvim-${MODPY_EGG_VERSION}-py${MODPY_VERSION}.egg-info/SOURCES.txt +lib/python${MODPY_VERSION}/site-packages/pynvim-${MODPY_EGG_VERSION}-py${MODPY_VERSION}.egg-info/dependency_links.txt +lib/python${MODPY_VERSION}/site-packages/pynvim-${MODPY_EGG_VERSION}-py${MODPY_VERSION}.egg-info/not-zip-safe +lib/python${MODPY_VERSION}/site-packages/pynvim-${MODPY_EGG_VERSION}-py${MODPY_VERSION}.egg-info/requires.txt +lib/python${MODPY_VERSION}/site-packages/pynvim-${MODPY_EGG_VERSION}-py${MODPY_VERSION}.egg-info/top_level.txt +lib/python${MODPY_VERSION}/site-packages/pynvim/__init__.py +${MODPY_COMMENT}lib/python${MODPY_VERSION}/site-packages/pynvim/${MODPY_PYCACHE}/ +lib/python${MODPY_VERSION}/site-packages/pynvim/${MODPY_PYCACHE}__init__.${MODPY_PYC_MAGIC_TAG}pyc +lib/python${MODPY_VERSION}/site-packages/pynvim/${MODPY_PYCACHE}compat.${MODPY_PYC_MAGIC_TAG}pyc +lib/python${MODPY_VERSION}/site-packages/pynvim/${MODPY_PYCACHE}util.${MODPY_PYC_MAGIC_TAG}pyc +lib/python${MODPY_VERSION}/site-packages/pynvim/api/ +lib/python${MODPY_VERSION}/site-packages/pynvim/api/__init__.py +${MODPY_COMMENT}lib/python${MODPY_VERSION}/site-packages/pynvim/api/${MODPY_PYCACHE}/ +lib/python${MODPY_VERSION}/site-packages/pynvim/api/${MODPY_PYCACHE}__init__.${MODPY_PYC_MAGIC_TAG}pyc +lib/python${MODPY_VERSION}/site-packages/pynvim/api/${MODPY_PYCACHE}buffer.${MODPY_PYC_MAGIC_TAG}pyc +lib/python${MODPY_VERSION}/site-packages/pynvim/api/${MODPY_PYCACHE}common.${MODPY_PYC_MAGIC_TAG}pyc +lib/python${MODPY_VERSION}/site-packages/pynvim/api/${MODPY_PYCACHE}nvim.${MODPY_PYC_MAGIC_TAG}pyc +lib/python${MODPY_VERSION}/site-packages/pynvim/api/${MODPY_PYCACHE}tabpage.${MODPY_PYC_MAGIC_TAG}pyc +lib/python${MODPY_VERSION}/site-packages/pynvim/api/${MODPY_PYCACHE}window.${MODPY_PYC_MAGIC_TAG}pyc +lib/python${MODPY_VERSION}/site-packages/pynvim/api/buffer.py +lib/python${MODPY_VERSION}/site-packages/pynvim/api/common.py +lib/python${MODPY_VERSION}/site-packages/pynvim/api/nvim.py +lib/python${MODPY_VERSION}/site-packages/pynvim/api/tabpage.py +lib/python${MODPY_VERSION}/site-packages/pynvim/api/window.py +lib/python${MODPY_VERSION}/site-packages/pynvim/compat.py +lib/python${MODPY_VERSION}/site-packages/pynvim/msgpack_rpc/ +lib/python${MODPY_VERSION}/site-packages/pynvim/msgpack_rpc/__init__.py +${MODPY_COMMENT}lib/python${MODPY_VERSION}/site-packages/pynvim/msgpack_rpc/${MODPY_PYCACHE}/ +lib/python${MODPY_VERSION}/site-packages/pynvim/msgpack_rpc/${MODPY_PYCACHE}__init__.${MODPY_PYC_MAGIC_TAG}pyc +lib/python${MODPY_VERSION}/site-packages/pynvim/msgpack_rpc/${MODPY_PYCACHE}async_session.${MODPY_PYC_MAGIC_TAG}pyc +lib/python${MODPY_VERSION}/site-packages/pynvim/msgpack_rpc/${MODPY_PYCACHE}msgpack_stream.${MODPY_PYC_MAGIC_TAG}pyc +lib/python${MODPY_VERSION}/site-packages/pynvim/msgpack_rpc/${MODPY_PYCACHE}session.${MODPY_PYC_MAGIC_TAG}pyc +lib/python${MODPY_VERSION}/site-packages/pynvim/msgpack_rpc/async_session.py +lib/python${MODPY_VERSION}/site-packages/pynvim/msgpack_rpc/event_loop/ +lib/python${MODPY_VERSION}/site-packages/pynvim/msgpack_rpc/event_loop/__init__.py +${MODPY_COMMENT}lib/python${MODPY_VERSION}/site-packages/pynvim/msgpack_rpc/event_loop/${MODPY_PYCACHE}/ +lib/python${MODPY_VERSION}/site-packages/pynvim/msgpack_rpc/event_loop/${MODPY_PYCACHE}__init__.${MODPY_PYC_MAGIC_TAG}pyc +lib/python${MODPY_VERSION}/site-packages/pynvim/msgpack_rpc/event_loop/${MODPY_PYCACHE}asyncio.${MODPY_PYC_MAGIC_TAG}pyc +lib/python${MODPY_VERSION}/site-packages/pynvim/msgpack_rpc/event_loop/${MODPY_PYCACHE}base.${MODPY_PYC_MAGIC_TAG}pyc +lib/python${MODPY_VERSION}/site-packages/pynvim/msgpack_rpc/event_loop/${MODPY_PYCACHE}uv.${MODPY_PYC_MAGIC_TAG}pyc +lib/python${MODPY_VERSION}/site-packages/pynvim/msgpack_rpc/event_loop/asyncio.py +lib/python${MODPY_VERSION}/site-packages/pynvim/msgpack_rpc/event_loop/base.py +lib/python${MODPY_VERSION}/site-packages/pynvim/msgpack_rpc/event_loop/uv.py +lib/python${MODPY_VERSION}/site-packages/pynvim/msgpack_rpc/msgpack_stream.py +lib/python${MODPY_VERSION}/site-packages/pynvim/msgpack_rpc/session.py +lib/python${MODPY_VERSION}/site-packages/pynvim/plugin/ +lib/python${MODPY_VERSION}/site-packages/pynvim/plugin/__init__.py +${MODPY_COMMENT}lib/python${MODPY_VERSION}/site-packages/pynvim/plugin/${MODPY_PYCACHE}/ +lib/python${MODPY_VERSION}/site-packages/pynvim/plugin/${MODPY_PYCACHE}__init__.${MODPY_PYC_MAGIC_TAG}pyc +lib/python${MODPY_VERSION}/site-packages/pynvim/plugin/${MODPY_PYCACHE}decorators.${MODPY_PYC_MAGIC_TAG}pyc +lib/python${MODPY_VERSION}/site-packages/pynvim/plugin/${MODPY_PYCACHE}host.${MODPY_PYC_MAGIC_TAG}pyc +lib/python${MODPY_VERSION}/site-packages/pynvim/plugin/${MODPY_PYCACHE}script_host.${MODPY_PYC_MAGIC_TAG}pyc +lib/python${MODPY_VERSION}/site-packages/pynvim/plugin/decorators.py +lib/python${MODPY_VERSION}/site-packages/pynvim/plugin/host.py +lib/python${MODPY_VERSION}/site-packages/pynvim/plugin/script_host.py +lib/python${MODPY_VERSION}/site-packages/pynvim/util.py