summaryrefslogtreecommitdiff
path: root/crn
diff options
context:
space:
mode:
Diffstat (limited to 'crn')
-rw-r--r--crn/packages.scm48
-rw-r--r--crn/packages/cmake-language-server.scm74
-rw-r--r--crn/packages/lua-xyz.scm94
-rw-r--r--crn/packages/patches/typeguard-version.patch9
-rw-r--r--crn/packages/python-xyz.scm123
5 files changed, 348 insertions, 0 deletions
diff --git a/crn/packages.scm b/crn/packages.scm
new file mode 100644
index 0000000..2d869c9
--- /dev/null
+++ b/crn/packages.scm
@@ -0,0 +1,48 @@
+;;; GNU Guix --- Functional package management for GNU
+;;; Copyright © 2020 Andrew Whatson <whatson@gmail.com>
+;;;
+;;; This file is NOT part of GNU Guix.
+;;;
+;;; This program is free software: you can redistribute it and/or modify
+;;; it under the terms of the GNU General Public License as published by
+;;; the Free Software Foundation, either version 3 of the License, or
+;;; (at your option) any later version.
+;;;
+;;; This program is distributed in the hope that it will be useful,
+;;; but WITHOUT ANY WARRANTY; without even the implied warranty of
+;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+;;; GNU General Public License for more details.
+;;;
+;;; You should have received a copy of the GNU General Public License
+;;; along with this program. If not, see <http://www.gnu.org/licenses/>.
+
+(define-module (crn packages)
+ #:use-module ((gnu packages) #:prefix gnu:)
+ #:use-module (guix diagnostics)
+ #:use-module (guix i18n)
+ #:use-module (srfi srfi-1)
+ #:export (search-patch
+ search-patches
+ %patch-path))
+
+(define (search-patch file-name)
+ "Search the patch FILE-NAME. Raise an error if not found."
+ (or (search-path (%patch-path) file-name)
+ (raise (formatted-message (G_ "~a: patch not found")
+ file-name))))
+
+(define-syntax-rule (search-patches file-name ...)
+ "Return the list of absolute file names corresponding to each
+FILE-NAME found in %PATCH-PATH."
+ (list (search-patch file-name) ...))
+
+(define %channel-root
+ (find (lambda (path)
+ (file-exists? (string-append path "/crn/packages.scm")))
+ %load-path))
+
+(define %patch-path
+ (make-parameter
+ (cons
+ (string-append %channel-root "/crn/packages/patches")
+ (gnu:%patch-path))))
diff --git a/crn/packages/cmake-language-server.scm b/crn/packages/cmake-language-server.scm
new file mode 100644
index 0000000..a7d644f
--- /dev/null
+++ b/crn/packages/cmake-language-server.scm
@@ -0,0 +1,74 @@
+(define-module (crn packages cmake-language-server))
+(use-modules (guix build utils)
+ (guix download)
+ (guix git-download)
+ (guix packages)
+ (guix licenses)
+ (guix gexp)
+ (guix build-system python)
+ (guix build-system pyproject)
+ (gnu packages python-check)
+ (gnu packages python-crypto)
+ (gnu packages python-build)
+ (gnu packages check)
+ (crn packages)
+ ((crn packages python-xyz) #:prefix crn-python:)
+ (gnu packages python-web)
+ (gnu packages python-xyz)
+ ((gnu packages) #:prefix gnu:))
+
+(define-public python-pdm-pep517
+ (package
+ (name "python-pdm-pep517")
+ (version "1.1.3")
+ (source (origin
+ (method url-fetch)
+ (uri (pypi-uri "pdm-pep517" version))
+ (sha256
+ (base32
+ "00sxd3bfwqbl9rqcn9shgbsaq6jkj75s47fjdq9bsm4ylkl7f4bn"))))
+ (build-system pyproject-build-system)
+ (home-page "")
+ (synopsis "A PEP 517 backend for PDM that supports PEP 621 metadata")
+ (description
+ "This package provides a PEP 517 backend for PDM that supports PEP 621 metadata")
+ (license expat)
+ (arguments (list
+ #:phases
+ #~(modify-phases %standard-phases
+ (delete 'check))))))
+
+(define-public cmake-language-server
+ (package
+ (name "cmake-language-server")
+ (version "0.1.7")
+ (source
+ (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/regen100/cmake-language-server")
+ (commit "v0.1.7")))
+ (sha256
+ (base32
+ "1ip6savjyhwizwxqx70ifmznn0j754n19xw4g84i3iz1is5h048k"))))
+ (build-system pyproject-build-system)
+ (native-inputs (list python-pdm-pep517
+ python-pytest
+ python-pytest-datadir
+ python-pytest-cov
+ python-mypy
+ python-flake8
+ python-black
+ python-isort
+ crn-python:python-typeguard))
+ (propagated-inputs (list crn-python:python-attrs
+ crn-python:python-gls
+ crn-python:python-lsprotocol))
+ (home-page "https://github.com/regen100/cmake-language-server")
+ (synopsis "An automated code formatter for Erlang.")
+ (description "erlfmt is an opinionated Erlang code formatter. By automating the process of formatting the code, it frees your team up to focus on what the code does, instead of what it looks like.")
+ (license asl2.0)
+ (arguments
+ (list #:phases
+ #~(modify-phases %standard-phases
+ (delete 'check))))))
diff --git a/crn/packages/lua-xyz.scm b/crn/packages/lua-xyz.scm
new file mode 100644
index 0000000..9d5b2a3
--- /dev/null
+++ b/crn/packages/lua-xyz.scm
@@ -0,0 +1,94 @@
+(define-module (crn packages lua-xyz))
+(use-modules (guix git)
+ (guix git-download)
+ (guix gexp)
+ (guix download)
+ (guix packages)
+ (guix licenses)
+ (guix build-system copy)
+ (guix build-system cmake)
+ (guix utils)
+ (gnu packages)
+ (gnu packages lua))
+
+(define-public luastatus
+(package
+ (name "luastatus")
+ (version "0.6.0")
+ (source (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/shdown/luastatus")
+ (commit "8d01bdf")))
+ (sha256
+ (base32 "0bwmdwqwsvr4jalcm4hpdwy1wsrbrl414ig69lwai9h2ran6ni3h"))))
+ (build-system cmake-build-system)
+ (native-inputs (specifications->packages (list "lua" "pkg-config")))
+ (inputs (specifications->packages
+ (list "alsa-lib"
+ "xcb-util"
+ "yajl"
+ "glib"
+ "libnl"
+ "eudev"
+ "libx11"
+ "libxcb"
+ "xcb-util-wm"
+ "python-docutils")))
+ (home-page "https://github.com/shdown/luastatus")
+ (synopsis "luastatus is a universal status bar content generator.")
+ (description "luastatus is a universal status bar content generator. It allows you to configure the way the data from event sources is processed and shown, with Lua.")
+ (license gpl3)
+ (arguments
+ (list #:phases
+ #~(modify-phases %standard-phases
+ (delete 'check))))))
+
+(define-public digestif
+ (package
+ (name "digestif")
+ (version "0.5.1")
+ (source (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/astoff/digestif")
+ (commit "v0.5.1")))
+ (sha256
+ (base32 "1jb8h7yks8bp74jpq85sz69d2k69vhp6gliajz8ximl3hbhdq17i"))))
+ (build-system copy-build-system)
+ (inputs (specifications->packages
+ (list "lua@5.3.5"
+ "lua-filesystem"
+ "lua-lpeg")))
+ (home-page "https://github.com/astoff/digestif")
+ (synopsis "A language server for TeX and friends")
+ (description "Digestif is a code analyzer, and a language server, for LaTeX, ConTeXt et caterva. It provides context-sensitive completion, documentation, code navigation, and related functionality to any text editor that speaks the LSP protocol.")
+ (license gpl3)
+ (arguments
+ `(
+ #:install-plan
+ `(("bin/digestif" "bin/")
+ ("digestif/" ,(string-append "share/lua/" ,(version-major+minor (package-version lua)) "/digestif"))
+ ("data/" "share/digestif"))
+ #:phases
+ (modify-phases %standard-phases
+ (add-after 'install 'wrap
+ (lambda* (#:key inputs outputs #:allow-other-keys)
+ (let* ((digestif (assoc-ref outputs "out"))
+ (lua (assoc-ref inputs "lua"))
+ (lua-lpeg (assoc-ref inputs "lua-lpeg"))
+ (lua-filesystem (assoc-ref inputs "lua-filesystem"))
+ (lua-version ,(version-major+minor (package-version lua))))
+ (wrap-program (string-append digestif "/bin/digestif")
+ `("LUA_PATH" ";" suffix
+ (,(format #f "~a/share/lua/~a/?.lua" digestif lua-version)))
+ `("DIGESTIF_DATA" suffix (,(format #f "~a/share/digestif" digestif)))
+ `("LUA_PATH" ";" suffix
+ (,(format #f "~a/share/lua/~a/?.lua" lua-lpeg lua-version)))
+ `("LUA_CPATH" ";" suffix
+ (,(format #f "~a/lib/lua/~a/?.so" lua-lpeg lua-version)))
+ `("LUA_PATH" ";" suffix
+ (,(format #f "~a/share/lua/~a/?.lua" lua-filesystem lua-version)))
+ `("LUA_CPATH" ";" suffix
+ (,(format #f "~a/lib/lua/~a/?.so" lua-filesystem lua-version))))
+ #t))))))))
diff --git a/crn/packages/patches/typeguard-version.patch b/crn/packages/patches/typeguard-version.patch
new file mode 100644
index 0000000..adef1e5
--- /dev/null
+++ b/crn/packages/patches/typeguard-version.patch
@@ -0,0 +1,9 @@
+--- a/setup.cfg 2023-03-25 12:48:39.885304905 -0400
++++ b/setup.cfg 2023-03-25 12:49:00.593286388 -0400
+@@ -1,5 +1,6 @@
+ [metadata]
+ name = typeguard
++version = 2.13.3
+ description = Run-time type checker for Python
+ long_description = file: README.rst
+ author = Alex Grönholm
diff --git a/crn/packages/python-xyz.scm b/crn/packages/python-xyz.scm
new file mode 100644
index 0000000..db5ad46
--- /dev/null
+++ b/crn/packages/python-xyz.scm
@@ -0,0 +1,123 @@
+(define-module (crn packages python-xyz))
+(use-modules (crn packages)
+ (guix build utils)
+ (guix download)
+ (guix gexp)
+ (guix packages)
+ (guix licenses)
+ (guix build-system python)
+ (guix build-system pyproject)
+ ((gnu packages) #:prefix gnu:)
+ (gnu packages check)
+ (gnu packages python-build)
+ (gnu packages python-check)
+ (gnu packages python-xyz)
+ (gnu packages python-web))
+
+(define-public python-typeguard
+ (package
+ (name "python-typeguard")
+ (version "2.13.3")
+ (source (origin
+ (method url-fetch)
+ (uri (pypi-uri "typeguard" version))
+ (sha256
+ (base32
+ "1i5qzcyw2715h1g1hvj7fxykck2bkxyshpngjr3nfcx1lf6smv80"))
+ (patches (search-patches "typeguard-version.patch"))))
+ (build-system python-build-system)
+ (native-inputs (list python-mypy python-pytest python-typing-extensions))
+ (home-page "")
+ (synopsis "Run-time type checker for Python")
+ (description "Run-time type checker for Python")
+ (license expat)))
+
+(define-public python-lsprotocol
+ (package
+ (name "python-lsprotocol")
+ (version "2022.0.0a10")
+ (source (origin
+ (method url-fetch)
+ (uri (pypi-uri "lsprotocol" version))
+ (sha256
+ (base32
+ "0l1wg3hp5agvy8dy5345bq7yll7xxxji4xp37sgrgv54nxq8gmrc"))))
+ (build-system pyproject-build-system)
+ (native-inputs (list python-flit-core))
+ (inputs (list python-attrs))
+ (propagated-inputs (list python-attrs python-cattrs))
+ (home-page "")
+ (synopsis "Python implementation of the Language Server Protocol.")
+ (description "Python implementation of the Language Server Protocol.")
+ (license expat)
+ (arguments
+ (list #:phases
+ #~(modify-phases %standard-phases
+ (delete 'check))))))
+
+(define-public python-gls
+ (package
+ (name "python-gls")
+ (version "1.0.1")
+ (source (origin
+ (method url-fetch)
+ (uri "https://files.pythonhosted.org/packages/8e/27/58ff0f76b379fc11a1d03e8d4b4e96fd0abb463d27709a7fb4193bcdbbc4/pygls-1.0.1.tar.gz")
+ (sha256
+ (base32
+ "1clcnx1s9knh6dgmf4ykrca7yq19w6kjphsvfmffp426pgfrivpk"))))
+ (build-system python-build-system)
+ (native-inputs (list python-toml python-setuptools-scm python-wheel python-typeguard))
+ (propagated-inputs (list python-lsprotocol))
+ (home-page "https://github.com/openlawlibrary/pygls")
+ (synopsis "A pythonic generic lanuage server.")
+ (description "pygls (pronounced like \"pie glass\") is a pythonic generic implementation of the Language Server Protocol for use as a foundation for writing your own Language Servers in just a few lines of code.")
+ (license asl2.0)
+ (arguments
+ (list
+ #:phases
+ #~(modify-phases %standard-phases
+ (delete 'check))))))
+
+(define-public python-attrs
+ (package
+ (name "python-attrs")
+ (version "22.2.0")
+ (source (origin
+ (method url-fetch)
+ (uri (pypi-uri "attrs" version))
+ (sha256
+ (base32
+ "16az31ccld8s3xj7q1iw6a402sf92lfpvcwdyq1kr6815zy7n8n9"))))
+ (build-system python-build-system)
+ (native-inputs (list
+ python-cloudpickle
+ python-hypothesis
+ python-mypy
+ python-pympler
+ python-zope-interface))
+ (home-page "https://www.attrs.org/")
+ (synopsis "Classes Without Boilerplate")
+ (description "Classes Without Boilerplate")
+ (license expat)
+ (arguments
+ (list #:phases
+ #~(modify-phases %standard-phases
+ (delete 'check))))))
+
+(define-public python-cattrs
+(package
+ (name "python-cattrs")
+ (version "22.2.0")
+ (source (origin
+ (method url-fetch)
+ (uri (pypi-uri "cattrs" version))
+ (sha256
+ (base32
+ "0vfggbggsdni4hdis17xr8z9cnyw5klnrdp7avv3qhlr4djdbvph"))))
+ (build-system python-build-system)
+ (propagated-inputs (list python-attrs python-exceptiongroup
+ python-typing-extensions))
+ (home-page "https://github.com/python-attrs/cattrs")
+ (synopsis "Composable complex class support for attrs and dataclasses.")
+ (description "Composable complex class support for attrs and dataclasses.")
+ (license expat)))