all messages for Guix-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* [bug#56717] [PATCH 1/2] gnu: Add python-i3ipc
  2022-07-23  7:00     ` [bug#56717] [PATCH 0/2] gnu: Add python-i3ipc and python-autotiling Hilton Chain via Guix-patches via
@ 2022-07-23  6:31       ` Hilton Chain via Guix-patches via
  2022-07-23  8:50         ` ( via Guix-patches via
  2022-07-23  8:54         ` ( via Guix-patches via
  2022-07-23  6:33       ` [bug#56717] [PATCH 2/2] gnu: Add python-autotiling Hilton Chain via Guix-patches via
  1 sibling, 2 replies; 24+ messages in thread
From: Hilton Chain via Guix-patches via @ 2022-07-23  6:31 UTC (permalink / raw)
  To: 56717

* gnu/packages/python-xyz.scm (python-i3ipc): New variable.

Signed-off-by: Hilton Chain <hako@ultrarare.space>
---
 gnu/packages/python-xyz.scm | 23 +++++++++++++++++++++++
 1 file changed, 23 insertions(+)

diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm
index 11f709f7b5..4bf6b3d965 100644
--- a/gnu/packages/python-xyz.scm
+++ b/gnu/packages/python-xyz.scm
@@ -124,6 +124,7 @@
 ;;; Copyright © 2022 Artyom V. Poptsov <poptsov.artyom@gmail.com>
 ;;; Copyright © 2022 Paul A. Patience <paul@apatience.com>
 ;;; Copyright © 2022 Jean-Pierre De Jesus DIAZ <me@jeandudey.tech>
+;;; Copyright © 2022 Hilton Chain <hako@ultrarare.space>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -30203,3 +30204,25 @@ (define-public python-bsdiff4
 binary diff utility.  It also provides two command-line tools, @code{bsdiff4}
 and @code{bspatch4}.")
     (license license:bsd-2)))
+
+(define-public python-i3ipc
+  (package
+    (name "python-i3ipc")
+    (version "2.2.1")
+    (source (origin
+              (method git-fetch)
+              (uri (git-reference
+                    (url "https://github.com/altdesktop/i3ipc-python")
+                    (commit (string-append "v" version))))
+              (file-name (git-file-name name version))
+              (sha256
+               (base32
+                "13bzs9dcv27czpnnbgz7a037lm8h991c8gk0qzzk5mq5yak24715"))))
+    (build-system python-build-system)
+    (arguments
+     '(#:tests? #f))
+    (inputs (list python-xlib))
+    (home-page "https://github.com/altdesktop/i3ipc-python")
+    (synopsis "Python library for controlling i3wm and sway")
+    (description "An improved Python library to control i3wm and sway.")
+    (license license:bsd-3)))
-- 
2.36.1





^ permalink raw reply related	[flat|nested] 24+ messages in thread

* [bug#56717] [PATCH 2/2] gnu: Add python-autotiling.
  2022-07-23  7:00     ` [bug#56717] [PATCH 0/2] gnu: Add python-i3ipc and python-autotiling Hilton Chain via Guix-patches via
  2022-07-23  6:31       ` [bug#56717] [PATCH 1/2] gnu: Add python-i3ipc Hilton Chain via Guix-patches via
@ 2022-07-23  6:33       ` Hilton Chain via Guix-patches via
  2022-07-23  8:54         ` ( via Guix-patches via
  1 sibling, 1 reply; 24+ messages in thread
From: Hilton Chain via Guix-patches via @ 2022-07-23  6:33 UTC (permalink / raw)
  To: 56717

* gnu/packages/python-xyz.scm (python-autotiling): New variable.

Signed-off-by: Hilton Chain <hako@ultrarare.space>
---
 gnu/packages/python-xyz.scm | 27 +++++++++++++++++++++++++++
 1 file changed, 27 insertions(+)

diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm
index 4bf6b3d965..8fd413a683 100644
--- a/gnu/packages/python-xyz.scm
+++ b/gnu/packages/python-xyz.scm
@@ -30226,3 +30226,30 @@ (define-public python-i3ipc
     (synopsis "Python library for controlling i3wm and sway")
     (description "An improved Python library to control i3wm and sway.")
     (license license:bsd-3)))
+
+(define-public python-autotiling
+  (package
+    (name "autotiling")
+    (version "1.6")
+    (source (origin
+              (method git-fetch)
+              (uri (git-reference
+                    (url "https://github.com/nwg-piotr/autotiling")
+                    (commit (string-append "v" version))))
+              (file-name (git-file-name name version))
+              (sha256
+               (base32
+                "1hjlvg7095s322gb43r9g7mqlsy3pj13l827jpnbn5x0918rq9rr"))))
+    (build-system python-build-system)
+    (arguments
+     '(#:tests? #f))
+    (inputs (list python-wheel python-xlib))
+    (propagated-inputs (list python-i3ipc))
+    (home-page "https://github.com/nwg-piotr/autotiling")
+    (synopsis
+     "Automatically switch the horizontal/vertical window split orientation in
+ i3 and sway")
+    (description "This script uses the i3ipc-python library to switch the layout
+splith/splitv depending on the currently focused window dimensions. It works on
+both sway and i3 window managers.")
+    (license license:gpl3)))
-- 
2.36.1





^ permalink raw reply related	[flat|nested] 24+ messages in thread

* [bug#56717] [PATCH 0/2] gnu: Add python-i3ipc and python-autotiling.
@ 2022-07-23  7:00     ` Hilton Chain via Guix-patches via
  2022-07-23  6:31       ` [bug#56717] [PATCH 1/2] gnu: Add python-i3ipc Hilton Chain via Guix-patches via
  2022-07-23  6:33       ` [bug#56717] [PATCH 2/2] gnu: Add python-autotiling Hilton Chain via Guix-patches via
  0 siblings, 2 replies; 24+ messages in thread
From: Hilton Chain via Guix-patches via @ 2022-07-23  7:00 UTC (permalink / raw)
  To: 56717

Hi Guix,

These patches add autotiling (a tool to automatically switch the
horizontal/vertical window split orientation in i3 and sway) and its
dependency i3ipc.

Since I do not have a working X environment, their tests are currently
disabled.

Thanks!

Hilton Chain (2):
  gnu: Add python-i3ipc
  gnu: Add python-autotiling.

 gnu/packages/python-xyz.scm | 50 +++++++++++++++++++++++++++++++++++++
 1 file changed, 50 insertions(+)


base-commit: 32a00363435ac8c1bc93ef1281b2c2afc28a8877
--
2.36.1




^ permalink raw reply	[flat|nested] 24+ messages in thread

* [bug#56717] [PATCH 1/2] gnu: Add python-i3ipc
  2022-07-23  6:31       ` [bug#56717] [PATCH 1/2] gnu: Add python-i3ipc Hilton Chain via Guix-patches via
@ 2022-07-23  8:50         ` ( via Guix-patches via
  2022-07-23  8:54         ` ( via Guix-patches via
  1 sibling, 0 replies; 24+ messages in thread
From: ( via Guix-patches via @ 2022-07-23  8:50 UTC (permalink / raw)
  To: Hilton Chain, 56717

Hello!

On Sat Jul 23, 2022 at 7:31 AM BST, Hilton Chain via Guix-patches via wrote:
> +    (arguments
> +     '(#:tests? #f))
Could you add an explanation of why the test fails in a comment, if
possible? Also, (arguments (list ...)) is now generally preferred to
(arguments '(...)) :)

    -- (




^ permalink raw reply	[flat|nested] 24+ messages in thread

* [bug#56717] [PATCH 1/2] gnu: Add python-i3ipc
  2022-07-23  6:31       ` [bug#56717] [PATCH 1/2] gnu: Add python-i3ipc Hilton Chain via Guix-patches via
  2022-07-23  8:50         ` ( via Guix-patches via
@ 2022-07-23  8:54         ` ( via Guix-patches via
  1 sibling, 0 replies; 24+ messages in thread
From: ( via Guix-patches via @ 2022-07-23  8:54 UTC (permalink / raw)
  To: Hilton Chain, 56717

On Sat Jul 23, 2022 at 7:31 AM BST, Hilton Chain via Guix-patches via wrote:
> +    (inputs (list python-xlib))
You'll want to propagate this input, as is usually done for Python
libraries.

    -- (




^ permalink raw reply	[flat|nested] 24+ messages in thread

* [bug#56717] [PATCH 2/2] gnu: Add python-autotiling.
  2022-07-23  6:33       ` [bug#56717] [PATCH 2/2] gnu: Add python-autotiling Hilton Chain via Guix-patches via
@ 2022-07-23  8:54         ` ( via Guix-patches via
  2022-07-23 10:31           ` [bug#56717] [PATCH v2 1/2] gnu: Add python-i3ipc Hilton Chain via Guix-patches via
  0 siblings, 1 reply; 24+ messages in thread
From: ( via Guix-patches via @ 2022-07-23  8:54 UTC (permalink / raw)
  To: Hilton Chain, 56717

On Sat Jul 23, 2022 at 7:33 AM BST, Hilton Chain via Guix-patches via wrote:
> +(define-public python-autotiling
I think this should be changed to `i3-autotiling`, since it's a Python
program, not a library.

> +  (package
> +    (name "autotiling")
Same here.

> +    (arguments
> +     '(#:tests? #f))
Can you add an explanation and change to (list ...) style here too,
please?

> +    (inputs (list python-wheel python-xlib))
I think python-wheel only needs to be a native-input, and python-xlib
can be removed if you propagate it in python-i3ipc.

    -- (




^ permalink raw reply	[flat|nested] 24+ messages in thread

* [bug#56717] [PATCH v2 1/2] gnu: Add python-i3ipc.
  2022-07-23  8:54         ` ( via Guix-patches via
@ 2022-07-23 10:31           ` Hilton Chain via Guix-patches via
  2022-07-23 10:31             ` [bug#56717] [PATCH v2 2/2] gnu: Add i3-autotiling Hilton Chain via Guix-patches via
  2022-07-23 10:48             ` [bug#56717] [PATCH v2 1/2] gnu: Add python-i3ipc ( via Guix-patches via
  0 siblings, 2 replies; 24+ messages in thread
From: Hilton Chain via Guix-patches via @ 2022-07-23 10:31 UTC (permalink / raw)
  To: (; +Cc: 56717

* gnu/packages/python-xyz.scm (python-i3ipc): New variable.

Signed-off-by: Hilton Chain <hako@ultrarare.space>
---
 gnu/packages/python-xyz.scm | 22 ++++++++++++++++++++++
 1 file changed, 22 insertions(+)

diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm
index 11f709f7b5..2115007a97 100644
--- a/gnu/packages/python-xyz.scm
+++ b/gnu/packages/python-xyz.scm
@@ -124,6 +124,7 @@
 ;;; Copyright © 2022 Artyom V. Poptsov <poptsov.artyom@gmail.com>
 ;;; Copyright © 2022 Paul A. Patience <paul@apatience.com>
 ;;; Copyright © 2022 Jean-Pierre De Jesus DIAZ <me@jeandudey.tech>
+;;; Copyright © 2022 Hilton Chain <hako@ultrarare.space>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -30203,3 +30204,24 @@ (define-public python-bsdiff4
 binary diff utility.  It also provides two command-line tools, @code{bsdiff4}
 and @code{bspatch4}.")
     (license license:bsd-2)))
+
+(define-public python-i3ipc
+  (package
+    (name "python-i3ipc")
+    (version "2.2.1")
+    (source (origin
+              (method git-fetch)
+              (uri (git-reference
+                    (url "https://github.com/altdesktop/i3ipc-python")
+                    (commit (string-append "v" version))))
+              (file-name (git-file-name name version))
+              (sha256
+               (base32
+                "13bzs9dcv27czpnnbgz7a037lm8h991c8gk0qzzk5mq5yak24715"))))
+    (build-system python-build-system)
+    (arguments (list #:tests? #f)) ;a working X environment is needed to run the tests
+    (propagated-inputs (list python-xlib))
+    (home-page "https://github.com/altdesktop/i3ipc-python")
+    (synopsis "Python library for controlling i3wm and sway")
+    (description "An improved Python library to control i3wm and sway.")
+    (license license:bsd-3)))
--
2.36.1




^ permalink raw reply related	[flat|nested] 24+ messages in thread

* [bug#56717] [PATCH v2 2/2] gnu: Add i3-autotiling.
  2022-07-23 10:31           ` [bug#56717] [PATCH v2 1/2] gnu: Add python-i3ipc Hilton Chain via Guix-patches via
@ 2022-07-23 10:31             ` Hilton Chain via Guix-patches via
  2022-07-23 10:52               ` ( via Guix-patches via
  2022-07-23 11:01               ` Maxime Devos
  2022-07-23 10:48             ` [bug#56717] [PATCH v2 1/2] gnu: Add python-i3ipc ( via Guix-patches via
  1 sibling, 2 replies; 24+ messages in thread
From: Hilton Chain via Guix-patches via @ 2022-07-23 10:31 UTC (permalink / raw)
  To: (; +Cc: 56717

* gnu/packages/python-xyz.scm (i3-autotiling): New variable.

Signed-off-by: Hilton Chain <hako@ultrarare.space>
---
 gnu/packages/python-xyz.scm | 26 ++++++++++++++++++++++++++
 1 file changed, 26 insertions(+)

diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm
index 2115007a97..eeeced71b7 100644
--- a/gnu/packages/python-xyz.scm
+++ b/gnu/packages/python-xyz.scm
@@ -30225,3 +30225,29 @@ (define-public python-i3ipc
     (synopsis "Python library for controlling i3wm and sway")
     (description "An improved Python library to control i3wm and sway.")
     (license license:bsd-3)))
+
+(define-public i3-autotiling
+  (package
+    (name "i3-autotiling")
+    (version "1.6")
+    (source (origin
+              (method git-fetch)
+              (uri (git-reference
+                    (url "https://github.com/nwg-piotr/autotiling")
+                    (commit (string-append "v" version))))
+              (file-name (git-file-name name version))
+              (sha256
+               (base32
+                "1hjlvg7095s322gb43r9g7mqlsy3pj13l827jpnbn5x0918rq9rr"))))
+    (build-system python-build-system)
+    (arguments (list #:tests? #f)) ;a working X environment is needed to run the tests
+    (native-inputs (list python-wheel))
+    (propagated-inputs (list python-i3ipc))
+    (home-page "https://github.com/nwg-piotr/autotiling")
+    (synopsis
+     "Automatically switch the horizontal/vertical window split orientation in
+ i3 and sway")
+    (description "This script uses the i3ipc-python library to switch the layout
+splith/splitv depending on the currently focused window dimensions. It works on
+both sway and i3 window managers.")
+    (license license:gpl3)))
--
2.36.1




^ permalink raw reply related	[flat|nested] 24+ messages in thread

* [bug#56717] [PATCH v2 0/2] gnu: Add python-i3ipc and i3-autotiling.
  2022-07-23  8:54         ` ( via Guix-patches via
@ 2022-07-23 10:40   ` Hilton Chain via Guix-patches via
  2022-07-23  7:00     ` [bug#56717] [PATCH 0/2] gnu: Add python-i3ipc and python-autotiling Hilton Chain via Guix-patches via
  0 siblings, 1 reply; 24+ messages in thread
From: Hilton Chain via Guix-patches via @ 2022-07-23 10:40 UTC (permalink / raw)
  To: (; +Cc: 56717

v1 -> v2:
* Package name: python-autotiling -> i3-autotiling
* Arguments style: use (list ...) instead of '(...)
* Comments for tests

Thank you, ( !

Hilton Chain (2):
  gnu: Add python-i3ipc.
  gnu: Add i3-autotiling.

 gnu/packages/python-xyz.scm | 48 +++++++++++++++++++++++++++++++++++++
 1 file changed, 48 insertions(+)


base-commit: 32a00363435ac8c1bc93ef1281b2c2afc28a8877
--
2.36.1




^ permalink raw reply	[flat|nested] 24+ messages in thread

* [bug#56717] [PATCH v2 1/2] gnu: Add python-i3ipc.
  2022-07-23 10:31           ` [bug#56717] [PATCH v2 1/2] gnu: Add python-i3ipc Hilton Chain via Guix-patches via
  2022-07-23 10:31             ` [bug#56717] [PATCH v2 2/2] gnu: Add i3-autotiling Hilton Chain via Guix-patches via
@ 2022-07-23 10:48             ` ( via Guix-patches via
  1 sibling, 0 replies; 24+ messages in thread
From: ( via Guix-patches via @ 2022-07-23 10:48 UTC (permalink / raw)
  To: Hilton Chain; +Cc: 56717

Almost LGTM :)

On Sat Jul 23, 2022 at 11:31 AM BST, Hilton Chain wrote:
> +    (synopsis "Python library for controlling i3wm and sway")
i3wm -> i3 and sway -> Sway maybe?

> +    (description "An improved Python library to control i3wm and sway.")
Maybe better as:

(description
 "This package provides a Python library for controlling the i3 and Sway
window managers.")

Also, have you run `guix lint python-i3ipc i3-autotiling`? Make sure to
do that and resolve any issues it raises :)

    -- (




^ permalink raw reply	[flat|nested] 24+ messages in thread

* [bug#56717] [PATCH v2 2/2] gnu: Add i3-autotiling.
  2022-07-23 10:31             ` [bug#56717] [PATCH v2 2/2] gnu: Add i3-autotiling Hilton Chain via Guix-patches via
@ 2022-07-23 10:52               ` ( via Guix-patches via
  2022-07-23 11:01               ` Maxime Devos
  1 sibling, 0 replies; 24+ messages in thread
From: ( via Guix-patches via @ 2022-07-23 10:52 UTC (permalink / raw)
  To: Hilton Chain; +Cc: 56717

On Sat Jul 23, 2022 at 11:31 AM BST, Hilton Chain wrote:
> +    (synopsis
> +     "Automatically switch the horizontal/vertical window split orientation in
> + i3 and sway")
I think a synopsis that spills onto multiple lines is probably too long.
How about simply:

(synopsis "Automatically tile windows in i3 and Sway")

> +    (description "This script uses the i3ipc-python library to switch the layout
> +splith/splitv depending on the currently focused window dimensions. It works on
> +both sway and i3 window managers.")
Maybe something like:

(description
 "This package provides a script that automatically switches the layout
of an i3 or Sway desktop based on the dimensions of the focused window.")

(By the way, that's the standard formatting for a description: the
string is on a new line.)

    -- (




^ permalink raw reply	[flat|nested] 24+ messages in thread

* [bug#56717] [PATCH v2 2/2] gnu: Add i3-autotiling.
  2022-07-23 10:31             ` [bug#56717] [PATCH v2 2/2] gnu: Add i3-autotiling Hilton Chain via Guix-patches via
  2022-07-23 10:52               ` ( via Guix-patches via
@ 2022-07-23 11:01               ` Maxime Devos
  2022-07-23 11:38                 ` Hilton Chain via Guix-patches via
  1 sibling, 1 reply; 24+ messages in thread
From: Maxime Devos @ 2022-07-23 11:01 UTC (permalink / raw)
  To: Hilton Chain, (; +Cc: 56717


[-- Attachment #1.1.1: Type: text/plain, Size: 422 bytes --]


On 23-07-2022 12:31, Hilton Chain via Guix-patches via wrote:
> +    (arguments (list #:tests? #f)) ;a working X environment is needed to run the tests

You can make a working X environment with "xvfb-run -- the-test-command" 
or with (IIRC) "Xvfb :1&" + (sleep 1) (preferably the former, as the 
latter is racy) -- search with "git grep -F xvfb-run" or "git grep -F 
Xvfb" for examples.

Greetings,
Maxime.


[-- Attachment #1.1.2: OpenPGP public key --]
[-- Type: application/pgp-keys, Size: 929 bytes --]

[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 236 bytes --]

^ permalink raw reply	[flat|nested] 24+ messages in thread

* [bug#56717] [PATCH v2 2/2] gnu: Add i3-autotiling.
  2022-07-23 11:01               ` Maxime Devos
@ 2022-07-23 11:38                 ` Hilton Chain via Guix-patches via
  2022-07-23 12:17                   ` Maxime Devos
  0 siblings, 1 reply; 24+ messages in thread
From: Hilton Chain via Guix-patches via @ 2022-07-23 11:38 UTC (permalink / raw)
  To: Maxime Devos, (; +Cc: 56717

Thanks!

xvfb-run works well, however some "Fontconfig error: No writable cache directories"
occurs. I don't know what to do with this, do you have any ideas?

* Below attaching part of the build log:
---
/gnu/store/65i3nhcwmz0p8rqbg48gaavyky4g4hwk-python-3.9.9/lib/python3.9/selectors.py:469: Failed
---------------------------- Captured stderr setup -----------------------------
Fontconfig error: No writable cache directories
Fontconfig error: No writable cache directories
----------------------------- Captured stderr call -----------------------------
Fontconfig error: No writable cache directories
Fontconfig error: No writable cache directories
------------------------------ Captured log call -------------------------------
ERROR    asyncio:base_events.py:1738 Task exception was never retrieved
future: <Task finished name='Task-82' coro=<Connection.command() done, defined at /gnu/store/gwsda4lb70rzazfh0kzx9z3wx5i4z43b-python-i3ipc-2.2.1/lib/python3.9/site-packages/i3ipc/aio/connection.py:503> exception=OSError(107, 'Transport endpoint is not connected')>
Traceback (most recent call last):
  File "/gnu/store/gwsda4lb70rzazfh0kzx9z3wx5i4z43b-python-i3ipc-2.2.1/lib/python3.9/site-packages/i3ipc/aio/connection.py", line 514, in command
    data = await self._message(MessageType.COMMAND, cmd)
  File "/gnu/store/gwsda4lb70rzazfh0kzx9z3wx5i4z43b-python-i3ipc-2.2.1/lib/python3.9/site-packages/i3ipc/aio/connection.py", line 407, in _message
    await self._loop.sock_sendall(self._cmd_socket, _pack(message_type, payload))
  File "/gnu/store/65i3nhcwmz0p8rqbg48gaavyky4g4hwk-python-3.9.9/lib/python3.9/asyncio/selector_events.py", line 446, in sock_sendall
    n = sock.send(data)
OSError: [Errno 107] Transport endpoint is not connected
ERROR    asyncio:base_events.py:1738 Future exception was never retrieved
future: <Future finished exception=FileNotFoundError(2, 'No such file or directory')>
Traceback (most recent call last):
  File "/gnu/store/gwsda4lb70rzazfh0kzx9z3wx5i4z43b-python-i3ipc-2.2.1/lib/python3.9/site-packages/i3ipc/aio/connection.py", line 383, in do_reconnect
    await self.connect()
  File "/gnu/store/gwsda4lb70rzazfh0kzx9z3wx5i4z43b-python-i3ipc-2.2.1/lib/python3.9/site-packages/i3ipc/aio/connection.py", line 359, in connect
    self._cmd_socket.connect(self.socket_path)
FileNotFoundError: [Errno 2] No such file or directory




^ permalink raw reply	[flat|nested] 24+ messages in thread

* [bug#56717] [PATCH v2 2/2] gnu: Add i3-autotiling.
  2022-07-23 11:38                 ` Hilton Chain via Guix-patches via
@ 2022-07-23 12:17                   ` Maxime Devos
  2022-07-23 12:22                     ` ( via Guix-patches via
  0 siblings, 1 reply; 24+ messages in thread
From: Maxime Devos @ 2022-07-23 12:17 UTC (permalink / raw)
  To: Hilton Chain, (; +Cc: 56717


[-- Attachment #1.1.1: Type: text/plain, Size: 782 bytes --]

On 23-07-2022 13:38, Hilton Chain wrote:

> xvfb-run works well, however some "Fontconfig error: No writable cache directories"
> occurs. I don't know what to do with this, do you have any ideas?

For these kind of things, creating the relevant directory and setting an 
environment variable tends to work. Maybe try (setenv "HOME" 
(getcwd)))?  However, IIUC, these fontconfig errors can usually be 
ignored (probably because it's just a cache?), likely the "Transport 
endpoint is not connected" test failure is independent.

My guess is that it tries to connect to the WM i3, but that WM is not 
running in the build environment fails.

You could give starting the WM before running the test a try, but maybe 
it's not worth the effort.

Greetings,
Maxime.


[-- Attachment #1.1.2: OpenPGP public key --]
[-- Type: application/pgp-keys, Size: 929 bytes --]

[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 236 bytes --]

^ permalink raw reply	[flat|nested] 24+ messages in thread

* [bug#56717] [PATCH v2 2/2] gnu: Add i3-autotiling.
  2022-07-23 12:17                   ` Maxime Devos
@ 2022-07-23 12:22                     ` ( via Guix-patches via
  2022-07-23 12:46                       ` [bug#56717] [PATCH 1/2] gnu: Add python-i3ipc Hilton Chain via Guix-patches via
  0 siblings, 1 reply; 24+ messages in thread
From: ( via Guix-patches via @ 2022-07-23 12:22 UTC (permalink / raw)
  To: Maxime Devos, Hilton Chain; +Cc: 56717

On Sat Jul 23, 2022 at 1:17 PM BST, Maxime Devos wrote:
> For these kind of things, creating the relevant directory and setting an 
> environment variable tends to work. Maybe try (setenv "HOME" 
> (getcwd)))?  However, IIUC, these fontconfig errors can usually be 
> ignored (probably because it's just a cache?), likely the "Transport 
> endpoint is not connected" test failure is independent.
We got this working on IRC :)

> My guess is that it tries to connect to the WM i3, but that WM is not 
> running in the build environment fails.
>
> You could give starting the WM before running the test a try, but maybe 
> it's not worth the effort.
Looks like the tests do a popen on i3 themselves:
<https://github.com/altdesktop/i3ipc-python/blob/master/test/ipctest.py#L16>



    -- (




^ permalink raw reply	[flat|nested] 24+ messages in thread

* [bug#56717] [PATCH 1/2] gnu: Add python-i3ipc.
  2022-07-23 12:22                     ` ( via Guix-patches via
@ 2022-07-23 12:46                       ` Hilton Chain via Guix-patches via
  2022-07-23 12:48                         ` [bug#56717] [PATCH 2/2] gnu: Add i3-autotiling Hilton Chain via Guix-patches via
  0 siblings, 1 reply; 24+ messages in thread
From: Hilton Chain via Guix-patches via @ 2022-07-23 12:46 UTC (permalink / raw)
  To: (, Maxime Devos; +Cc: 56717

* gnu/packages/python-xyz.scm (python-i3ipc): New variable.

Signed-off-by: Hilton Chain <hako@ultrarare.space>
---
 gnu/packages/python-xyz.scm | 24 ++++++++++++++++++++++++
 1 file changed, 24 insertions(+)

diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm
index 11f709f7b5..d67b535d40 100644
--- a/gnu/packages/python-xyz.scm
+++ b/gnu/packages/python-xyz.scm
@@ -124,6 +124,7 @@
 ;;; Copyright © 2022 Artyom V. Poptsov <poptsov.artyom@gmail.com>
 ;;; Copyright © 2022 Paul A. Patience <paul@apatience.com>
 ;;; Copyright © 2022 Jean-Pierre De Jesus DIAZ <me@jeandudey.tech>
+;;; Copyright © 2022 Hilton Chain <hako@ultrarare.space>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -30203,3 +30204,26 @@ (define-public python-bsdiff4
 binary diff utility.  It also provides two command-line tools, @code{bsdiff4}
 and @code{bspatch4}.")
     (license license:bsd-2)))
+
+(define-public python-i3ipc
+  (package
+    (name "python-i3ipc")
+    (version "2.2.1")
+    (source (origin
+              (method git-fetch)
+              (uri (git-reference
+                    (url "https://github.com/altdesktop/i3ipc-python")
+                    (commit (string-append "v" version))))
+              (file-name (git-file-name name version))
+              (sha256
+               (base32
+                "13bzs9dcv27czpnnbgz7a037lm8h991c8gk0qzzk5mq5yak24715"))))
+    (build-system python-build-system)
+    (arguments (list #:tests? #f))      ;FIXME: some tests are unable to run
+    (propagated-inputs (list python-xlib))
+    (home-page "https://github.com/altdesktop/i3ipc-python")
+    (synopsis "Python library for controlling i3 and Sway")
+    (description
+     "This package provides a Python library for controlling the i3 and Sway
+ window managers.")
+    (license license:bsd-3)))
-- 
2.36.1





^ permalink raw reply related	[flat|nested] 24+ messages in thread

* [bug#56717] [PATCH v4 1/2] gnu: Add python-i3ipc.
  2022-07-23 12:56                           ` ( via Guix-patches via
@ 2022-07-23 12:46                             ` Hilton Chain via Guix-patches via
  2022-07-23 12:48                               ` [bug#56717] [PATCH v4 2/2] gnu: Add i3-autotiling Hilton Chain via Guix-patches via
  0 siblings, 1 reply; 24+ messages in thread
From: Hilton Chain via Guix-patches via @ 2022-07-23 12:46 UTC (permalink / raw)
  To: (, Maxime Devos; +Cc: 56717

* gnu/packages/python-xyz.scm (python-i3ipc): New variable.

Signed-off-by: Hilton Chain <hako@ultrarare.space>
---
 gnu/packages/python-xyz.scm | 24 ++++++++++++++++++++++++
 1 file changed, 24 insertions(+)

diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm
index 11f709f7b5..d67b535d40 100644
--- a/gnu/packages/python-xyz.scm
+++ b/gnu/packages/python-xyz.scm
@@ -124,6 +124,7 @@
 ;;; Copyright © 2022 Artyom V. Poptsov <poptsov.artyom@gmail.com>
 ;;; Copyright © 2022 Paul A. Patience <paul@apatience.com>
 ;;; Copyright © 2022 Jean-Pierre De Jesus DIAZ <me@jeandudey.tech>
+;;; Copyright © 2022 Hilton Chain <hako@ultrarare.space>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -30203,3 +30204,26 @@ (define-public python-bsdiff4
 binary diff utility.  It also provides two command-line tools, @code{bsdiff4}
 and @code{bspatch4}.")
     (license license:bsd-2)))
+
+(define-public python-i3ipc
+  (package
+    (name "python-i3ipc")
+    (version "2.2.1")
+    (source (origin
+              (method git-fetch)
+              (uri (git-reference
+                    (url "https://github.com/altdesktop/i3ipc-python")
+                    (commit (string-append "v" version))))
+              (file-name (git-file-name name version))
+              (sha256
+               (base32
+                "13bzs9dcv27czpnnbgz7a037lm8h991c8gk0qzzk5mq5yak24715"))))
+    (build-system python-build-system)
+    (arguments (list #:tests? #f))      ;FIXME: some tests are unable to run
+    (propagated-inputs (list python-xlib))
+    (home-page "https://github.com/altdesktop/i3ipc-python")
+    (synopsis "Python library for controlling i3 and Sway")
+    (description
+     "This package provides a Python library for controlling the i3 and Sway
+ window managers.")
+    (license license:bsd-3)))
--
2.36.1




^ permalink raw reply related	[flat|nested] 24+ messages in thread

* [bug#56717] [PATCH 2/2] gnu: Add i3-autotiling.
  2022-07-23 12:46                       ` [bug#56717] [PATCH 1/2] gnu: Add python-i3ipc Hilton Chain via Guix-patches via
@ 2022-07-23 12:48                         ` Hilton Chain via Guix-patches via
  2022-07-23 12:56                           ` ( via Guix-patches via
  0 siblings, 1 reply; 24+ messages in thread
From: Hilton Chain via Guix-patches via @ 2022-07-23 12:48 UTC (permalink / raw)
  To: (, Maxime Devos; +Cc: 56717

* gnu/packages/python-xyz.scm (i3-autotiling): New variable.

Signed-off-by: Hilton Chain <hako@ultrarare.space>
---
 gnu/packages/python-xyz.scm | 25 +++++++++++++++++++++++++
 1 file changed, 25 insertions(+)

diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm
index d67b535d40..fc00779b40 100644
--- a/gnu/packages/python-xyz.scm
+++ b/gnu/packages/python-xyz.scm
@@ -30227,3 +30227,28 @@ (define-public python-i3ipc
      "This package provides a Python library for controlling the i3 and Sway
  window managers.")
     (license license:bsd-3)))
+
+(define-public i3-autotiling
+  (package
+    (name "i3-autotiling")
+    (version "1.6")
+    (source (origin
+              (method git-fetch)
+              (uri (git-reference
+                    (url "https://github.com/nwg-piotr/autotiling")
+                    (commit (string-append "v" version))))
+              (file-name (git-file-name name version))
+              (sha256
+               (base32
+                "1hjlvg7095s322gb43r9g7mqlsy3pj13l827jpnbn5x0918rq9rr"))))
+    (build-system python-build-system)
+    (arguments (list #:tests? #f))      ;no tests
+    (native-inputs (list python-wheel))
+    (propagated-inputs (list python-i3ipc))
+    (home-page "https://github.com/nwg-piotr/autotiling")
+    (synopsis "Automatically tile windows in i3 and Sway")
+    (description
+     "This script uses the python-i3ipc library to switch the layout
+splith/splitv depending on the currently focused window dimensions.  It works on
+both sway and i3 window managers.")
+    (license license:gpl3)))
-- 
2.36.1





^ permalink raw reply related	[flat|nested] 24+ messages in thread

* [bug#56717] [PATCH v4 2/2] gnu: Add i3-autotiling.
  2022-07-23 12:46                             ` [bug#56717] [PATCH v4 1/2] gnu: Add python-i3ipc Hilton Chain via Guix-patches via
@ 2022-07-23 12:48                               ` Hilton Chain via Guix-patches via
  0 siblings, 0 replies; 24+ messages in thread
From: Hilton Chain via Guix-patches via @ 2022-07-23 12:48 UTC (permalink / raw)
  To: (, Maxime Devos; +Cc: 56717

* gnu/packages/python-xyz.scm (i3-autotiling): New variable.

Signed-off-by: Hilton Chain <hako@ultrarare.space>
---
 gnu/packages/python-xyz.scm | 24 ++++++++++++++++++++++++
 1 file changed, 24 insertions(+)

diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm
index d67b535d40..114d7817fe 100644
--- a/gnu/packages/python-xyz.scm
+++ b/gnu/packages/python-xyz.scm
@@ -30227,3 +30227,27 @@ (define-public python-i3ipc
      "This package provides a Python library for controlling the i3 and Sway
  window managers.")
     (license license:bsd-3)))
+
+(define-public i3-autotiling
+  (package
+    (name "i3-autotiling")
+    (version "1.6")
+    (source (origin
+              (method git-fetch)
+              (uri (git-reference
+                    (url "https://github.com/nwg-piotr/autotiling")
+                    (commit (string-append "v" version))))
+              (file-name (git-file-name name version))
+              (sha256
+               (base32
+                "1hjlvg7095s322gb43r9g7mqlsy3pj13l827jpnbn5x0918rq9rr"))))
+    (build-system python-build-system)
+    (arguments (list #:tests? #f))      ;no tests
+    (native-inputs (list python-wheel))
+    (propagated-inputs (list python-i3ipc))
+    (home-page "https://github.com/nwg-piotr/autotiling")
+    (synopsis "Automatically tile windows in i3 and Sway")
+    (description
+     "Script for Sway and i3 to automatically switch the horizontal/vertical
+ window split orientation.")
+    (license license:gpl3)))
--
2.36.1




^ permalink raw reply related	[flat|nested] 24+ messages in thread

* [bug#56717] [PATCH v3 0/2] gnu: Add python-i3ipc and i3-autotiling.
  2022-07-23 12:22                     ` ( via Guix-patches via
@ 2022-07-23 12:49 ` Hilton Chain via Guix-patches via
  2022-07-23 10:40   ` [bug#56717] [PATCH v2 " Hilton Chain via Guix-patches via
  0 siblings, 1 reply; 24+ messages in thread
From: Hilton Chain via Guix-patches via @ 2022-07-23 12:49 UTC (permalink / raw)
  To: (, Maxime Devos; +Cc: 56717

v2 -> v3: synopsis and description changes suggested by (

Hilton Chain (2):
  gnu: Add python-i3ipc.
  gnu: Add i3-autotiling.

 gnu/packages/python-xyz.scm | 49 +++++++++++++++++++++++++++++++++++++
 1 file changed, 49 insertions(+)


base-commit: 32a00363435ac8c1bc93ef1281b2c2afc28a8877
--
2.36.1




^ permalink raw reply	[flat|nested] 24+ messages in thread

* [bug#56717] [PATCH 2/2] gnu: Add i3-autotiling.
  2022-07-23 12:48                         ` [bug#56717] [PATCH 2/2] gnu: Add i3-autotiling Hilton Chain via Guix-patches via
@ 2022-07-23 12:56                           ` ( via Guix-patches via
  2022-07-23 12:46                             ` [bug#56717] [PATCH v4 1/2] gnu: Add python-i3ipc Hilton Chain via Guix-patches via
  0 siblings, 1 reply; 24+ messages in thread
From: ( via Guix-patches via @ 2022-07-23 12:56 UTC (permalink / raw)
  To: Hilton Chain, Maxime Devos; +Cc: 56717

On Sat Jul 23, 2022 at 1:48 PM BST, Hilton Chain wrote:
> +    (description
> +     "This script uses the python-i3ipc library to switch the layout
> +splith/splitv depending on the currently focused window dimensions.  It works on
> +both sway and i3 window managers.")
I think you should probably change this one, too. 'splith'/'splitv'
doesn't make much sense as there's no mention of sway or i3 until the
end. Also, sway -> Sway :)

    -- (




^ permalink raw reply	[flat|nested] 24+ messages in thread

* [bug#56717] [PATCH v4 0/2] gnu: Add python-i3ipc and i3-autotiling.
  2022-07-23 12:56                           ` ( via Guix-patches via
@ 2022-07-23 13:08 Hilton Chain via Guix-patches via
  2022-07-23 12:49 ` [bug#56717] [PATCH v3 " Hilton Chain via Guix-patches via
  2022-08-06 21:14 ` bug#56717: [PATCH 0/2] gnu: Add python-i3ipc and python-autotiling Ludovic Courtès
  0 siblings, 2 replies; 24+ messages in thread
From: Hilton Chain via Guix-patches via @ 2022-07-23 13:08 UTC (permalink / raw)
  To: (, Maxime Devos; +Cc: 56717

v3 -> v4: description change for i3-autotiling.

Hilton Chain (2):
  gnu: Add python-i3ipc.
  gnu: Add i3-autotiling.

 gnu/packages/python-xyz.scm | 48 +++++++++++++++++++++++++++++++++++++
 1 file changed, 48 insertions(+)


base-commit: 32a00363435ac8c1bc93ef1281b2c2afc28a8877
--
2.36.1




^ permalink raw reply	[flat|nested] 24+ messages in thread

* bug#56717: [PATCH 0/2] gnu: Add python-i3ipc and python-autotiling.
  2022-07-23 13:08 [bug#56717] [PATCH v4 0/2] gnu: Add python-i3ipc and i3-autotiling Hilton Chain via Guix-patches via
  2022-07-23 12:49 ` [bug#56717] [PATCH v3 " Hilton Chain via Guix-patches via
@ 2022-08-06 21:14 ` Ludovic Courtès
  2022-08-06 21:14   ` [bug#56717] " ( via Guix-patches via
  1 sibling, 1 reply; 24+ messages in thread
From: Ludovic Courtès @ 2022-08-06 21:14 UTC (permalink / raw)
  To: Hilton Chain; +Cc: (, Maxime Devos, 56717-done

Hi,

Hilton Chain <hako@ultrarare.space> skribis:

>   gnu: Add python-i3ipc.
>   gnu: Add i3-autotiling.

Applied, thank you, and thanks to the reviewers!

Ludo’.




^ permalink raw reply	[flat|nested] 24+ messages in thread

* [bug#56717] [PATCH 0/2] gnu: Add python-i3ipc and python-autotiling.
  2022-08-06 21:14 ` bug#56717: [PATCH 0/2] gnu: Add python-i3ipc and python-autotiling Ludovic Courtès
@ 2022-08-06 21:14   ` ( via Guix-patches via
  0 siblings, 0 replies; 24+ messages in thread
From: ( via Guix-patches via @ 2022-08-06 21:14 UTC (permalink / raw)
  To: Ludovic Courtès, Hilton Chain; +Cc: 56717-done, Maxime Devos

On Sat Aug 6, 2022 at 10:14 PM BST, Ludovic Courtès wrote:
> Applied, thank you, and thanks to the reviewers!

Thanks Ludo! :D

    -- (




^ permalink raw reply	[flat|nested] 24+ messages in thread

end of thread, other threads:[~2022-08-06 21:15 UTC | newest]

Thread overview: 24+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-07-23 13:08 [bug#56717] [PATCH v4 0/2] gnu: Add python-i3ipc and i3-autotiling Hilton Chain via Guix-patches via
2022-07-23 12:49 ` [bug#56717] [PATCH v3 " Hilton Chain via Guix-patches via
2022-07-23 10:40   ` [bug#56717] [PATCH v2 " Hilton Chain via Guix-patches via
2022-07-23  7:00     ` [bug#56717] [PATCH 0/2] gnu: Add python-i3ipc and python-autotiling Hilton Chain via Guix-patches via
2022-07-23  6:31       ` [bug#56717] [PATCH 1/2] gnu: Add python-i3ipc Hilton Chain via Guix-patches via
2022-07-23  8:50         ` ( via Guix-patches via
2022-07-23  8:54         ` ( via Guix-patches via
2022-07-23  6:33       ` [bug#56717] [PATCH 2/2] gnu: Add python-autotiling Hilton Chain via Guix-patches via
2022-07-23  8:54         ` ( via Guix-patches via
2022-07-23 10:31           ` [bug#56717] [PATCH v2 1/2] gnu: Add python-i3ipc Hilton Chain via Guix-patches via
2022-07-23 10:31             ` [bug#56717] [PATCH v2 2/2] gnu: Add i3-autotiling Hilton Chain via Guix-patches via
2022-07-23 10:52               ` ( via Guix-patches via
2022-07-23 11:01               ` Maxime Devos
2022-07-23 11:38                 ` Hilton Chain via Guix-patches via
2022-07-23 12:17                   ` Maxime Devos
2022-07-23 12:22                     ` ( via Guix-patches via
2022-07-23 12:46                       ` [bug#56717] [PATCH 1/2] gnu: Add python-i3ipc Hilton Chain via Guix-patches via
2022-07-23 12:48                         ` [bug#56717] [PATCH 2/2] gnu: Add i3-autotiling Hilton Chain via Guix-patches via
2022-07-23 12:56                           ` ( via Guix-patches via
2022-07-23 12:46                             ` [bug#56717] [PATCH v4 1/2] gnu: Add python-i3ipc Hilton Chain via Guix-patches via
2022-07-23 12:48                               ` [bug#56717] [PATCH v4 2/2] gnu: Add i3-autotiling Hilton Chain via Guix-patches via
2022-07-23 10:48             ` [bug#56717] [PATCH v2 1/2] gnu: Add python-i3ipc ( via Guix-patches via
2022-08-06 21:14 ` bug#56717: [PATCH 0/2] gnu: Add python-i3ipc and python-autotiling Ludovic Courtès
2022-08-06 21:14   ` [bug#56717] " ( via Guix-patches via

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/guix.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.