IRC channel logs

2017-02-19.log

back to list of logs

<wingo>paroneayea: fash is still around :) http://wingolog.org/pub/fash.scm
<desiderantes>hello
<desiderantes>is guile-gir still a thing?
<amz3> https://www.julian.com/blog/upvote
<amz3> 3~3~https://en.m.wikipedia.org/wiki/1%25_rule_(Internet_culture)
<amz3> https://en.m.wikipedia.org/wiki/1%25_rule_(Internet_culture)
<catonano_>amz3: what do you mean to say, with these posts ?
<peterbrett>I have a daft question about (format)
<peterbrett>We have some translatable strings in our source code with substitutions
<peterbrett>We have a lint to always use explicit indices in translatable strings, to help translators reorder the substitutions if necessary
<peterbrett>In Python, we can write something like "Failed to load configuration for {1} from {2}"
<peterbrett>What's the equivalent for Guile (ice-9 format)?
<peterbrett>The closest I've found so far is "Failed to load configuration for ~0@*~s from ~1@*~s" which seems... unwieldy
<janneke>peterbrett: could you give more exact code snippets?
<janneke>are you talking about python's "bla %(xxx)s %(yyy)s" % locals () feature?
<wleslie>{} is the new-style format, %s the old one
<wleslie>"foo {0} bar {1}".format(x, y)
<janneke>wleslie: ah, okay...sorry
<janneke>wleslie: i never used the numbered version anyway, always used named+locals ()
<janneke>or % dict
<wleslie>I personally prefer % dict too
<janneke>and apparently, haven't kept up with python
<wleslie>not locals, because I work on a compiler and know how that looks when interpreted (:
<peterbrett>janneke: "Failed to load configuration for {1} from {2}".format(user, filename)
<janneke>haha
<peterbrett>(format #f "Failed to load configuration for ~0@*~s from ~1@*~s" user filename)
<janneke>peterbrett: i'm confused [possibly learing something from you]...
<janneke>why don't you use
<janneke>(format #f "Failed to load configuration for ~s from ~s" user filename)
<wleslie>because some languages need to reverse the placeholders
<wleslie>think subject-verb-object vs object-verb-subject vs subject-object-verb etc
<janneke>rright i18n'able strings
<janneke>peterbrett: i hope there is a friendlier way, esp. given that translators are often not programmers :-(
<janneke>possibly good to ask for a solution on guile-user/guile-devel list
<paroneayea>wingo: how about throwing in fash.scm into the next release? :)
<paroneayea>I know a lot of us would like having constant-time immutable hashmaps that aren't append-only
<paroneayea>(ice-9 fash) ! :)
<paroneayea>janneke: btw I think the right way for us to do i18n gettext style things in Guile would be to have a "gettextable" quasiquote and have a format procedure that appends together the string once un-quasiquoted from a list
<paroneayea>#_("Failed to load configuration for " ,_foo " from " ,_bar)
<paroneayea>then a translator could reorder things however they like
<paroneayea>mark_weaver seems to think such a thing is possible anyway :)
<amz3>catonano_: I find them interesting
<amz3>catonano_: did you look at the videos?
<jmd>Is there a tool to do coverage analysis for guile?
<wingo>paroneayea: dunno, do you use guix everywhere?
<wingo>if so a package with fash & fector would be good enough i think, dunno
<wingo>need more experience with these data structures :)
<paroneayea>wingo: I do use guix everywhere. I could package it.
<wingo>alternately include locally in your packages
<wingo>dunno
<paroneayea>wingo: I could check them into a repository on gitlab. Do you have an account there?
<paroneayea>I could add you as a collaborator
<wingo>i do have a gitlab yes
<wingo>i think it's "wingo"
<paroneayea>wingo: ok. I'll look at doing that soon.
<wingo>ACTION about to make another fibers release
<paroneayea>nice :)
<paroneayea>ACTION is working on Pubstrate
<paroneayea>trying to get in a bunch of features so I can ensure that terms don't get dropped from the ActivityStreams standard which I'll need in the long run!
<catonano_>amz3: I did !
<catonano_>admittedly I didn t understand all you did. I found cool the way you produce page components as Scheme functions. It s very similar to what happens in Hoplon
<catonano_>you need to make a package of it ;-)
<catonano_>Oh and you need to make a package of grf3 too ;-)
<catonano_>if it was available in guix and with those footages it would be easier, I think to get started with it
<catonano_>as a side note, I love the colors in your terminal, I love the transpèarency of your windows and i love your dexterity in using the Gnome workspaces :-)