Package Details: ltex-ls-bin 16.0.0-3

Git Clone URL: https://aur.archlinux.org/ltex-ls-bin.git (read-only, click to copy)
Package Base: ltex-ls-bin
Description: LTeX Language Server: LSP language server for LanguageTool with support for LaTeX, Markdown, and others
Upstream URL: https://github.com/valentjn/ltex-ls
Keywords: language latex lsp markdown server
Licenses: MPL2
Conflicts: ltex-ls
Provides: ltex-ls
Submitter: pu-007
Maintainer: pu-007 (leejuyuu)
Last Packager: leejuyuu
Votes: 10
Popularity: 0.59
First Submitted: 2022-01-23 12:31 (UTC)
Last Updated: 2023-09-29 15:22 (UTC)

Dependencies (2)

Required by (0)

Sources (1)

Latest Comments

« First ‹ Previous 1 2

leejuyuu commented on 2023-06-29 12:52 (UTC)

@j.mlr Hello, I am currently using ltex-ls-bin 16.0.0, with OpenJDK 20. It works okay with Neovim 0.9.1 and the latest nvim-lspconfig. I would guess that the issue is not related to ltex-ls but to the specific coc-ltex Vim plugin. Have you talked to the plugin developers?

j.mlr commented on 2023-06-23 13:29 (UTC)

It has been suggested that the latest version of ltex-ls (16.0.0) doesn't work with Vim and coc-ltex (https://github.com/valentjn/ltex-ls/issues/243).

On my machine, version 15.2.0 still works.

Not sure if this affects VSCode in any way.

leejuyuu commented on 2023-06-03 16:21 (UTC)

dmitmel: Sorry for the late reply and thanks for the input. I modified the package to limit the Java version to 11. Pacman should install OpenJDK headless 11 by default now.

dmitmel commented on 2023-05-21 11:36 (UTC)

leejuyuu: Honestly I don't remember why I put a dependency on a headless JRE, let alone why I specified precisely OpenJDK, but if it ain't broke...

leejuyuu commented on 2023-05-18 15:21 (UTC) (edited on 2023-05-18 15:22 (UTC) by leejuyuu)

@dmitmel I tried applying your patch, but namcap detects java-runtime dependency. So I modified the PKGBUILD as the following. Let me know whether you find it reasonable. Thanks!

diff --git a/PKGBUILD b/PKGBUILD
index e9db2a7..3f5a6fc 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -8,7 +8,7 @@ pkgdesc="LTeX Language Server: LSP language server for LanguageTool with support
 arch=('any')
 url="https://github.com/valentjn/ltex-ls"
 license=('MPL2')
-depends=('java-runtime-headless-openjdk=11' 'sh')
+depends=('java-runtime>=11' 'bash')
 provides=("${_pkgname}")
 conflicts=("${_pkgname}")
 source=("${url}/releases/download/${pkgver}/${_pkgname}-${pkgver}.tar.gz")
@@ -28,7 +28,7 @@ package() {
         install -Dm755 /dev/null -T "${pkgdir}/${_appdir}/bin/${_bin}"
         cat > "${pkgdir}/${_appdir}/bin/${_bin}" <<EOF
 #!/usr/bin/env sh
-exec /usr/lib/jvm/java-11-openjdk/bin/java \
+exec java \
 -classpath '/usr/share/java/${_pkgname}/*' \
 -Dapp.name='${_pkgname}' \
 -Dapp.pid="\$\$" \

dmitmel commented on 2022-07-17 16:00 (UTC)

zpyg: Hi again, could you please take a look at the patch?

pu-007 commented on 2022-06-21 14:14 (UTC)

@dmitmel Thanks! Howerver, I'm a little bit busy these days, I'll merge it next weekend.

dmitmel commented on 2022-06-21 14:07 (UTC)

Hi, I rewrote the PKGBUILD to not install the bundled JDK and instead use the OpenJDK 11 package from the repositories, also to install simpler scripts into /usr/bin, and fixed some other minor mistakes. Here's the diff:

diff --git a/PKGBUILD b/PKGBUILD
index 2f05ead..e9db2a7 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -1,22 +1,46 @@
 # Maintainer: pu <pu.mb@qq.com>
-pkgname=ltex-ls-bin
+# Contributor: <qzlgeb.zryrfuxb@tznvy.pbz(rot13)>
 _pkgname=ltex-ls
+pkgname="${_pkgname}-bin"
 pkgver=15.2.0
 pkgrel=1
-pkgdesc="LTeX Language Server: LSP language server for LanguageTool magheavy_check_mark with support for LaTeX mortar_board, Markdown memo, and others"
-arch=('x86_64')
-usl="https://github.com/valentjn/ltex-ls"
+pkgdesc="LTeX Language Server: LSP language server for LanguageTool with support for LaTeX, Markdown, and others"
+arch=('any')
+url="https://github.com/valentjn/ltex-ls"
 license=('MPL2')
-provides=('ltex-ls')
-source=("https://github.com/valentjn/ltex-ls/releases/download/15.2.0/ltex-ls-15.2.0-linux-x64.tar.gz")
-md5sums=('6234713566e863420c728e32273ed88c')
+depends=('java-runtime-headless-openjdk=11' 'sh')
+provides=("${_pkgname}")
+conflicts=("${_pkgname}")
+source=("${url}/releases/download/${pkgver}/${_pkgname}-${pkgver}.tar.gz")
+sha256sums=('ca08c216361a3fd2dce412ee3877b9fa5c9a2a97c3862711efcdec924060a3b2')

 package() {
-    install -d "${pkgdir}/opt/${_pkgname}"
-    install -d "${pkgdir}/usr/bin"
+    cd "${srcdir}/${_pkgname}-${pkgver}"

-    cp -r "${srcdir}/${_pkgname}-${pkgver}/"* "${pkgdir}/opt/${_pkgname}/"
+    local _appdir="usr/share/${_pkgname}"
+    install -Dm644 "README.md" "LICENSE.md" "ACKNOWLEDGMENTS.md" "changelog.xml" -t "${pkgdir}/${_appdir}/"
+    install -Dm644 "lib"/*.jar -t "${pkgdir}/usr/share/java/${_pkgname}/"
+    ln -sf "/usr/share/java/${_pkgname}" -T "${pkgdir}/${_appdir}/lib"
+    install -Dm644 "bin/.lsp-cli.json" -t "${pkgdir}/${_appdir}/bin/"

-    ln -sf /opt/${_pkgname}/bin/ltex-ls "${pkgdir}"/usr/bin/ltex-ls
-    ln -sf /opt/${_pkgname}/bin/ltex-cli "${pkgdir}"/usr/bin/ltex-cli
+    _generate_launcher() {
+        local _bin="$1" _class="$2"
+        install -Dm755 /dev/null -T "${pkgdir}/${_appdir}/bin/${_bin}"
+        cat > "${pkgdir}/${_appdir}/bin/${_bin}" <<EOF
+#!/usr/bin/env sh
+exec /usr/lib/jvm/java-11-openjdk/bin/java \
+-classpath '/usr/share/java/${_pkgname}/*' \
+-Dapp.name='${_pkgname}' \
+-Dapp.pid="\$\$" \
+-Dapp.repo='/${_appdir}/lib' \
+-Dapp.home='/${_appdir}' \
+-Dbasedir='/${_appdir}' \
+${_class} "\$@"
+EOF
+        install -d "${pkgdir}/usr/bin/"
+        ln -sf "/${_appdir}/bin/${_bin}" -t "${pkgdir}/usr/bin/"
+    }
+
+    _generate_launcher ltex-ls  org.bsplines.ltexls.LtexLanguageServerLauncher
+    _generate_launcher ltex-cli org.bsplines.lspcli.LspCliLauncher
 }