ChanServ changed the topic of #crystal-lang to: The Crystal programming language | http://crystal-lang.org | Crystal 0.23.1 | Fund Crystal's development: http://is.gd/X7PRtI | GH: https://github.com/crystal-lang/crystal | Docs: http://crystal-lang.org/docs/ | API: http://crystal-lang.org/api/ | Gitter: https://gitter.im/crystal-lang/crystal
maxpowa has quit [Ping timeout: 255 seconds]
aroaminggeek[awa has quit [Ping timeout: 255 seconds]
hightower3 has joined #crystal-lang
sz0 has quit [Quit: Connection closed for inactivity]
aroaminggeek has joined #crystal-lang
hightower2 has quit [Ping timeout: 255 seconds]
aroaminggeek is now known as aroaminggeek[awa
maxpowa has joined #crystal-lang
alex`` has quit [Quit: WeeChat 1.9.1]
binBASH has quit [Ping timeout: 276 seconds]
binBASH has joined #crystal-lang
aroaminggeek[awa has quit [Ping timeout: 276 seconds]
DTZUZO has quit [Quit: WeeChat 1.9]
aroaminggeek has joined #crystal-lang
aroaminggeek has quit [Ping timeout: 268 seconds]
DTZUZO has joined #crystal-lang
sz0 has joined #crystal-lang
faustinoaq has quit [Quit: IRC client terminated!]
ashirase has quit [Ping timeout: 255 seconds]
ashirase has joined #crystal-lang
DTZUZO has quit [Quit: WeeChat 1.9]
DTZUZO has joined #crystal-lang
DTZUZO has quit [Quit: WeeChat 1.9]
DTZUZO has joined #crystal-lang
DTZUZO has quit [Quit: WeeChat 1.9]
aroaminggeek has joined #crystal-lang
aroaminggeek has quit [Ping timeout: 255 seconds]
illyohs has quit [Ping timeout: 255 seconds]
aroaminggeek has joined #crystal-lang
aroaminggeek is now known as aroaminggeek[awa
qard has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
qard has joined #crystal-lang
aroaminggeek[awa is now known as aroaminggeek
ashirase has quit [Ping timeout: 260 seconds]
ashirase has joined #crystal-lang
aroaminggeek is now known as aroaminggeek[awa
snsei has joined #crystal-lang
snsei has quit [Remote host closed the connection]
snsei has joined #crystal-lang
snsei has quit [Remote host closed the connection]
snsei has joined #crystal-lang
snsei has quit [Remote host closed the connection]
snsei has joined #crystal-lang
snsei has quit [Remote host closed the connection]
snsei has joined #crystal-lang
snsei has quit [Remote host closed the connection]
snsei has joined #crystal-lang
snsei has quit [Remote host closed the connection]
snsei has joined #crystal-lang
rohitpaulk has joined #crystal-lang
rohitpaulk has quit [Ping timeout: 260 seconds]
qard has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
rohitpaulk has joined #crystal-lang
wmoxam has quit [Remote host closed the connection]
<Groogy> Morning! o/
<FromGitter> <bew> Morning Groogy ;) (and others) how are you?
<FromGitter> <Lispre> fine thank, and you?
aroaminggeek[awa is now known as aroaminggeek
<FromGitter> <bew> Perfect!
alex`` has joined #crystal-lang
<FromGitter> <imonmyown> Morning :)
mark_66 has joined #crystal-lang
snsei has quit [Remote host closed the connection]
snsei has joined #crystal-lang
snsei has quit [Remote host closed the connection]
snsei has joined #crystal-lang
snsei has quit [Remote host closed the connection]
snsei has joined #crystal-lang
snsei has quit [Remote host closed the connection]
snsei has joined #crystal-lang
snsei has quit [Remote host closed the connection]
snsei has joined #crystal-lang
snsei has quit [Remote host closed the connection]
encryptedf has joined #crystal-lang
aroaminggeek has quit [Quit: Textual IRC Client: www.textualapp.com]
claudiuinberlin has joined #crystal-lang
<FromGitter> <Lispre> we crystaler alway happy
Papierkorb_ has joined #crystal-lang
<FromGitter> <sdogruyol> Hey everyone, Crystal Survey 2017 results are just published :) We're sorry for the delay https://crystal-lang.org/2017/11/03/2017-crystal-survey-2017-results.html
<FromGitter> <codenoid> my god
<FromGitter> <imonmyown> @sdogruyol 👍
<FromGitter> <Lispre> @sdogruyol That sounds great
<FromGitter> <sdogruyol> thank you
<FromGitter> <bew> Awesome 👍 thank you for taking the time to do this!
<FromGitter> <sdogruyol> This was our first survey, please give us your feedback to make it better next year :)
<FromGitter> <imonmyown> I was offline for a while so I missed it unfortunately, will try to fill it out next time
encryptedf has quit [Quit: Page closed]
dragonkh has joined #crystal-lang
<dragonkh> hey - is there a way to make the option parser print the help if the program is executed with no args?
<Groogy> @sdogruyol nice!
<FromGitter> <sdogruyol> thanks
<Papierkorb_> dragonkh: Create the option parser normally. Check if `ARGV.empty?` and if so, `puts option_parser` and exit out. Otherwise, you can use `#parse` or `#parse!` on the opt parser
<dragonkh> thanks Papierkorb - I found a similar solutoin
<dragonkh> Papierkorb - is there no for or foreach on Enumerable?
<FromGitter> <codenoid> hi, why i cant define 2 constant with one same value ⏎ ⏎ ```Cat = Dog = "value"``` [https://gitter.im/crystal-lang/crystal?at=5a266fa9ba39a53f1a20b999]
<FromGitter> <yxhuvud> Hmm, is there an easy way to unify utf8 chars that display the same?
<Papierkorb_> sdogruyol, @pie chart, it would be cool if either the legend would surround the pie parts and visually link to them through lines OR when hovering over a pie part (or a legend text), the text part would be highlighted
<FromGitter> <sdogruyol> @Papierkorb yeah..julien said the same thing but Google Forms doesn't support that..
<Papierkorb_> The ^ 1/13 v buttons don't work for me
<FromGitter> <sdogruyol> what buttons?
<Papierkorb_> The arrow buttons (..are they buttons?) under the legend
<FromGitter> <bew> took them for buttons too, no idea what it should do
<FromGitter> <sdogruyol> ah shoot...
<Papierkorb_> The hovering tooltip also puts all parts into the same info, making it hard to just hover above one to figure out what this particular part represents
<FromGitter> <sdogruyol> I should've cropped them..sorry
<Papierkorb_> Oh now I see, the whole thing's a PNG
<FromGitter> <sdogruyol> yeah, it's
<Papierkorb_> That explains it then lol
<FromGitter> <sdogruyol> unfortunately, there's no way to export those results from google forms
<FromGitter> <sdogruyol> just screenshots
<Papierkorb_> The "hover for more info" text doesn't have enough space on my screen, so it word-wraps: https://screenshots.firefox.com/I3ln9k13JWCD52b9/crystal-lang.org
<FromGitter> <sdogruyol> that's interesting
<FromGitter> <sdogruyol> what' your resolution?
<Papierkorb_> 1080p
<Papierkorb_> There's plenty space on each side
<FromGitter> <sdogruyol> I don't have any problems on Chrome
<FromGitter> <sdogruyol> let me check with FF
<FromGitter> <sdogruyol> ugh, I've got the same problem with FF Quantum
<FromGitter> <sdogruyol> probably FF issue
<Papierkorb_> Yeah one of my long-time running private web applications, which worked fine in Chrome & FF, is now buggy in Quantum too >_>
<FromGitter> <sdogruyol> They need to tweak their new layout engine
<FromGitter> <bew> I have the same (hover for more info) wrapping for some pictures (I'm on Vivaldi, it's based on Chromium so the layout engine should be good?)
<Papierkorb_> "what domain do you use crystal in?" "Gaming" found Groogy
<FromGitter> <codenoid> oh sorry, i'm dizzy, it's defferent error
<Papierkorb_> sdogruyol, thanks for the survey & analysis
<FromGitter> <bew> @yxhuvud what do you mean "unify" utf8 chars that "display the same"?
<Papierkorb_> Normalization?
<FromGitter> <yxhuvud> What papierkorb said.
<Papierkorb_> What's your goal?
<FromGitter> <yxhuvud> text mining. unify identical words to make results more accurate, as well as removing stop words.
<FromGitter> <sdogruyol> have you seen https://github.com/johnjansen/text @yxhuvud
<FromGitter> <sdogruyol> I remember @johnjansen dealing with text a lot
<Papierkorb_> Then I'd actually try to get rid of pesky unicode stuff and ASCII-fy the string
<Papierkorb_> turning ä to a also helps for simple typos as bonus
<FromGitter> <yxhuvud> @sdogruyol interesting. Could be useful if I used english :)
<Papierkorb_> If you want to follow into the normalization rabbit hole, I'd look at libicu (dunno if there are bindings for that)
rohitpaulk has quit [Ping timeout: 268 seconds]
<FromGitter> <bew> there is!
<FromGitter> <yxhuvud> oh, niiiice :D
rohitpaulk has joined #crystal-lang
rohitpaulk has quit [Ping timeout: 252 seconds]
claudiuinberlin has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
rohitpaulk has joined #crystal-lang
rohitpaulk has quit [Ping timeout: 255 seconds]
rohitpaulk has joined #crystal-lang
snsei has joined #crystal-lang
claudiuinberlin has joined #crystal-lang
snsei has quit [Ping timeout: 246 seconds]
rohitpaulk has quit [Ping timeout: 268 seconds]
snsei has joined #crystal-lang
snsei has quit [Ping timeout: 250 seconds]
<crystal-gh> [crystal] MakeNowJust opened pull request #5349: Semantic: fix to look up type var in macro called inside class (master...fix/crystal/lookup-type-var-in-macro-called-in-class) https://git.io/vbGb5
rohitpaulk has joined #crystal-lang
alex`` has quit [Quit: WeeChat 1.9.1]
alex`` has joined #crystal-lang
sz0 has quit [Quit: Connection closed for inactivity]
qard has joined #crystal-lang
qard has quit [Client Quit]
rohitpaulk has quit [Ping timeout: 250 seconds]
qard has joined #crystal-lang
rohitpaulk has joined #crystal-lang
<crystal-gh> [crystal] straight-shoota opened pull request #5350: Fix: String#gsub should use shortcut only for ascii-only string (master...jm-issue-5348) https://git.io/vbZfC
qard has quit [Quit: Textual IRC Client: www.textualapp.com]
rohitpaulk has quit [Ping timeout: 240 seconds]
<FromGitter> <unreadable> has anyone here played with sfml and shaders?
<FromGitter> <unreadable> no matter the language
snsei has joined #crystal-lang
snsei has quit [Ping timeout: 255 seconds]
snsei has joined #crystal-lang
<Papierkorb_> Could the crystallang/crystal Docker image be updated with a sensible LLVM version? I have to compile my program with --no-debug, which kinda sucks when analyzing errors
<robacarp> I'd vote for that
<RX14> I think i'll just ask to release 0.24.1 myself
<RX14> then we can solve all this
<crystal-gh> [crystal] mverzilli pushed 1 new commit to master: https://git.io/vbZsV
<crystal-gh> crystal/master 494fdcb Serdar Dogruyol: Add 0.24.0 to CHANGELOG
ashirase has quit [Ping timeout: 248 seconds]
claudiuinberlin has quit [Quit: Textual IRC Client: www.textualapp.com]
ashirase has joined #crystal-lang
<FromGitter> <fridgerator> 👍
Papierkorb_ has quit [Quit: Konversation terminated!]
snsei has quit [Remote host closed the connection]
rohitpaulk has joined #crystal-lang
snsei has joined #crystal-lang
rohitpaulk has quit [Ping timeout: 250 seconds]
<FromGitter> <RX14> test
<RX14> nice
snsei has quit [Ping timeout: 276 seconds]
<travis-ci> crystal-lang/crystal#494fdcb (master - Add 0.24.0 to CHANGELOG): The build passed. https://travis-ci.org/crystal-lang/crystal/builds/311961962
mark_66 has quit [Remote host closed the connection]
aroaminggeek has joined #crystal-lang
<oprypin> RX14, does nickname completion work?
<RX14> For FromGitter
<RX14> Yes
<RX14> Vexatos added it
<RX14> I just had to nag him
<oprypin> i mean like if you typed frid<TAB>gerator
<FromGitter> <sdogruyol> what's vexatos?
<RX14> A german
<oprypin> a person that RX14 knows , i suppose
<FromGitter> <sdogruyol> human?
<RX14> Well
<oprypin> RX14, added to what, hopefully not to upstream software :D
<Vexatos> ._.
<RX14> oprypin: its a hexchat python plug in
<RX14> And the tab completion works after @
<oprypin> oh hexchat, that could be useful to some more people then
<oprypin> thats nice
<oprypin> i just have a forked irc client :D
<RX14> It only stores people who have talked since you started the client
<oprypin> naturally
<Vexatos> I'd never dare release this code publicly, it's terrible and I add stuff to it regularly :P
<Vexatos> But it works well :I
<FromGitter> <sdogruyol> hey @Vexatos, welcome
<Vexatos> I've been here all day :I
<FromGitter> <sdogruyol> sorry, I didn't see it
<Vexatos> @sdogruyol regarding your question: I do appear to be human, but sometimes I'm not too sure
DTZUZO has joined #crystal-lang
vivus has joined #crystal-lang
linuksz has joined #crystal-lang
<FromGitter> <bew> Lol, Vexatos did you post your code somewhere ? ⏎ (github?)
<Vexatos> You mean the plugin in particular? It's currently on a secret gist
Ven`` has joined #crystal-lang
<linuksz> Is it possible to write an init process (pid 1) in Crystal?
<Papierkorb> sure it is
<FromGitter> <bew> yes I meant the plugin Vexatos
<Vexatos> I mean, you can have it if you want >_>
<Vexatos> But you're not using hexchat anyway, soo
<FromGitter> <bew> I'd like too if you don't mind (sure I don't often go on IRC, but I think it's partly because I don't have a good IRC client ^^)
<Vexatos> which version would you like? The one that displays the bot prefix as an actual hexchat prefix (like + and @) or one that makes it part of the nickname >_>
<linuksz> I haven't started coding the init program yet, I am now only learning how it works. If the parent of the process exits, it will be owned by the init. How can this be done in Crystal? Process.wait is only for the childs of the current process.
<FromGitter> <bew> Vexatos the first one
<Vexatos> so you are like RX14
<FromGitter> <bew> Thanks!
<Vexatos> @completion only works on users that have written something since the last time you opened hexchat
<Vexatos> it only stores them temporarily
<Vexatos> To add a bot, use /addbot <botname> <prefix>, e.g. /addbot FromGitter ~
<Vexatos> Should work with mods IRC bots out there
<Vexatos> At least all the ones I am aware of
<FromGitter> <bew> no prob! I also wanted to see how sth like this could be done ;)
<Vexatos> Now, back to writing about the Eötvös rule
<linuksz> How is it possible to reap child processes in a PID 1 written in Crystal?
<Papierkorb> The same that's needed when you'd write it in C
<linuksz> waitpid for -1?
Ven`` has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
<linuksz> Process.wait is only for known processes.
<Papierkorb> use the LibC functions
<linuksz> LibC.waitpid(-1) ?
<Papierkorb> No idea? init for linux is well documented though, you'll find it quickly through a web search
<Papierkorb> there are also plenty really-small "pid1" implementations around to learn from
<linuksz> Oh, I should learn more about how Crystal works with processes. :)
<linuksz> Thanks.
DTZUZO has quit [Quit: WeeChat 1.9]
faustinoaq has joined #crystal-lang
DTZUZO has joined #crystal-lang
csk157 has joined #crystal-lang
claudiuinberlin has joined #crystal-lang
vivus has left #crystal-lang ["Leaving"]
aroaminggeek is now known as aroaminggeek[awa
linuksz has quit [Quit: WeeChat 1.9.1]
aroaminggeek[awa is now known as aroaminggeek
alex`` has quit [Quit: WeeChat 1.9.1]
<FromGitter> <bew> Anyone knows how (if?) I can use local tags with the YAML parser?
DTZUZO has quit [Read error: Connection reset by peer]
DTZUZO has joined #crystal-lang
alex`` has joined #crystal-lang
csk157 has quit [Ping timeout: 248 seconds]
<FromGitter> <bew> is there an easy way to transform a string like `$HOME/bla` to `/home/user/bla` ?
<FromGitter> <bew> (using the ENV variables of course)
<FromGitter> <joselfr> Something like that `crystal eval 's="$HOME"; ENV.each { |k, v| s = s.gsub("$#{k}", v); }; puts s'`
<FromGitter> <bew> nice idea!
<oprypin> nothing else in stdlib probably. you got a nice suggestion already though
<crystal-gh> [crystal] Sija opened pull request #5352: Change properties key in YAML.mapping to reduce chance of conflict (master...pr-5180-followup) https://git.io/vbZHW
<FromGitter> <bew> ah yes, forgot about this one, thanks both of you!
<FromGitter> <bew> ah also, I got YAML local tags to work ;) so I can do `key: !expand ~/bla` and it'll give me the correct path ;)
<Papierkorb> I should really extract ConfigReader from bindgen at some point
<FromGitter> <bew> why?
<Papierkorb> Because it's useful for configuration stuff, and solves your use-case
<Papierkorb> Although using the merge key, not tags
claudiuinberlin has quit [Quit: Textual IRC Client: www.textualapp.com]
<FromGitter> <bew> how would that look like with merge key for my usecase?
<Papierkorb> `foo:\n <<: ~/foo.yml`
<FromGitter> <bew> I don't get it, can you explain what this would do exactly?
faustinoaq has quit [Read error: Connection reset by peer]
<Papierkorb> `key: !expand ~/bla` would load a YML file at ~/bla into key:, correct?
faustinoaq has joined #crystal-lang
<oprypin> "foo": {"<<": "~/foo.yml"}
<FromGitter> <bew> oh, I just want to get a path, not include another yaml file
<FromGitter> <bew> but your example is quite cool if I wanted to do that
<Papierkorb> https://github.com/Papierkorb/bindgen/#advanced-configuration-features is basically what configreader does
<oprypin> at some point you gotta think "yaml is holding me down"
<FromGitter> <bew> yeah I remember you condition system that ... insane ^^
<FromGitter> <bew> but really cool, and well suited here
<Papierkorb> oprypin: Hence me extending it lul. It's a fine markup language, I simply needed a bit more oomph without adding an actual language
<oprypin> that's what they all say
<FromGitter> <bew> @oprypin not sure what you mean by "a bug in macro splat" in https://github.com/crystal-lang/crystal/pull/5352#discussion_r155084377
<oprypin> bew, please look at the rest of the pull request
<oprypin> if you think that part is unwarranted, then the rest of it is DEFINITELY unwarranted
<oprypin> you're hypothesizing that the name of splat variable should be irrelevant in method calls
<oprypin> it also should be irrelevant in macro calls, but then why would anyone be prompted to make this PR? there has to be some problem
<FromGitter> <bew> nevermind, I didn't know this would work: `https://carc.in/#/r/37a9`
<FromGitter> <bew> wait
<RX14> honestly we should just remove the splat stuff and have the macro take a single argument which is a named tuple literal
<oprypin> probably
<RX14> the formatter formats it much nicer that way anyway lol
<oprypin> what's that, 2 extra brackets?
<RX14> yep
<RX14> ({ instead of just (
<RX14> assuming your editor has auto bracket
<oprypin> if formatter formats a call and a tuple literal differently, i view that as a bug
<RX14> which is pretty much all of them in 2017
<RX14> oprypin, ehh not so sure
<RX14> i can't remember
<RX14> like
<RX14> how it worked but i seem to remember it being a thing
<RX14> wow i'm tried
<oprypin> indeed
<Papierkorb> apparently
daemonwrangler is now known as derek-away
<Papierkorb> wat MS-DOS 4.0 supported preemptive multi tasking. But MS-DOS 4.01 doesn't. MS was never good at semver lol
<aroaminggeek> Papierkorb was MS was good at *anything* ? (Well maybe flight simulator...)
<Papierkorb> the office easter eggs were cool. until ms killed them cause they weren't srs bsns.
<FromGitter> <jwaldrip> Any idea why this would fail? ⏎ ⏎ ```code paste, see link``` [https://gitter.im/crystal-lang/crystal?at=5a271d14232e79134d1243a8]
<FromGitter> <jwaldrip> Builds on mac, does not build in docker
<Papierkorb> jwaldrip, the docker image has a faulty llvm version, pass --no-debug to crystal if you want to use it
<FromGitter> <jwaldrip> thanks
<FromGitter> <jwaldrip> wait what!? are we tagged on 0.24.0 now?
<Papierkorb> 0.24.0 has been out for two weeks. Don't use it for prod™
<RX14> a month now lol Papierkorb
<Vexatos> People are using crystal for prod? ._.
<Vexatos> And here I thought it being version 0 meant something
<RX14> Vexatos, we don't recommend it but we're grateful to the people who do it regardless
<RX14> this is an added super extra+ don't use in prod notice
<FromGitter> <crisward> I'm looking forward to v1 later in the month https://crystal-lang.org/2017/02/24/state-of-crystal-at-0.21.html 😉
<Papierkorb> I use it as caching proxy towards Stanford CoreNLP. works great.
<Papierkorb> queries whose response cane be served from the in-memory cache (Basically a `Hash(String, String)`) take about 100µs. fast enough for me ~
<FromGitter> <HCLarsen> Version 0.24.0 is out? It would be nice if you guys had something on the main page that showed the current version.
<Papierkorb> It's actually a pre release
<FromGitter> <HCLarsen> Oh, ok.
<FromGitter> <jwaldrip> ah okay... so I am just seeing the commit to the changelog...
<FromGitter> <jwaldrip> Any idea when we will see the next version?
wmoxam has joined #crystal-lang
illyohs has joined #crystal-lang
alex`` has quit [Ping timeout: 255 seconds]
<FromGitter> <jwaldrip> ...?
<FromGitter> <jwaldrip> Seems like everytime I ask that question I get crickets.
<FromGitter> <elorest> 🐊
<FromGitter> <bew> That, dear user, is a recurrent question, without any answer ...
<FromGitter> <bew> But you have a little luck, you have crickets! (I don't have crickets here, it's silent as ** :D)
<jokke> can i find out in a macro if a constant exists?
<Papierkorb> jokke: https://crystal-lang.org/api/0.23.1/Crystal/Macros/TypeNode.html#has_constant%3F%28name%3AStringLiteral%7CSymbolLiteral%29%3ABoolLiteral-instance-method
<jokke> Papierkorb: and if i search for a constant in the global namespace?
<Papierkorb> try it on Kernel or Object.
<jokke> Papierkorb: also, is constant here the same as a class?
<FromGitter> <bew> There is also https://crystal-lang.org/api/0.23.1/Crystal/Macros/Path.html#resolve%3F%3AASTNode%7CNilLiteral-instance-method
<jokke> or module
<Papierkorb> But best: Don't put stuff into the global space .. except for modules and classes
<jokke> yes, it's a module
<jokke> but i could scope them in another module
<Papierkorb> then they're already scoped.
<Papierkorb> That's not equal to the global scope.
<jokke> hm?
<Papierkorb> [00:33] <jokke> yes, it's a module
<jokke> if i have a module in the top level namespace called Foo
<Papierkorb> [00:32] <jokke> Papierkorb: and if i search for a constant in the global namespace?
<Papierkorb> What now? global or not?
<jokke> then i can check if it exists how?
<Papierkorb> "it"?
<Papierkorb> Please be clear in your intentions.
<jokke> Foo
<jokke> the module
<jokke> i know it's an unusual use case
<Papierkorb> Just try using that method for it?
<Papierkorb> If it doesn't work, it .. doesn't work. Never needed that
<FromGitter> <bew> Would be nice (and weird?) To
<FromGitter> <bew> Oups
<FromGitter> <bew> To do: `::.resolve` in a macro (:: would denotes a path), to get the global scope's TypeNode
<Papierkorb> GlobalScope instead of :: (or a different descriptive name) if at all. If someone finds a sensible use-case for it
<Papierkorb> I mean :: can't produce a collision, but it looks kinda whack by itself with a dot following it
<jokke> how come case bla; {% for foo in bar %}; when {{foo}} then ... no longer works?
<jokke> i remember it used to
<RX14> never did
<jokke> really?
<jokke> O.o
<RX14> you always needed to surround it in {%begin%} {% end %} iirc
<jokke> ahh
<jokke> thanks