<FromGitter>
<johnjansen> add `—no-debug` its a bug with 0.23.1
<FromGitter>
<johnjansen> thats double dash
<FromGitter>
<domgetter> oh man I just had to scroll up 10 lines to see someone else with the issue. Thanks @johnjansen
<FromGitter>
<johnjansen> it was me ;-)
rohitpaulk has quit [Ping timeout: 240 seconds]
rohitpaulk has joined #crystal-lang
<FromGitter>
<domgetter> Now I can get back to figuring out why my SDL event handling is slow
rohitpaulk has quit [Ping timeout: 255 seconds]
greengriminal has quit [Quit: Leaving]
rohitpaulk has joined #crystal-lang
dhk has joined #crystal-lang
dhk has quit [Client Quit]
rohitpaulk has quit [Ping timeout: 260 seconds]
rohitpaulk has joined #crystal-lang
rohitpaulk has quit [Ping timeout: 255 seconds]
rohitpaulk has joined #crystal-lang
rohitpaulk has quit [Ping timeout: 248 seconds]
rohitpaulk has joined #crystal-lang
_whitelogger has joined #crystal-lang
hightower2 has joined #crystal-lang
<FromGitter>
<bigDaddyS1oth> Hey all, it's been awhile. I'm on a new comfy Linux distro called Void and I'm installing Crystal from source, and I was curious if it's taken awhile for those of you who've done the same.
<FromGitter>
<bigDaddyS1oth> `make` is just taking awhile but I did give it the `-si` flags so that's probably why.
<hightower2>
Did you run it with -jX?
<hightower2>
(If not that's another reason why it's taking a while ;-)
<FromGitter>
<bigDaddyS1oth> nope just`make -si`
<FromGitter>
<bigDaddyS1oth> what do the j and X flags do?
<FromGitter>
<bigDaddyS1oth> oh j is for jobs
hightower4 has joined #crystal-lang
hightower3 has quit [Ping timeout: 268 seconds]
<Groogy>
Morning!
<Groogy>
Though I don't think giving it more threads to compile will make it faster since Crystal compiles everything into one object file right?
mark_66 has joined #crystal-lang
crack08 has joined #crystal-lang
<FromGitter>
<crisward> The standard crystal init command creates a shard.yml file with a version, it also create a `version.cr` file containing a version. I'm looking at a deploy system for our code at the moment and it seems odd to have two places to update. Should this be raised as an issue on Crystal? An obvious solution may be to load a parse shard.yml into app/version.cr at compile time so they're always the same. Thoughts?
<FromGitter>
<konovod> btw there is a shard for updating both) https://github.com/elorest/crelease but yes, I don't understand point of having version in two places too.
<FromGitter>
<crisward> @konovod Thanks for that, looks useful. Personally I think this should be part of either the shards or crystal commands. A bit like `npm version patch` and just update the yml file.
<FromGitter>
<romain1189> Does someone know if a compile-time flag can be set directly from crystal, through a macro?
<FromGitter>
<straight-shoota> I don' think so. But you could probably use a constant for this purpose.
<FromGitter>
<romain1189> Its value would depend on the result of a command executed in a subshell if the user doesn't specify the flag himself
<FromGitter>
<straight-shoota> Just assign the constant with a macro
<FromGitter>
<romain1189> Ah yes, thanks. I forgot this was possible
hightower2 has joined #crystal-lang
<FromGitter>
<bigDaddyS1oth> Oh yea so I couldn't compile Crystal. The process went for 6 hours and didn't finish. .-.
<FromGitter>
<straight-shoota> Is there a way to use a string symbol like `:"foo bar"` as a named argument? ⏎ It's possible to call a method like that with a double splat operator, but can I have it as a named argument? ⏎ ⏎ ```code paste, see link``` [https://gitter.im/crystal-lang/crystal?at=596f4a8876a757f808267425]
<FromGitter>
<straight-shoota> otherwise you're screwed if you try doublesplatting a named tuple with string keys^^
<oprypin>
why tho
<Papierkorb>
Multiple word argument names sounds like something I'd rather not have
Philpax has joined #crystal-lang
<FromGitter>
<straight-shoota> usually not, true
<crystal-gh>
[crystal] MakeNowJust opened pull request #4726: Correct to parse string interpolation with trailing newline (master...fix/crystal/4713-parse-string-interpolation-newline) https://git.io/vQjUD
<FromGitter>
<codenoid> i forget it, :( how to search with `string.includes?` with 2 / more give value
<FromGitter>
<codenoid> haha, i'll use this `myarray.any? { |x| ["val1", "val2", "val3", "val4"].include?(x) }` when still forget about the syntax
Papierkorb has quit [Ping timeout: 268 seconds]
<crystal-gh>
[crystal] straight-shoota opened pull request #4727: Add NamedTuple#update(other : NamedTuple) to merge values but keep type (master...named-tuple-update) https://git.io/vQjte
Papierkorb has joined #crystal-lang
Philpax has quit [Ping timeout: 255 seconds]
<FromGitter>
<fridgerator> @codenoid do it backwards, and with array.includes?
<FromGitter>
<fridgerator> `[array of strings].includes? the_string`
<FromGitter>
<codenoid> oh, haha,, ok ["cat","dog","fish"].includes? "i belive to my cat, i belive my cat can fly",, 👍 thanks
<FromGitter>
<straight-shoota> no, this won't work
<FromGitter>
<straight-shoota> this would return true for `["cat", "dog", "fish"].includes? "cat"`
<FromGitter>
<straight-shoota> you might wanna try using a regex: `"i belive to my cat, i belive my cat can fly".match(/cat|dog|fish/)
<FromGitter>
<codenoid> 😆 👍 ,
<FromGitter>
<codenoid> `Range(Int32, JSON::Any)#each()` , actually, my string (from JSON.parse), just have number value,
<FromGitter>
<codenoid> i've tried to use .to_i but `undefined method 'to_i'`
<FromGitter>
<MakeNowJust> I wanna become Crystal collaborator (maintainer) or join to GitHub crystal-lang org for more contributing to Crystal. Who have such a authority?
<FromGitter>
<bew> i is already a JSON::Any object I think
<FromGitter>
<bew> I just checked the ChuckNoris API you're using, you should use JSON.mapping and stuff to easily get what you want from the api's output
<oprypin>
MakeNowJust, the way this has happened so far is people who regularly and reliably contribute to the language get an invite from the core team. you probably can't just ask to be added. and you're not supposed to push commits by yourself anyway. you'd still be doing pull requests. so overall not a big deal, i would say.
<FromGitter>
<codenoid> i cant get directly from holyquote
<FromGitter>
<codenoid> LOL
<xiljin>
is it possible to get the remote/client IP address from HTTP::Server? I've looked through Context and Request but don't see anything obvious ..
<RX14>
xiljin, remote IP is exposed on the TCP socket, it's just not made it's way up to the HTTP abstraction yet
<RX14>
in addition you may also choose to trust your proxies and read the remote address from X-Forwarded-For
<RX14>
it all depends on your usecase etc.
<RX14>
it's a harder problem than it seems sometimes
<Papierkorb>
truth be told, that client information should be exposed in any case
<RX14>
yes both should be exposed
<RX14>
which i think neither are currently
<RX14>
well, not parsed
<xiljin>
@RX14, yes, especially since #1722 has been open since 2015 :)
fazibear has quit [Ping timeout: 255 seconds]
fazibear has joined #crystal-lang
<FromGitter>
<straight-shoota> In a handler you can read the header yourself but you have no information about the socket.
<FromGitter>
<straight-shoota> In a handler you can read the header yourself but you have no information about the socket.
<FromGitter>
<straight-shoota> In a handler you can read the header yourself but you have no information about the socket.
fenicks has joined #crystal-lang
<oprypin>
🤔
fazibear has quit [Ping timeout: 250 seconds]
fazibear has joined #crystal-lang
fazibear has quit [Ping timeout: 255 seconds]
<FromGitter>
<bigDaddyS1oth> Hey is there are tarball for Crystal I can download? Void doesn't have a package for Crystal (yet) and to create it from sources doesn't work (I think it tries to use OpenSSL, which Void uses LibreSSL).
<Groogy>
Eh ArchLinux compiles without OpenSSL from what I remember
<Groogy>
so you should be able to compile without openssl unless you need it?
<FromGitter>
<bigDaddyS1oth> well when you run make there's a `-noopenssl` tag and I let this computer run for 6 hours straight last night and `make` was still going.
<FromGitter>
<bigDaddyS1oth> And I have no idea why nothing was seemingly getting done with `make`
<RX14>
well wat was the output
<RX14>
was the compiler hanging?
<FromGitter>
<bigDaddyS1oth> I think so
<Groogy>
also did you have LLVM installed as well?
<FromGitter>
<bigDaddyS1oth> okay the formating is fucked up but yea
<FromGitter>
<bigDaddyS1oth> those `/home/` directories are stuff that I have and bash just says "Fuck you I'm not going to run anything in those directories. Even if the scripts are able to run"
<RX14>
you sure they chmod +x ?
<RX14>
and that there's no conflicting entries earlier in the PATH
<RX14>
and that PATH is set
<FromGitter>
<bigDaddyS1oth> yup
<FromGitter>
<bigDaddyS1oth> Checked all of that like 2 weeks ago multiple times
<jhass>
oprypin: I'm totally accepting pull requests on DeBot ;)
<FromGitter>
<bigDaddyS1oth> @RX14 I actually tried removing some of those entries in the PATH statement to see if it would fuck anything up, and it did.
<RX14>
putting it at the front
<RX14>
have you tried putting it at the front*
<FromGitter>
<bigDaddyS1oth> let me see
<FromGitter>
<johnjansen> @jhass consider it forked ;-)
<RX14>
also why's there a big space in it
<FromGitter>
<bigDaddyS1oth> By at the front you mean `/home/x/bin`
<FromGitter>
<bigDaddyS1oth> move `/home/x/bin` to the front that is
<RX14>
yes
<oprypin>
jhass, well i said previously, the functionality would need sandboxing anyway and then it ends up as ugly specific features in carc.in
<FromGitter>
<bigDaddyS1oth> doesn't seem to do anything..let me just make a script that'll echo something in `~/bin` and see if it runs
<jhass>
well, you could try a wrapper that's a script that then again runs crystal in the sandbox
<FromGitter>
<bigDaddyS1oth> @RX14 okay putting it at the front did work
<RX14>
well there's something in your path already then with the same name
<RX14>
or you typed it wrong when it was at the end