aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristopher R. Nelson <christopher.nelson@languidnights.com>2023-05-13 13:14:08 -0400
committerChristopher R. Nelson <christopher.nelson@languidnights.com>2023-05-13 13:14:08 -0400
commit2480744234dd4226ef3b723870ca9e4e022ee754 (patch)
treeb415ef3181becb4dda5abe747bef3a35d9e73721
parent4849a5b03f8663f5f01832c2c7191c6e4dbc69bf (diff)
add sway-contrib (mostly) python programs
-rw-r--r--crn/packages/patches/sway-contrib-python.patch18
-rw-r--r--crn/packages/python-xyz.scm161
2 files changed, 169 insertions, 10 deletions
diff --git a/crn/packages/patches/sway-contrib-python.patch b/crn/packages/patches/sway-contrib-python.patch
new file mode 100644
index 0000000..78f8f0b
--- /dev/null
+++ b/crn/packages/patches/sway-contrib-python.patch
@@ -0,0 +1,18 @@
+diff --unified a/contrib/autoname-workspaces.py b/contrib/autoname-workspaces.py
+--- a/contrib/autoname-workspaces.py 2023-05-13 13:02:45.738991799 -0400
++++ b/contrib/autoname-workspaces.py 2023-05-13 13:04:08.494950048 -0400
+@@ -1,4 +1,4 @@
+-#!/usr/bin/python
++#!/usr/bin/env python3
+
+ # This script requires i3ipc-python package (install it from a system package manager
+ # or pip).
+diff --unified a/contrib/inactive-windows-transparency.py b/contrib/inactive-windows-transparency.py
+--- a/contrib/inactive-windows-transparency.py 2023-05-13 12:52:44.367358344 -0400
++++ b/contrib/inactive-windows-transparency.py 2023-05-13 12:29:43.700170305 -0400
+@@ -1,4 +1,4 @@
+-#!/usr/bin/python
++#!/usr/bin/env python3
+
+ # This script requires i3ipc-python package (install it from a system package manager
+ # or pip).
diff --git a/crn/packages/python-xyz.scm b/crn/packages/python-xyz.scm
index db5ad46..9e8a2b6 100644
--- a/crn/packages/python-xyz.scm
+++ b/crn/packages/python-xyz.scm
@@ -2,9 +2,11 @@
(use-modules (crn packages)
(guix build utils)
(guix download)
+ (guix git-download)
(guix gexp)
(guix packages)
(guix licenses)
+ (guix build-system copy)
(guix build-system python)
(guix build-system pyproject)
((gnu packages) #:prefix gnu:)
@@ -105,19 +107,158 @@
(delete 'check))))))
(define-public python-cattrs
-(package
- (name "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)))
+
+(define-public sway-contrib
+ (package
+ (name "sway-contrib")
+ (version "1.8")
+ (source
+ (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/swaywm/sway")
+ (commit version)))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32 "17dqr2lkmcv2ssp7vky27zw599i77whpb1aqh1s6kl8a8vkrz6mg"))))
+
+ (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 "cattrs" version))
+ (uri (pypi-uri "attrs" version))
(sha256
(base32
- "0vfggbggsdni4hdis17xr8z9cnyw5klnrdp7avv3qhlr4djdbvph"))))
+ "16az31ccld8s3xj7q1iw6a402sf92lfpvcwdyq1kr6815zy7n8n9"))))
(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)))
+ (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)))
+
+(define-public sway-contrib
+ (package
+ (name "sway-contrib")
+ (version "1.8")
+ (source
+ (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/swaywm/sway")
+ (commit version)))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32 "17dqr2lkmcv2ssp7vky27zw599i77whpb1aqh1s6kl8a8vkrz6mg"))
+ (patches (search-patches "sway-contrib-python.patch"))))
+ (build-system copy-build-system)
+ (arguments
+ '(#:install-plan
+ '(("contrib" "bin"))))
+ (inputs (gnu:specifications->packages (list "sway"
+ "python")))
+ (propagated-inputs (gnu:specifications->packages (list "python-i3ipc"
+ "jq"
+ "grim")))
+ (home-page "https://github.com/swaywm/sway")
+ (synopsis "transparency for inactive windows in sway")
+ (description "transparency for inactive windows in sway")
+ (license expat)))