Logs: freenode/#haskell
| 2020-09-21 09:46:54 | <merijn> | gnumonik: You can, but you're mixing levels |
| 2020-09-21 09:47:19 | <[exa]> | cheater: consider https://www.reddit.com/r/haskell/comments/7tutxa/vty_needs_your_help_supporting_windows/ |
| 2020-09-21 09:47:21 | <merijn> | gnumonik: You're creating a parser in your quotation, while what you *want* is "the Exp resembling a parser" |
| 2020-09-21 09:47:28 | <[exa]> | cheater: generally, windows does _not_ have a terminal |
| 2020-09-21 09:47:29 | <cheater> | this is how i know mirrorbird and why you've been put on ignore https://twitter.com/PLT_cheater/status/1306114709905694722 |
| 2020-09-21 09:47:59 | <cheater> | [exa]: thanks, looking! |
| 2020-09-21 09:48:22 | <mirrorbird> | cheater, yeah i hate that too |
| 2020-09-21 09:48:25 | <merijn> | cheater: gitbash is what my girlfriend uses on windows for git, seems the most workable solution |
| 2020-09-21 09:48:38 | <cheater> | merijn: thank you |
| 2020-09-21 09:48:49 | <cheater> | merijn: does she know how it compares to WSL1 or WSL2? |
| 2020-09-21 09:49:31 | <merijn> | WSL1/2 are linux emulation layers fully running linux code. gitbash is just a lightweight terminal emulator that runs bash, git and some other commandline tools |
| 2020-09-21 09:49:45 | <cheater> | right |
| 2020-09-21 09:49:50 | → | cosimone joins (~cosimone@2001:b07:ae5:db26:b248:7aff:feea:34b6) |
| 2020-09-21 09:49:51 | × | ces quits (~ces@52d3ce3c.dynamic-ip.k-net.dk) (Quit: WeeChat 2.9) |
| 2020-09-21 09:50:00 | <dminuoso> | gnumonik: Of course there is! :) |
| 2020-09-21 09:50:01 | <merijn> | Incidentally, all of GNU coreutils already support windows anyway. I used to use grep/bash/etc. in windows' Command.exe |
| 2020-09-21 09:50:07 | <cheater> | if I need a terminal to run Vty, then maybe this will be a good way to get Vty running |
| 2020-09-21 09:50:09 | <merijn> | No clue how to get git in there, though |
| 2020-09-21 09:50:20 | <merijn> | And git-bash seems to have the most convenient story for installing stuff |
| 2020-09-21 09:50:28 | <cheater> | mhm |
| 2020-09-21 09:50:50 | <gentauro> | I once saw a .cabal file that had, besides several `executable` (`executable foobar` and `executable bazqux`) it also had another `library` besides the main/default. I just don't remember the syntax to add this ad-hoc library. Anybody can help? Thx |
| 2020-09-21 09:51:39 | <gentauro> | is it `library identifier` or how is it done? |
| 2020-09-21 09:51:42 | → | heatsink joins (~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net) |
| 2020-09-21 09:51:57 | <gentauro> | I'm using `cabal 2.2` |
| 2020-09-21 09:52:05 | gentauro | that's the header of the file |
| 2020-09-21 09:52:24 | <phadej> | gentauro: https://cabal.readthedocs.io/en/3.4/cabal-package.html#library scroll down to internal library |
| 2020-09-21 09:53:07 | <gnumonik> | I'm not sure how to get an exp that resembles a parser though :-( And I tried building the AST by hand but i reach a point where I need a way to lift a 'Parser' to get it into the syntax tree and I'm lost |
| 2020-09-21 09:53:28 | hackage | floskell 0.10.5 - A flexible Haskell source code pretty printer https://hackage.haskell.org/package/floskell-0.10.5 (ecramer) |
| 2020-09-21 09:53:42 | → | mpereira joins (~mpereira@2a02:810d:f40:d96:b903:bcf4:35d5:9a35) |
| 2020-09-21 09:55:29 | × | mirrorbird quits (~psutcliff@2a00:801:44a:a00b:20c3:c64:eb15:73a2) (Ping timeout: 272 seconds) |
| 2020-09-21 09:55:47 | <gentauro> | phadej: thx. Just what I needed :) |
| 2020-09-21 09:56:00 | × | heatsink quits (~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 256 seconds) |
| 2020-09-21 09:58:15 | <gnumonik> | The only thing I can think of is rewriting a bunch of Parsec (that's what I'm using) by hand in the Haskell AST, so everything's an exp. Actually it'd probably be easier to just write some haskell to generate the text of the source code for the parsers than do that |
| 2020-09-21 09:58:40 | × | pingiun quits (~pingiun@j63019.upc-j.chello.nl) (Quit: My MacBook has gone to sleep. ZZZzzz…) |
| 2020-09-21 10:01:40 | → | Rudd0 joins (~Rudd0@185.189.115.103) |
| 2020-09-21 10:02:05 | <merijn> | gnumonik: You want [| |] for lifting stuff into Exp |
| 2020-09-21 10:02:34 | × | bahamas quits (~lucian@unaffiliated/bahamas) (Ping timeout: 272 seconds) |
| 2020-09-21 10:02:51 | <merijn> | gnumonik: "[| foo 1 >>= bar |]" says "take the code "foo 1 >>= bar" and give me the Exp of that AST |
| 2020-09-21 10:04:50 | → | polyrain joins (~polyrain@2001:8003:e501:6901:9557:35db:b11f:8e3c) |
| 2020-09-21 10:05:07 | <gnumonik> | https://gist.github.com/gnumonik/77554f3a7817495030c16dd46739fa79 is what I have (I think that's all the important stuff, hastily reconstructed, probably quite ugly) |
| 2020-09-21 10:05:13 | <boxscape> | looks like the Gcm etc. thing in constraints is intentional https://github.com/ekmett/constraints/issues/53 |
| 2020-09-21 10:07:42 | <boxscape> | ( tomsmeding, in case you're interested) |
| 2020-09-21 10:09:04 | <tomsmeding> | boxscape: I'm not sure whether that issue still applies, given that Min does seem to have a suitable implementation now |
| 2020-09-21 10:09:20 | <boxscape> | oh, huh, true |
| 2020-09-21 10:10:18 | <gnumonik> | I know how the quotation brackets work. I wish I knew more so I could explain this well. The problem, I think, is that I'm trapped in the Q monad. My function that generates parsers spits out 'Q Parser a's, so when I quote it, I *think* that it's giving me the AST for an expression that spits out the Q stuff. |
| 2020-09-21 10:11:13 | × | marek quits (~mmahut@209.250.249.245) (Changing host) |
| 2020-09-21 10:11:13 | → | marek joins (~mmahut@fedora/pyxel) |
| 2020-09-21 10:11:49 | <dminuoso> | gnumonik: Try generating a `Q Exp` instead. |
| 2020-09-21 10:12:30 | → | heatsink joins (~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net) |
| 2020-09-21 10:13:04 | <dminuoso> | gnumonik: You can either use [| ... |] like merijn suggested, or you build up that construction yourself |
| 2020-09-21 10:13:13 | × | chaosmasttter quits (~chaosmast@p200300c4a70213017ae400fffe8093b8.dip0.t-ipconnect.de) (Ping timeout: 272 seconds) |
| 2020-09-21 10:13:50 | <boxscape> | s/Gcm/Gcd, whoops |
| 2020-09-21 10:14:43 | <cheater> | has anyone got experience compiling medium large Haskell projects on Windows using WSL1 vs WSL2 if the data must be stored on the Windows file system? |
| 2020-09-21 10:15:49 | × | fweht quits (uid404746@gateway/web/irccloud.com/x-vltddeikipwkmies) (Quit: Connection closed for inactivity) |
| 2020-09-21 10:17:04 | → | v0d1ch joins (~v0d1ch@cable-178-148-120-241.dynamic.sbb.rs) |
| 2020-09-21 10:17:08 | × | heatsink quits (~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 256 seconds) |
| 2020-09-21 10:18:11 | <gnumonik> | I tried to do that and I couldn't make it work :-( If I make a parser in the Q monad I can't get it out. I can use the oxford brackets to transform any other function (or w/e) into an exp but whenever I try to quote the parser I generates I get a "No lift instance" |
| 2020-09-21 10:18:32 | <gentauro> | phadej: I like this feature with `sub-libs`. That way I can keep my main library `Safe` while all the nasty stuff needed by some of the `executables` I can move to these `sub-libs` :-) |
| 2020-09-21 10:18:53 | → | chaosmasttter joins (~chaosmast@p200300c4a70213017ae400fffe8093b8.dip0.t-ipconnect.de) |
| 2020-09-21 10:18:54 | gentauro | what's not to like :) |
| 2020-09-21 10:19:33 | × | olligobber quits (olligobber@gateway/vpn/privateinternetaccess/olligobber) (Ping timeout: 272 seconds) |
| 2020-09-21 10:21:06 | × | mmohammadi9812 quits (~mmohammad@2.178.188.114) (Quit: I quit (╯°□°)╯︵ ┻━┻) |
| 2020-09-21 10:23:15 | × | stree quits (~stree@50-108-115-67.adr01.mskg.mi.frontiernet.net) (Quit: Caught exception) |
| 2020-09-21 10:23:33 | → | stree joins (~stree@50-108-115-67.adr01.mskg.mi.frontiernet.net) |
| 2020-09-21 10:25:58 | <gnumonik> | https://gist.github.com/gnumonik/51b29cb694a8e19052f3613b8cc3fcfa that's problem I think. I can quote *other* parsers in the oxford brackets but for some reason that I don't understand the compiler never lets me quote the one that I made inside the Q monad. So I have to return a 'Q Parser'. Which is kinda useless. |
| 2020-09-21 10:27:59 | × | alp quits (~alp@2a01:e0a:58b:4920:8dbc:80e7:a786:cb13) (Remote host closed the connection) |
| 2020-09-21 10:28:06 | → | alp joins (~alp@88.126.45.36) |
| 2020-09-21 10:34:12 | × | cosimone quits (~cosimone@2001:b07:ae5:db26:b248:7aff:feea:34b6) (Quit: Quit.) |
| 2020-09-21 10:36:21 | → | bahamas joins (~lucian@unaffiliated/bahamas) |
| 2020-09-21 10:37:33 | <cheater> | glguy: hi, do you know if there is any way yet to sensibly run Vty on Windows? |
| 2020-09-21 10:37:40 | → | cosimone joins (~cosimone@2001:b07:ae5:db26:b248:7aff:feea:34b6) |
| 2020-09-21 10:40:56 | × | polyrain quits (~polyrain@2001:8003:e501:6901:9557:35db:b11f:8e3c) (Quit: My MacBook has gone to sleep. ZZZzzz…) |
| 2020-09-21 10:41:07 | × | bahamas quits (~lucian@unaffiliated/bahamas) (Ping timeout: 260 seconds) |
| 2020-09-21 10:41:10 | <tomsmeding> | cheater: what kind of trouble are you hitting? |
| 2020-09-21 10:41:49 | <cheater> | tomsmeding: Vty is said to require an ansi terminal, which windows didn't have until recently, so I don't know if Vty has been updated at all to take advantage of any of that |
| 2020-09-21 10:42:06 | <tomsmeding> | have you tried it? it might just magically work |
| 2020-09-21 10:42:25 | <cheater> | no, it takes a bunch of time to try it. i'd rather ask some people I know have used it. |
| 2020-09-21 10:42:38 | <tomsmeding> | sure :) |
| 2020-09-21 10:43:06 | × | cosimone quits (~cosimone@2001:b07:ae5:db26:b248:7aff:feea:34b6) (Quit: Quit.) |
| 2020-09-21 10:44:15 | <dminuoso> | What is the reason `cabal build foo:test:bar` requires --enable-tests (sometimes?). Why is there some mutable state requiring me to switch between enabling and disabling tests? |
| 2020-09-21 10:44:38 | <merijn> | dminuoso: It's because it affects the build plan |
| 2020-09-21 10:45:05 | <merijn> | dminuoso: tests might require different build plans for the main library and having them automatically rebuild and switch plans each time is...suboptimal |
| 2020-09-21 10:45:24 | <merijn> | Because then your code recompiles every time you switch between tests or not |
| 2020-09-21 10:45:27 | hackage | wai-extra 3.1.0 - Provides some basic WAI handlers and middleware. https://hackage.haskell.org/package/wai-extra-3.1.0 (MichaelSnoyman) |
| 2020-09-21 10:45:40 | <dminuoso> | merijn: And that is bad why? |
| 2020-09-21 10:45:47 | × | DirefulSalt quits (DirefulSal@gateway/vpn/privateinternetaccess/direfulsalt) (Remote host closed the connection) |
| 2020-09-21 10:45:48 | <merijn> | dminuoso: Just enable tests in cabal.project(.local) so they're always in the build plan |
| 2020-09-21 10:45:55 | <dminuoso> | Mm |
| 2020-09-21 10:46:07 | <merijn> | dminuoso: Because if you alternate running tests and executables you don't want your library to recompile each switch? |
| 2020-09-21 10:46:13 | → | DirefulSalt joins (DirefulSal@gateway/vpn/privateinternetaccess/direfulsalt) |
| 2020-09-21 10:46:27 | <merijn> | But not recompiling isn't safe if the build plan changes |
| 2020-09-21 10:46:44 | <merijn> | So just enable tests so the build plan always accommodates them, problem solved |
| 2020-09-21 10:48:38 | → | cosimone joins (~cosimone@2001:b07:ae5:db26:b248:7aff:feea:34b6) |
| 2020-09-21 10:48:51 | <tomsmeding> | cheater: I _think_ that because vty will indirectly use the terminfo library, which I _think_ is not present on windows, it will not work out of the box |
| 2020-09-21 10:48:56 | <tomsmeding> | but I haven't tested it either :) |
| 2020-09-21 10:49:11 | <cheater> | OK |
| 2020-09-21 10:49:13 | <dminuoso> | Fair enough. So --enable-tests essentially mixes in the build-depends from the test-suite, causing a new build plan to be generated that includes the (transitive) version bounds of the test-suite? |
| 2020-09-21 10:49:24 | <dminuoso> | And --disable-tests turns that off again? |
| 2020-09-21 10:50:00 | <tomsmeding> | cheater: I have written a library on somewhat the same level of abstraction as vty at some point, that does work on windows (https://git.tomsmeding.com/terminal-io-hs/tree/); however, it's not on hackage, and has been used for exactly one university project at some point :p |
| 2020-09-21 10:50:14 | <tomsmeding> | so I don't necessarily recommend using it, but wanted to post it for completeness regardless |
All times are in UTC.