diff options
-rw-r--r-- | .SRCINFO | 41 | ||||
-rw-r--r-- | .gitignore | 5 | ||||
-rw-r--r-- | PKGBUILD | 177 | ||||
-rw-r--r-- | neovim.install | 15 | ||||
-rw-r--r-- | nvimdoc | 5 | ||||
-rw-r--r-- | nvimdoc.hook | 11 |
6 files changed, 118 insertions, 136 deletions
@@ -1,40 +1,43 @@ pkgbase = neovim-nightly - pkgdesc = hyperextensible Vim-based text editor - pkgver = 0.10.0.dev.20230525 - pkgrel = 3 - url = https://github.com/neovim/neovim/releases/tag/nightly + pkgdesc = Fork of Vim aiming to improve user experience, plugins, and GUIs + pkgver = 0.10.0.r2250.g6bba4beced + pkgrel = 1 + url = https://neovim.io arch = i686 arch = x86_64 arch = armv7h arch = armv6h arch = aarch64 - arch = pentium4 license = custom:neovim makedepends = cmake - makedepends = gperf + makedepends = git makedepends = ninja - makedepends = patchelf + makedepends = unzip depends = libluv depends = libtermkey depends = libuv - depends = libvterm + depends = libvterm>0.1.4 depends = luajit depends = msgpack-c - depends = tree-sitter + depends = tree-sitter-git depends = unibilium depends = lua51-lpeg - depends = lua51-mpack - optdepends = python2-neovim: Python 2 provider - optdepends = python-pynvim: Python 3 provider - optdepends = ruby-neovim: Ruby provider - optdepends = xclip: X11 clipboard integration - optdepends = xsel: X11 clipboard integration - optdepends = wl-clipboard: wayland clipboard integration - provides = neovim=0.10.0.dev.20230705.gb2e8c0d + optdepends = python-pynvim: for Python plugin support (see :help python) + optdepends = xclip: for clipboard support on X11 (or xsel) (see :help clipboard) + optdepends = xsel: for clipboard support on X11 (or xclip) (see :help clipboard) + optdepends = wl-clipboard: for clipboard support on wayland (see :help clipboard) + provides = neovim=0.10.0 provides = vim-plugin-runtime conflicts = neovim backup = etc/xdg/nvim/sysinit.vim - source = neovim-nightly-0.10.0.dev.20230705.gb2e8c0d::https://github.com/neovim/neovim/archive/refs/tags/nightly.tar.gz - sha256sums = SKIP + source = git+https://github.com/neovim/neovim.git#tag=nightly + source = nvimdoc + source = nvimdoc.hook + sha512sums = SKIP + sha512sums = 22662462c823de243599cdd3483e46ade4ab59b219e907468d34c18e584fe7477548e357ee2ce56bb098cf54b770b108a3511703dd486f0774a65c84af78f6aa + sha512sums = 3c6ee1e4646d09c164a2212f9e4d2f53158ff32911b0972e060a395a8d4685334574a7ede995a81680dcc0750cd3327a78beb7904a4bb326b2399d79a8b12d5e + b2sums = SKIP + b2sums = d31cf81659e238fada8092755eb9be16f77c00a466107eb5770c6c9c32e043c91e6efada7ddb51663716a0e38ffa6e3d0093b3e6833aa961d845c7451a95491e + b2sums = 26588b9da6459393076723bdfb8d2b16fed882070f2326bf7c35cd272dee9c18df603afb1ae2254cd0a59eff68189caf04828ef165d5de42c7a4222267604101 pkgname = neovim-nightly diff --git a/.gitignore b/.gitignore deleted file mode 100644 index 7ce21c5289ab..000000000000 --- a/.gitignore +++ /dev/null @@ -1,5 +0,0 @@ -*.pkg* -*.tar* -updater.sh -latest_release -latest_version
\ No newline at end of file @@ -1,111 +1,94 @@ -# Maintainer: iamawacko <iamawacko@protonmail.com> -# Contributor: Francesco La Camera <fm@lacamera.org> -pkgname=neovim-nightly -pkgver=0.10.0.dev.20230525 -pkgrel=3 -pkgdesc='hyperextensible Vim-based text editor' -arch=('i686' 'x86_64' 'armv7h' 'armv6h' 'aarch64' 'pentium4') -url='https://github.com/neovim/neovim/releases/tag/nightly' +# Maintainer: A Farzat <a@farzat.xyz> +# Contributor: éclairevoyant +# Contributor: Sven-Hendrik Haase <svenstaro@archlinux.org> +# Contributor: Caleb Maclennan <caleb@alerque.com> +# Contributor: Florian Walch <florian+aur@fwalch.com> +# Contributor: Florian Hahn <flo@fhahn.com> + +_pkgname=neovim +pkgname="$_pkgname-nightly" +pkgver=0.10.0.r2250.g6bba4beced +pkgrel=1 +pkgdesc='Fork of Vim aiming to improve user experience, plugins, and GUIs' +arch=(i686 x86_64 armv7h armv6h aarch64) +url='https://neovim.io' backup=('etc/xdg/nvim/sysinit.vim') license=('custom:neovim') -depends=('libluv' 'libtermkey' 'libuv' 'libvterm' 'luajit' 'msgpack-c' 'tree-sitter' 'unibilium' 'lua51-lpeg' 'lua51-mpack') -makedepends=('cmake' 'gperf' 'ninja' 'patchelf') -optdepends=('python2-neovim: Python 2 provider' - 'python-pynvim: Python 3 provider' - 'ruby-neovim: Ruby provider' - 'xclip: X11 clipboard integration' - 'xsel: X11 clipboard integration' - 'wl-clipboard: wayland clipboard integration') - -# get latest version -_neovim_version() { - if [ -e "$srcdir/neovim-nightly/CMakeLists.txt" ] ; then - _regex_vmaj='^set\(NVIM_VERSION_MAJOR ([0-9]+)\)$' - _regex_vmin='^set\(NVIM_VERSION_MINOR ([0-9]+)\)$' - _regex_vpat='^set\(NVIM_VERSION_PATCH ([0-9]+)\)$' - - _neovim_version_major=$( - grep -E "$_regex_vmaj" "$srcdir/neovim-nightly/CMakeLists.txt" \ - | sed -E "s@$_regex_vmaj@\1@" - ) - _neovim_version_minor=$( - grep -E "$_regex_vmin" "$srcdir/neovim-nightly/CMakeLists.txt" \ - | sed -E "s@$_regex_vmin@\1@" - ) - _neovim_version_patch=$( - grep -E "$_regex_vpat" "$srcdir/neovim-nightly/CMakeLists.txt" \ - | sed -E "s@$_regex_vpat@\1@" - ) - else - _neovim_version_major=0 - _neovim_version_minor=10 - _neovim_version_patch=0 - fi - - printf "%s.%s.%s" \ - "$_neovim_version_major" \ - "$_neovim_version_minor" \ - "$_neovim_version_patch" -} - -_pkgver() { - _response=$( - curl 'https://api.github.com/repos/neovim/neovim/releases?per_page=1&page=1' -s \ - | grep -E -A 6 '^\s+"tag_name": "nightly".*$' - ) - - _regex_date='^\s+"created_at": "([0-9]+-[0-9]+-[0-9]+)T.*".*$' - _date=$( - echo "$_response" \ - | grep -E "$_regex_date" \ - | sed -E "s@$_regex_date@\1@; s@-@@g" - ) - - _regex_commit='^\s+"target_commitish": "([^"]+)".*$' - _commit=$( - echo "$_response" \ - | grep -E "$_regex_commit" \ - | sed -E "s@$_regex_commit@\1@" - ) - - _neovim_version=$(_neovim_version) - - printf '%s.dev.%s.g%s' \ - "$_neovim_version" \ - "$_date" \ - "${_commit:0:7}" -} -_pkgver=$(_pkgver) -source=("$pkgname-$_pkgver::https://github.com/neovim/neovim/archive/refs/tags/nightly.tar.gz") -provides=("neovim=$_pkgver" 'vim-plugin-runtime') -conflicts=('neovim') -sha256sums=('SKIP') +depends=( + 'libluv' + 'libtermkey' + 'libuv' + 'libvterm>0.1.4' + 'luajit' + 'msgpack-c' + 'tree-sitter-git' + 'unibilium' + 'lua51-lpeg' +) +makedepends=('cmake' 'git' 'ninja' 'unzip') +optdepends=( + 'python-pynvim: for Python plugin support (see :help python)' + 'xclip: for clipboard support on X11 (or xsel) (see :help clipboard)' + 'xsel: for clipboard support on X11 (or xclip) (see :help clipboard)' + 'wl-clipboard: for clipboard support on wayland (see :help clipboard)' +) +provides=("$_pkgname=${pkgver/\.r*/}" 'vim-plugin-runtime') +conflicts=("$_pkgname") +source=( + "git+https://github.com/neovim/$_pkgname.git#tag=nightly" + nvimdoc{,.hook} +) +sha512sums=('SKIP' + '22662462c823de243599cdd3483e46ade4ab59b219e907468d34c18e584fe7477548e357ee2ce56bb098cf54b770b108a3511703dd486f0774a65c84af78f6aa' + '3c6ee1e4646d09c164a2212f9e4d2f53158ff32911b0972e060a395a8d4685334574a7ede995a81680dcc0750cd3327a78beb7904a4bb326b2399d79a8b12d5e') +b2sums=('SKIP' + 'd31cf81659e238fada8092755eb9be16f77c00a466107eb5770c6c9c32e043c91e6efada7ddb51663716a0e38ffa6e3d0093b3e6833aa961d845c7451a95491e' + '26588b9da6459393076723bdfb8d2b16fed882070f2326bf7c35cd272dee9c18df603afb1ae2254cd0a59eff68189caf04828ef165d5de42c7a4222267604101') pkgver() { - printf "$_pkgver" + cd "$_pkgname" + local nvim_version nvim_version_git + nvim_version="$(sed -nE '/NVIM_VERSION_/ s/.* +([0-9]+)\).*/\1/p' ./CMakeLists.txt | sed ':b;N;$!bb;s/\n/\./g')" + nvim_version_git="$(git describe --first-parent --always | sed -E 's/^v[0-9]+.[0-9]+.[0-9]+-//; s/^([0-9]+)-([a-z0-9]+)/\1\.\2/')" + printf "%s.r%s\n" "$nvim_version" "$nvim_version_git" } build() { - cmake -Sneovim-nightly -Bbuild \ - -DCMAKE_BUILD_TYPE=RelWithDebInfo \ - -DCMAKE_INSTALL_PREFIX=/usr - cmake --build build + cd "$_pkgname" + cmake \ + -Bbuild \ + -DCMAKE_BUILD_TYPE=RelWithDebInfo \ + -DCMAKE_INSTALL_PREFIX=/usr \ + -DUSE_BUNDLED=OFF \ + -W no-dev + cmake --build build --verbose } check() { - cd "$srcdir/build" - ./bin/nvim --headless -u NONE -i NONE -c ':quit' + cd "$_pkgname" + ./build/bin/nvim --version + ./build/bin/nvim --headless -u NONE -i NONE +q } package() { - cd "$srcdir/build" - DESTDIR="$pkgdir" cmake --build . --target install - cd "$srcdir/neovim-nightly" - install -Dm644 LICENSE.txt "$pkgdir/usr/share/licenses/$pkgname/LICENSE.txt" - install -Dm644 runtime/nvim.desktop "$pkgdir/usr/share/applications/nvim.desktop" - install -Dm644 runtime/nvim.png "$pkgdir/usr/share/pixmaps/nvim.png" - mkdir -p "$pkgdir/etc/xdg/nvim" - mkdir -p "$pkgdir/usr/share/nvim" - echo "source /usr/share/nvim/archlinux.vim" >> "$pkgdir"/etc/xdg/nvim/sysinit.vim - echo "set runtimepath+=/usr/share/vim/vimfiles" > "$pkgdir"/usr/share/nvim/archlinux.vim + install -Dm644 -t "$pkgdir/usr/share/libalpm/hooks/" nvimdoc.hook + install -Dt "$pkgdir/usr/share/libalpm/scripts/" nvimdoc + + cd "$_pkgname" + DESTDIR="$pkgdir" cmake --install build + + install -Dm644 LICENSE.txt -t "${pkgdir}/usr/share/licenses/${pkgname}/" + install -Dm644 runtime/nvim.desktop -t "${pkgdir}/usr/share/applications/" + install -Dm644 runtime/nvim.appdata.xml -t "${pkgdir}/usr/share/metainfo/" + install -Dm644 runtime/nvim.png -t "${pkgdir}/usr/share/pixmaps/" + + # Make Arch Vim packages work + mkdir -p "${pkgdir}"/etc/xdg/nvim + echo "\" This line makes pacman-installed global Arch Linux vim packages work." > "${pkgdir}"/etc/xdg/nvim/sysinit.vim + echo "source /usr/share/nvim/archlinux.vim" >> "${pkgdir}"/etc/xdg/nvim/sysinit.vim + + mkdir -p "${pkgdir}"/usr/share/vim + echo "set runtimepath+=/usr/share/vim/vimfiles" > "${pkgdir}"/usr/share/nvim/archlinux.vim } + +# vim:set sw=2 sts=2 et: diff --git a/neovim.install b/neovim.install deleted file mode 100644 index 7d7f32f98325..000000000000 --- a/neovim.install +++ /dev/null @@ -1,15 +0,0 @@ -# $1: new package version -post_install() { - echo ":: The Neovim executable is called 'nvim'." - echo ":: If you are already familiar with Vim, see ':help nvim-from-vim'" - echo " to get started." -} - -post_upgrade() { - echo ":: If you have any questions, check the following page first:" - echo " https://github.com/neovim/neovim/wiki/FAQ" - echo ":: Remember this a pre-release build, see 'Following HEAD' for more info" - echo " https://github.com/neovim/neovim/wiki/Following-HEAD" -} - -# vim:set sw=2 sts=2 et: diff --git a/nvimdoc b/nvimdoc new file mode 100644 index 000000000000..821826f24b30 --- /dev/null +++ b/nvimdoc @@ -0,0 +1,5 @@ +#!/bin/bash + +for f in /usr/share/nvim/site/pack/dist/start/*/doc/; do + /usr/bin/nvim -es "+helptags $f" +q +done diff --git a/nvimdoc.hook b/nvimdoc.hook new file mode 100644 index 000000000000..558907c81ac6 --- /dev/null +++ b/nvimdoc.hook @@ -0,0 +1,11 @@ +[Trigger] +Operation = Install +Operation = Upgrade +Operation = Remove +Type = Path +Target = usr/share/nvim/site/pack/dist/start/*/doc/ + +[Action] +Description = Updating Neovim help tags... +Exec = /usr/share/libalpm/scripts/nvimdoc +When = PostTransaction |