Logs on 2022-12-19 (liberachat/#xmonad)
| 00:05:26 | → | ^[ joins (~user@user//x-8473491) |
| 00:10:24 | × | LemanR quits (~LemanR@2607:fb90:54b0:6e01:9403:ba62:4ea3:9eb9) (Quit: Client closed) |
| 00:27:40 | → | Guest4 joins (~Guest4@ip68-101-166-83.sd.sd.cox.net) |
| 00:28:59 | <Guest4> | I've got a question about modifying the list of workspaces in the `XMonad.config` (not the current StackSet) |
| 00:29:35 | <Guest4> | So this lets me query the list of WorkspaceIds in the config: |
| 00:29:35 | <Guest4> | ``` |
| 00:29:36 | <Guest4> | workspacesInConfig :: X [WorkspaceId] |
| 00:29:36 | <Guest4> | workspacesInConfig = asks (XMonad.workspaces . XMonad.config) |
| 00:29:37 | <Guest4> | ``` |
| 00:30:55 | <Guest4> | What is the idiomatic analogue of this for modification? |
| 00:31:41 | <geekosaur> | you can't modify it; it's read-only |
| 00:33:03 | <geekosaur> | you can modify the workspaces in the StackSet, but you need some way to access them afterward because you can't rebind the keys that were defined using the read-only list of workspaces |
| 00:33:24 | <Guest4> | That makes sense |
| 00:33:47 | <Guest4> | related question |
| 00:34:50 | <Guest4> | well, really just a rephrasing of my question to make sure it's clear |
| 00:35:01 | <Guest4> | is there a way of essentially updating (in a normal functional way = generating a new modified value) the config with a modified list of workspaces? |
| 00:36:31 | <Guest4> | The context for asking is that I'm trying to simultaneously use `XMonad.Actions.TreeSelect` and functions that rename/add to/remove from the workspaces in the StackSet |
| 00:38:30 | <geekosaur> | do you know what the Reader monad is? |
| 00:38:33 | <Guest4> | Yes |
| 00:39:09 | × | ft quits (~ft@p4fc2a257.dip0.t-ipconnect.de) (Remote host closed the connection) |
| 00:39:42 | <Guest4> | So basically you're telling me that the relevant value I'm asking about is never meant to modified after initialization |
| 00:39:42 | <geekosaur> | the XMonad configuration is stored in a Reader, so it can be accessed but not modified. there are no tricks to get around this, and everything else assumes this so won't look for changes anyway |
| 00:39:49 | <geekosaur> | correct |
| 00:39:52 | <Guest4> | Yeah ok |
| 00:40:34 | <Guest4> | Alright |
| 00:40:54 | → | ft joins (~ft@p4fc2a257.dip0.t-ipconnect.de) |
| 00:42:06 | <Guest4> | So I'm currently trying to accomplish my goal by using `XMonad.Util.ExtensibleState` to create a `TreeZipper WorkspaceId` that essentially parallels some of the information in the `StackSet` |
| 00:42:19 | <geekosaur> | right. the list of workspaces in particular is there only for reference; the "live" version is the StackSet |
| 00:43:21 | <Guest4> | yeah - and a lot of code is written in a way that grabs information from the static, totally ordered list of workspaces from the initial config rather than the StackSet |
| 00:43:28 | <Guest4> | which I understand why |
| 00:44:29 | <Guest4> | but I've written a bunch of tweaked versions of operations for navigating/updating workspaces that update the treezipper state appropriately |
| 00:44:33 | <geekosaur> | one reason for that is it gives you the possibility for "hidden" workspaces, which for example NamedScratchpads uses to put hidden scratchpads in an "NSP" workspace |
| 00:45:19 | <Guest4> | and nevertheless I keep finding situations where there are calls that cause the current workspace to change that I didn't anticipate |
| 00:45:34 | <Guest4> | and then the TreeZipper and the StackSet end up unsynced |
| 00:45:59 | <Guest4> | (I have a keybinding to manually update the TreeZipper, but this is Not Ideal) |
| 00:46:08 | <geekosaur> | you could probably stick something to resync them in logHook |
| 00:46:24 | <Guest4> | that is exactly what I was hoping someone would say! |
| 00:48:37 | <Guest4> | I am having trouble figuring out how exactly to use logHook, however |
| 00:48:55 | <Guest4> | Like - when is whatever's in the logHook run? |
| 00:49:07 | <Guest4> | what is the type of information that is available? |
| 00:49:26 | <geekosaur> | it's the last step of XMonad.Operations.windows, which is the master function that handles all focus, workspace, etc. changes |
| 00:50:16 | <geekosaur> | it is not passed anything explicitly but it can access the StackSet (`gets windowset`) so you can see what workspace is current and adjust your TreeZipper as needed |
| 00:51:24 | <geekosaur> | since it's in X, all read-only (asks) and mutable (gets) state is available to it |
| 00:54:07 | <geekosaur> | the only restriction is that, since it's run in X.O.windows, you can't run X.O.windows from it without causing an infinite loop |
| 00:54:35 | <geekosaur> | (unless you are very careful to avoid such loop) |
| 00:55:54 | <Guest4> | that makes sense |
| 00:56:05 | <Guest4> | that's very helpful, thank you! |
| 00:58:52 | <geekosaur> | if you need a pointer to the exact state information, X is StateT XState (ReaderT XConf IO). XState and XConf are defined in XMonad.Core. |
| 01:10:09 | × | sogens quits (sogens@gateway/vpn/protonvpn/sogens) (Quit: WeeChat 3.7.1) |
| 01:10:37 | → | sogens joins (sogens@gateway/vpn/protonvpn/sogens) |
| 02:45:26 | × | sogens quits (sogens@gateway/vpn/protonvpn/sogens) (Quit: WeeChat 3.7.1) |
| 03:04:30 | × | banc quits (banc@gateway/vpn/protonvpn/banc) (Ping timeout: 268 seconds) |
| 03:10:03 | × | jao quits (~jao@cpc103048-sgyl39-2-0-cust502.18-2.cable.virginm.net) (Ping timeout: 268 seconds) |
| 03:15:16 | → | sogens joins (sogens@gateway/vpn/protonvpn/sogens) |
| 03:19:50 | × | sogens quits (sogens@gateway/vpn/protonvpn/sogens) (Client Quit) |
| 03:24:53 | → | banc joins (banc@gateway/vpn/protonvpn/banc) |
| 03:31:44 | × | td_ quits (~td@83.135.9.47) (Ping timeout: 252 seconds) |
| 03:33:30 | → | td_ joins (~td@83.135.9.40) |
| 03:47:47 | × | terrorjack quits (~terrorjac@2a01:4f8:1c1e:509a::1) (Quit: The Lounge - https://thelounge.chat) |
| 03:50:23 | → | terrorjack joins (~terrorjac@2a01:4f8:1c1e:509a::1) |
| 04:15:01 | → | sogens joins (sogens@gateway/vpn/protonvpn/sogens) |
| 04:22:14 | × | sogens quits (sogens@gateway/vpn/protonvpn/sogens) (Quit: WeeChat 3.7.1) |
| 04:23:48 | → | sogens joins (sogens@gateway/vpn/protonvpn/sogens) |
| 04:27:09 | × | sogens quits (sogens@gateway/vpn/protonvpn/sogens) (Client Quit) |
| 04:53:33 | × | Guest4 quits (~Guest4@ip68-101-166-83.sd.sd.cox.net) (Ping timeout: 260 seconds) |
| 05:08:32 | × | ectospasm quits (~ectospasm@user/ectospasm) (Ping timeout: 252 seconds) |
| 05:12:21 | → | ectospasm joins (~ectospasm@user/ectospasm) |
| 05:26:07 | → | sogens joins (sogens@gateway/vpn/protonvpn/sogens) |
| 06:09:40 | × | sogens quits (sogens@gateway/vpn/protonvpn/sogens) (Quit: WeeChat 3.7.1) |
| 06:10:02 | → | sogens joins (sogens@gateway/vpn/protonvpn/sogens) |
| 06:12:36 | × | sogens quits (sogens@gateway/vpn/protonvpn/sogens) (Client Quit) |
| 06:12:58 | → | sogens joins (sogens@gateway/vpn/protonvpn/sogens) |
| 06:36:55 | × | sogens quits (sogens@gateway/vpn/protonvpn/sogens) (Quit: WeeChat 3.7.1) |
| 06:39:37 | → | sogens joins (sogens@gateway/vpn/protonvpn/sogens) |
| 06:56:56 | × | telser quits (~quassel@user/telser) (Quit: https://quassel-irc.org - Chat comfortably. Anywhere.) |
| 06:58:38 | → | mncheck joins (~mncheck@193.224.205.254) |
| 07:00:55 | × | mncheck quits (~mncheck@193.224.205.254) (Remote host closed the connection) |
| 07:06:19 | → | mncheck joins (~mncheck@193.224.205.254) |
| 07:10:24 | → | telser joins (~quassel@user/telser) |
| 08:19:47 | → | alexiscott joins (~user@4.red-83-36-45.dynamicip.rima-tde.net) |
| 08:21:14 | × | alexiscott quits (~user@4.red-83-36-45.dynamicip.rima-tde.net) (Client Quit) |
| 08:50:53 | <xmonadtrack> | New branch created: pull/432 (6 commits) https://github.com/xmonad/xmonad/pull/432 |
| 08:54:47 | × | sogens quits (sogens@gateway/vpn/protonvpn/sogens) (Quit: WeeChat 3.7.1) |
| 09:12:58 | → | sogens joins (sogens@gateway/vpn/protonvpn/sogens) |
| 09:24:11 | → | cfricke joins (~cfricke@user/cfricke) |
| 09:26:46 | → | sogens_ joins (sogens@gateway/vpn/protonvpn/sogens) |
| 09:28:41 | × | sogens quits (sogens@gateway/vpn/protonvpn/sogens) (Ping timeout: 268 seconds) |
| 09:31:34 | <xmonadtrack> | New branch created: pull/433 (7 commits) https://github.com/xmonad/xmonad/pull/433 |
| 09:49:34 | × | xacktm quits (~xacktm@user/xacktm) (Ping timeout: 265 seconds) |
| 09:51:54 | <xmonadtrack> | New branch created: pull/434 (8 commits) https://github.com/xmonad/xmonad/pull/434 |
| 10:08:33 | × | ft quits (~ft@p4fc2a257.dip0.t-ipconnect.de) (Quit: leaving) |
| 10:27:29 | <xmonadtrack> | New branch created: pull/435 (7 commits) https://github.com/xmonad/xmonad/pull/435 |
| 10:42:04 | → | lokesh1197 joins (~Thunderbi@14.102.72.155) |
| 10:47:26 | → | xacktm joins (~xacktm@user/xacktm) |
| 10:54:45 | × | lokesh1197 quits (~Thunderbi@14.102.72.155) (Ping timeout: 260 seconds) |
| 10:55:28 | × | sogens_ quits (sogens@gateway/vpn/protonvpn/sogens) (Quit: WeeChat 3.7.1) |
| 11:00:11 | → | sogens joins (sogens@gateway/vpn/protonvpn/sogens) |
| 11:03:59 | → | lokesh1197 joins (~Thunderbi@14.102.72.155) |
| 11:08:23 | × | lokesh1197 quits (~Thunderbi@14.102.72.155) (Ping timeout: 260 seconds) |
| 11:29:24 | × | lambdabot quits (~lambdabot@haskell/bot/lambdabot) (Remote host closed the connection) |
| 11:30:43 | → | lambdabot joins (~lambdabot@haskell/bot/lambdabot) |
| 11:43:44 | <xmonadtrack> | New branch created: pull/436 (8 commits) https://github.com/xmonad/xmonad/pull/436 |
| 11:46:52 | <[Leary]> | That's probably it for tonight. These were delayed due to a couple of weaknesses I noticed while I was turning the commit messages into PRs. I probably could have forced them through in the promised time frame, but honestly I didn't have the determination ... I plan to accept my trouting with dignity. |
| 11:47:35 | <[Leary]> | There's still sister PRs for contrib and maybe another for core, but they'll have to wait a little. |
| 12:06:26 | × | sogens quits (sogens@gateway/vpn/protonvpn/sogens) (Ping timeout: 272 seconds) |
| 12:36:00 | × | xacktm quits (~xacktm@user/xacktm) (Quit: fBNC - https://bnc4free.com) |
| 12:47:11 | → | sogens joins (sogens@gateway/vpn/protonvpn/sogens) |
| 13:27:51 | → | xacktm joins (~xacktm@user/xacktm) |
| 13:35:17 | → | lokesh1197 joins (~Thunderbi@14.102.72.154) |
| 13:35:58 | → | mvk joins (~mvk@2607:fea8:5ce3:8500::6126) |
| 13:37:06 | × | mvk quits (~mvk@2607:fea8:5ce3:8500::6126) (Client Quit) |
| 13:42:24 | × | lokesh1197 quits (~Thunderbi@14.102.72.154) (Quit: lokesh1197) |
| 13:46:58 | → | lokesh1197 joins (~Thunderbi@14.102.72.154) |
| 14:07:24 | × | sogens quits (sogens@gateway/vpn/protonvpn/sogens) (Ping timeout: 272 seconds) |
| 14:29:42 | → | sogens joins (sogens@gateway/vpn/protonvpn/sogens) |
| 14:32:12 | <geekosaur> | I don't promise anyone will get to them any time soon; I have a PR waiting myself because I don't commit my own PRs nunless it's doc-only (and in that case it's usually a direct commit anyway) |
| 14:40:53 | → | rekahsoft joins (~rekahsoft@2605:8d80:6e2:a50e:e78b:13e9:40ed:3d2c) |
| 14:54:13 | <liskin> | Also it's quite heavy stuff :-) |
| 15:11:39 | × | sogens quits (sogens@gateway/vpn/protonvpn/sogens) (Ping timeout: 260 seconds) |
| 15:21:27 | geekosaur | gets around to looking (got a number of other things going on, mostly personal) |
| 15:21:32 | <geekosaur> | oh, my |
| 15:37:31 | × | cfricke quits (~cfricke@user/cfricke) (Quit: WeeChat 3.7.1) |
| 16:35:18 | × | rekahsoft quits (~rekahsoft@2605:8d80:6e2:a50e:e78b:13e9:40ed:3d2c) (Ping timeout: 260 seconds) |
| 17:16:57 | → | jao joins (~jao@cpc103048-sgyl39-2-0-cust502.18-2.cable.virginm.net) |
| 17:20:46 | × | td_ quits (~td@83.135.9.40) (Quit: waking up from the american dream ...) |
| 17:33:24 | → | td_ joins (~td@83.135.9.40) |
| 18:23:11 | Jade[m] | is now known as Jadesheit[m] |
| 18:29:53 | → | lokesh1198 joins (~Thunderbi@14.139.128.60) |
| 18:30:14 | × | lokesh1197 quits (~Thunderbi@14.102.72.154) (Ping timeout: 272 seconds) |
| 18:30:14 | lokesh1198 | is now known as lokesh1197 |
| 18:33:44 | × | koluacik quits (~koluacik@165.227.171.188) (Quit: ZNC - https://znc.in) |
| 18:34:06 | → | koluacik joins (~koluacik@165.227.171.188) |
| 18:48:36 | × | thunderrd_ quits (~thunderrd@183.182.111.182) (Ping timeout: 272 seconds) |
| 19:01:53 | → | thunderrd_ joins (~thunderrd@183.182.111.27) |
| 19:05:42 | × | lokesh1197 quits (~Thunderbi@14.139.128.60) (Ping timeout: 272 seconds) |
| 19:53:23 | → | sogens joins (sogens@gateway/vpn/protonvpn/sogens) |
| 19:55:14 | → | ft joins (~ft@p4fc2a257.dip0.t-ipconnect.de) |
| 20:03:52 | → | mvk joins (~mvk@2607:fea8:5ce3:8500::6126) |
| 20:04:07 | × | mvk quits (~mvk@2607:fea8:5ce3:8500::6126) (Client Quit) |
| 20:29:07 | × | geekosaur quits (~geekosaur@xmonad/geekosaur) (Killed (NickServ (GHOST command used by allbery_b))) |
| 20:29:07 | → | allbery_b joins (~geekosaur@xmonad/geekosaur) |
| 20:29:10 | allbery_b | is now known as geekosaur |
| 20:29:18 | × | xmonadtrack quits (~xmonadtra@xmonad/geekosaur) (Ping timeout: 272 seconds) |
| 20:50:16 | → | xmonadtrack joins (~xmonadtra@069-135-003-034.biz.spectrum.com) |
| 20:50:16 | × | xmonadtrack quits (~xmonadtra@069-135-003-034.biz.spectrum.com) (Changing host) |
| 20:50:16 | → | xmonadtrack joins (~xmonadtra@xmonad/geekosaur) |
| 20:55:49 | × | td_ quits (~td@83.135.9.40) (Ping timeout: 260 seconds) |
| 21:49:57 | → | td_ joins (~td@83.135.9.40) |
| 22:24:22 | × | jao quits (~jao@cpc103048-sgyl39-2-0-cust502.18-2.cable.virginm.net) (Ping timeout: 252 seconds) |
| 22:36:21 | → | mc47 joins (~mc47@xmonad/TheMC47) |
| 22:38:24 | × | mc47 quits (~mc47@xmonad/TheMC47) (Remote host closed the connection) |
All times are in UTC on 2022-12-19.