diff options
| author | Aaron1371 <aaron.boyd.org@gmail.com> | 2025-09-28 15:33:00 -0600 |
|---|---|---|
| committer | Cayetano Santos <csantosb@inventati.org> | 2026-01-29 20:13:26 +0100 |
| commit | bc8adbc9b2a49fed423a0ebb7a2e921e8172ccb1 (patch) | |
| tree | 9a2bccd95c70ad29497735406802f4d78a9134fc /gnu/packages/lua.scm | |
| parent | 147767904e828371e17f8a2900150c313491dee0 (diff) | |
gnu: Add fennel-ls.
* gnu/packages/lua.scm (fennel-ls): New variable.
Merges guix/guix!1267
Change-Id: I1f0c494f770a104e866e4dbecb6f19d78cd19366
Signed-off-by: Cayetano Santos <csantosb@inventati.org>
Diffstat (limited to 'gnu/packages/lua.scm')
| -rw-r--r-- | gnu/packages/lua.scm | 65 |
1 files changed, 65 insertions, 0 deletions
diff --git a/gnu/packages/lua.scm b/gnu/packages/lua.scm index 20e091918ff..fe6d09f5dff 100644 --- a/gnu/packages/lua.scm +++ b/gnu/packages/lua.scm @@ -68,6 +68,7 @@ #:use-module (gnu packages gperf) #:use-module (gnu packages gnupg) #:use-module (gnu packages gtk) + #:use-module (gnu packages haskell-xyz) #:use-module (gnu packages libevent) #:use-module (gnu packages libffi) #:use-module (gnu packages linux) @@ -1716,3 +1717,67 @@ This compiler does the opposite of what the Fennel compiler does.") "Fnlfmt is a tool for automatically formatting Fennel code in a consistent way, following established lisp conventions.") (license license:lgpl3+))) + +(define-public fennel-ls + (package + (name "fennel-ls") + (version "0.2.3") + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://git.sr.ht/~xerool/fennel-ls") + (commit version))) + (file-name (git-file-name name version)) + (sha256 + (base32 "1fyyd6yg8xrb572hvk76yi9ga1ysrn6j40phf8ickav3s28i4k85")))) + (build-system gnu-build-system) + (arguments + (list + #:make-flags #~(list "VENDOR=false") + #:tests? #f ; tests require additional dependencies + #:phases + #~(let ((luajit-major+minor + #$(version-major+minor (package-version lua)))) + (modify-phases %standard-phases + (delete 'configure) + (add-before 'build 'rm-vendored-deps + (lambda _ + (delete-file-recursively "fennel") + (delete-file-recursively "deps/"))) + (add-before 'build 'set-lua-path + (lambda _ + (setenv "LUA_PATH" + (string-join + (list + (string-append + #$fennel "/share/lua/" luajit-major+minor "/?.lua") + (string-append + #$dkjson "/share/lua/" luajit-major+minor "/?.lua") + "?.lua") + ";")))) + (replace 'install + (lambda _ + (install-file "fennel-ls" + (string-append #$output "/bin")))) + (add-after 'install 'wrap + (lambda _ + (wrap-program (string-append #$output "/bin/fennel-ls") + `("LUA_PATH" ";" suffix + (,(string-append + #$fennel + "/share/lua/" + luajit-major+minor + "/?.lua") + ,(string-append + #$dkjson + "/share/lua/" + luajit-major+minor + "/?.lua")))))))))) + (inputs (list bash-minimal lua fennel pandoc dkjson)) + (synopsis "Language server for Fennel") + (description + "Fennel Language Server is a language server for the Fennel programming + language.") + (home-page "https://git.sr.ht/~xerool/fennel-ls") + (license license:expat))) |
