Package Details: languagetool-snapshot 6.9.20261010-1

Git Clone URL: https://aur.archlinux.org/languagetool-snapshot.git (read-only, click to copy)
Package Base: languagetool-snapshot
Description: Grammar and style checker (daily snapshot)
Upstream URL: https://github.com/languagetool-org/languagetool
Licenses: LGPL-2.1-or-later
Conflicts: languagetool
Provides: languagetool
Submitter: None
Maintainer: RubenKelevra
Last Packager: RubenKelevra
Votes: 1
Popularity: 0.74
First Submitted: 2023-08-28 02:56 (UTC)
Last Updated: 2026-10-10 17:09 (UTC)

Dependencies (5)

Required by (17)

Sources (3)

Latest Comments

RubenKelevra commented on 2026-09-25 00:39 (UTC) (edited on 2026-09-25 00:40 (UTC) by RubenKelevra)

@MaximGun no longer needed, the package is now updating on its own.

MaximGun commented on 2025-10-29 13:08 (UTC)

For anyone interested, I updated the PKGBUILD to automatically download the latest available snapshot from Languagetool's servers:

pkgname=languagetool-snapshot
_pkgname="${pkgname%-snapshot}"
pkgver=6.8.20251028  # will be set by pkgver()
pkgrel=1
pkgdesc='Style and Grammar Checker for 25+ Languages (daily snapshot)'
arch=(any)
url='https://www.languagetool.org'
license=(LGPL)
depends=(java-runtime-headless)
optdepends=('java-runtime: needed for the GUI version'
            'libxtst: needed for the GUI version'
            'gtk3: GTK style for the GUI')
provides=("$_pkgname")
conflicts=("$_pkgname")

# Find the latest snapshot file and set it as a source
_snapshot_url_base="https://internal1.languagetool.org/snapshots"
_snapshot_file=$(curl -s "$_snapshot_url_base/" | grep -oP 'LanguageTool-\d{8}-snapshot\.zip' | sort -r | head -n1)
_date=$(echo "$_snapshot_file" | grep -oP '\d{8}')

source=("${_snapshot_url_base}/${_snapshot_file}"
        'languagetool.service'
        'languagetool.sh')
sha256sums=('SKIP'
            '628e59208af02dd41c678135ef6dd8b328905701301d8257316b388d36d6c52b'
            'e395fe51eb107365bb6e5456a2e1a144a60296e52554b8407f241e195e434359')
noextract=("$_snapshot_file")

# helper: extract the top-level directory name from the archive (e.g., LanguageTool-6.8-SNAPSHOT)
_get_topdir() {
bsdtar -tf "$_snapshot_file" \
    | awk -F/ '/^LanguageTool-.*-SNAPSHOT\/$/ {print $1; exit}'
}

pkgver() {
local topdir rev
topdir=$(_get_topdir)
# topdir is like "LanguageTool-6.8-SNAPSHOT"
rev=${topdir#LanguageTool-}
rev=${rev%-SNAPSHOT}
printf '%s.%s\n' "$rev" "$_date"
}

package() {
install -d "$pkgdir/usr/share/java/$_pkgname"

# Extract the snapshot
bsdtar -xpf "$_snapshot_file" -C "$srcdir"

# Discover the directory name dynamically
local topdir
topdir=$(_get_topdir)

# Install the whole tree to /usr/share/languagetool
mv "$srcdir/$topdir" "$pkgdir/usr/share/$_pkgname"

# Wrapper + service
install -D -m755 "$_pkgname.sh" "$pkgdir/usr/bin/$_pkgname"
install -D -m644 "$_pkgname.service" "$pkgdir/usr/lib/systemd/system/$_pkgname.service"

# Move jars/libs under /usr/share/java/languagetool
cd "$pkgdir/usr/share/$_pkgname"
mv languagetool{,-server,-commandline}.jar libs/ "$pkgdir/usr/share/java/$_pkgname"
}