00:52
havenwood has quit [Remote host closed the connection]
00:53
havenwood has joined #crystal-lang
00:59
havenwood has quit [Ping timeout: 252 seconds]
01:01
havenwood has joined #crystal-lang
01:01
deansc has joined #crystal-lang
01:23
shama has quit [Quit: (╯°□°)╯︵ɐɯɐɥs]
01:38
a5i has joined #crystal-lang
01:39
deansc has quit [Remote host closed the connection]
01:41
<
a5i >
did any of you people see the pics?
01:41
<
a5i >
for Crystal's logo
01:43
<
jhass >
I think I prefer the stylized, modern arty look of the spinning thing on the homepage
01:44
<
havenwood >
<3 spinny thing
01:44
<
jhass >
should post to /r/ or something and see what happens :D
01:47
<
a5i >
but we can't use that spinny thing for everything yet
01:47
<
a5i >
mainly since it isnt supported everywhere
01:50
<
havenwood >
Having your logo be an emoji has certain upsides. :P
01:52
sadin has joined #crystal-lang
01:53
<
a5i >
does 'exit' exit the program in Crystal?
01:55
Cassyblanca has joined #crystal-lang
02:04
<
jhass >
tbh I really don't
02:04
<
jhass >
the logo is a copy of the ruby logo
02:04
<
jhass >
the first part of the byline is misleading
02:04
<
jhass >
the second part of the byline is a useless buzzword
02:04
<
havenwood >
Ruby logo is Ruby's logo. It's not "Pure Ruby." Webscale is one uhg.
02:05
<
a5i >
I can pick off a crystal logo from the internet
02:05
<
a5i >
if im allowed too :(
02:05
<
jhass >
we should post to some graphic design request board
02:05
<
jhass >
I just don't know any (sane one)
02:16
<
jhass >
is it a request board?
02:17
<
jhass >
well, rules there say a big fat NO
02:17
<
a5i >
No for free work
02:17
<
a5i >
though we want free
02:17
<
a5i >
so its not a fta No
02:22
<
DeBot >
a5i: 1e+100
02:24
<
a5i >
>> 2353465624323546 + 3523465754647656
02:24
<
DeBot >
a5i: 5876931378971202
02:26
deansc has joined #crystal-lang
02:27
<
a5i >
What's the largest f65 value in Crystal?
02:35
<
DeBot >
a5i: Error in line 3: undefined constant VERSION
02:39
<
jhass >
so I threw that $5 at that just for fun, let's see what happens :D
02:41
<
a5i >
You sent in a request?
02:42
<
jhass >
I mean it's a beer, what can go wrong ;)
02:43
<
a5i >
I hope he comes up with a kickass Crystal logo
02:58
<
crystal-gh >
crystal/master e9dd89e Ary Borenszweig: Added `toggle(bool)` method to colorize. Doing `obj.colorize.red.toggle(false)` won't output color codes
02:58
<
crystal-gh >
crystal/master 12df889 Ary Borenszweig: Added --no-color option to disable colored output. Fixes #523
03:06
<
travis-ci >
manastech/crystal#2208 (master - 12df889 : Ary Borenszweig): The build was fixed.
03:49
deansc has quit [Remote host closed the connection]
04:24
ponga has joined #crystal-lang
04:45
djellemah has left #crystal-lang ["Leaving"]
05:02
JuryBatenko has joined #crystal-lang
05:30
JuryBatenko has quit [Quit: Computer has gone to sleep.]
06:32
havenwood has quit [Remote host closed the connection]
06:53
a5i has quit [Quit: Connection closed for inactivity]
07:33
nulpunkt has joined #crystal-lang
07:38
ponga has quit [Remote host closed the connection]
08:10
ponga has joined #crystal-lang
08:48
ponga has quit [Remote host closed the connection]
08:50
ponga has joined #crystal-lang
09:09
Ven has joined #crystal-lang
09:28
Ven has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
10:00
leafybasil has quit [Remote host closed the connection]
10:03
JuryBatenko has joined #crystal-lang
10:13
ponga has quit [Remote host closed the connection]
10:13
ponga has joined #crystal-lang
10:18
leafybasil has joined #crystal-lang
10:18
leafybasil has quit [Remote host closed the connection]
10:18
leafybasil has joined #crystal-lang
10:53
a5i has joined #crystal-lang
11:17
colorisco has joined #crystal-lang
11:57
canhtak has joined #crystal-lang
11:59
<
jhass >
there's no solution method or variable
12:00
canhtak_ has joined #crystal-lang
12:00
canhtak has quit [Client Quit]
12:00
canhtak_ is now known as canhtak
12:05
<
a5i >
jhass, there actually is, but its not the part that needs mods
12:06
<
jhass >
so, what are you stuck with?
12:08
<
a5i >
Error in ./test.cr:16: undefined method 'sync=' for CFileIO
12:08
<
jhass >
so we don't have that flag
12:09
<
jhass >
you need to find out what syscalls that does and bind them
12:09
<
a5i >
is there an altnernate?
12:09
<
jhass >
the alternative is to implement it
12:13
<
a5i >
well, Idk where to start
12:15
<
jhass >
you would check what IO#sync= actually does
12:29
<
a5i >
It sets the sync mode of the file?
12:29
<
a5i >
doesnt have ot be a file
12:31
<
jhass >
"actually does" = which syscalls with what parameters it executes
12:39
<
a5i >
I can't seem to find out via google
12:40
<
jhass >
yeah, reading source is usually easier
13:01
<
jhass >
I guess you can try leaving that call out
13:06
asterite has joined #crystal-lang
13:06
<
a5i >
STDIN does not have a .each method
13:12
<
jhass >
isn't IO#each in Ruby deprecated or something?
13:14
<
asterite >
Yes, #each is ambiguous, use each_line
13:14
<
asterite >
(I mean, we didn't include it in crystal)
13:14
<
asterite >
About sync, I don't know what that is. I think Ruby always has an internal buffer for every IO
13:15
<
asterite >
"When sync mode is true, all output is immediately flushed to the underlying operating system and is not buffered by Ruby internally."
13:15
<
asterite >
Well, since we are not Ruby, that doesn't apply :-P
13:15
<
asterite >
(just kidding)
13:16
<
asterite >
Talking seriously, we don't have internal buffers so everything is immediately flushed (except for stdout, I think the OS keeps a buffer)
13:16
<
asterite >
If you want to use a buffer use BufferedIO, I think that's the programmer's responsibility
13:20
<
a5i >
in ./test.cr:19: undefined constant Process::CLOCK_MONOTONIC
13:27
<
asterite >
>> time = Time.now; sleep 0.2; Time.now - time
13:27
<
asterite >
Use Time for now
13:27
<
DeBot >
asterite: Sorry, that took too long.
13:29
<
jhass >
Time is bad for benchmarks :/
13:29
<
jhass >
and using a monotonic clock is a requirement
13:30
<
jhass >
to get it accepted into that repo
13:31
<
a5i >
could we use librt's clock_gettime via FFI ?
13:31
<
jhass >
we could just bind clock_gettime
13:32
<
jhass >
man clock_gettime
13:32
<
asterite >
There's no clock_gettime in mac
13:32
<
asterite >
jhass: "to get it accepted into that repo" -> what repo?
13:34
Ven has joined #crystal-lang
13:34
<
ytti >
i would love to see that as Time.monotonic
13:34
<
asterite >
In the docs for Process#clock_gettime it says that monotonic is only available in SUSv3 to 4, Linux 2.5.63, FreeBSD 3.0, NetBSD 2.0, OpenBSD 3.4
13:34
<
asterite >
It uses gettimeofday for mac, I think... which is what Time.new uses, so...
13:34
<
asterite >
But we can improve things in linux, I guess
13:34
<
ytti >
+ abs = mach_absolute_time();
13:34
<
ytti >
+ absolutetime_to_nanoseconds(abs, &ts);
13:34
<
ytti >
is what it uses on OSX
13:35
<
jhass >
wonder what benchmark stdlib uses
13:39
<
asterite >
Well, I guess we'll have to port Process#clock_gettime
13:41
<
a5i >
Well if you do and add it to HEAD version, then someone else with the HEAD version needs to tell him what version + the script, since I can't compile HEAD unless the next release of Crystal
13:41
<
a5i >
jhass, any word on the logo :P
13:41
Ven has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
13:42
<
asterite >
a5i: it'll take us (or somebody else?) some time to do it anyway
13:42
<
asterite >
I liked the second logo until heavenwood noticed it's an emoji :(
13:43
<
asterite >
"Crystal: simple, even in it's logo"
13:45
<
a5i >
asterite: to implement Process MONOTONIC?
13:45
<
asterite >
That, and to make a new release
13:45
<
asterite >
I also don't know if we should copy Ruby's Process#clock_gettime or do something different
13:46
<
jhass >
Process seems like a bad place
13:46
<
jhass >
could add Clock
13:47
<
jhass >
or have Time support monotonic and real times
13:47
<
jhass >
though not sure if that should be mixed with all the timezone/date stuff in the long run
13:47
<
jhass >
mh, TimeSpan perhaps?
13:48
<
jhass >
TimeSpan.measure_monotonic(&block); TimeSpan.measure_realtime(&block)
13:48
<
asterite >
Maybe Clock is good. Time represents a point in time, TimeSpan a duration, and Clock is for measuring small amounts of time, like a stopwatch
13:48
<
asterite >
I think other languages use StopWatch
13:48
<
jhass >
though that still doesn't feel like the right place to retrieve the actual value, only for a span
13:49
havenwood has joined #crystal-lang
13:50
<
asterite >
Do we also need to support all those other constants, or monotonic is enough?
13:50
<
jhass >
Clock.monotonic_now : Int64, Clock.realtime_now : Int64, Clock.measure_monotonic(&block) : TimeSpan, Clock.measure_realtime(&block)
13:51
<
jhass >
and Clock.measure(&block) to choose best available
13:51
<
jhass >
yeah, I think that could work
13:52
<
asterite >
I think in Ruby they return a float
14:01
bcardiff has joined #crystal-lang
14:14
weskinner_work has joined #crystal-lang
14:27
<
a5i >
its not asl bruh
14:27
<
saml >
can you write 3d games in crystal?
14:28
<
asterite >
saml: of course!
14:28
<
asterite >
Well, not "can", but "could"
14:29
<
asterite >
Just a proof of concept, it has a 3d cube using opengl
14:29
<
saml >
that's amazing
14:29
<
asterite >
Seems to be very outdated, though
14:31
<
asterite >
Ah, no, I didn't pull. It works, you can try it :-)
14:32
<
asterite >
You can do anything with crystal. Not sure it's turing complete, but it has C bindings
14:32
<
asterite >
C bindings > turing complete
14:39
<
weskinner_work >
I just started on a 2d platformer for crystal :P
14:40
<
weskinner_work >
with crystal*
14:40
<
asterite >
weskinner_work: 2d platformer games are my favorites
14:42
<
weskinner_work >
starting very small though to get into it. something like: jump up the platforms to get to the flag.
14:43
<
weskinner_work >
asterite: I'm with you. something about the gameplay of super mario world is just unforgettable
14:47
<
asterite >
My favorites are Rayman and Yoshi's Island
14:50
<
asterite >
Gunstar Heroes was awesome too, but that has shooting too...
14:59
<
saml >
are we ready to build a full web startup on crystal?
15:00
<
saml >
cms, db, html templating, http client, async http server, logging, image manipulation, video conversion, message passing, web sockets
15:05
<
asterite >
We have web sockets :-)
15:05
<
asterite >
We also have sqlite3 :-P
15:05
<
asterite >
We need to define a common DB API
15:05
<
asterite >
I guess everything will come, slowly but steadily
15:26
canhtak has quit [Quit: canhtak]
15:30
canhtak has joined #crystal-lang
15:30
canhtak has quit [Client Quit]
15:39
asterite has quit [Ping timeout: 246 seconds]
16:09
<
a5i >
Idk what to create in Crystal*
16:16
JuryBatenko has quit [Ping timeout: 272 seconds]
16:20
shama has joined #crystal-lang
16:28
havenwood has quit [Remote host closed the connection]
16:31
Ven has joined #crystal-lang
17:18
<
saml >
a5i, create video editor
17:19
<
a5i >
that sounds like an insane amount of code
17:19
<
saml >
create a cms (wordpress)
17:19
<
saml >
create juce.com binding
17:20
jua_ has joined #crystal-lang
17:20
<
saml >
create karaoke software
17:20
<
a5i >
I wish I was skilled enough
17:21
<
jhass >
how about an IRC client
17:21
<
saml >
noooooooooooooooooooooooooooo
17:21
<
jhass >
he could stop using irccloud!
17:21
<
saml >
a5i, think about what you're missing
17:22
<
saml >
a pretty girl in your life?
17:22
<
saml >
create a girl
17:22
<
a5i >
Thats worse...
17:22
<
saml >
create a text editor
17:22
<
jhass >
make a tool that uses markov chains to create project ideas
17:23
JuryBatenko has joined #crystal-lang
17:23
<
a5i >
If someone doesnt have a pretty girl its best they don't create one virtually
17:24
<
saml >
create a cure for loneliness and depression
17:24
<
saml >
port ruby on rails to crystal
17:25
<
jhass >
those aren't all without exclusion great ideas?
17:28
<
saml >
i give up too. i go shopping
17:55
shadeslayer has quit [Ping timeout: 246 seconds]
17:56
shadeslayer has joined #crystal-lang
18:03
asterite has joined #crystal-lang
18:04
<
asterite >
saml: I like your project ideas
18:04
<
saml >
do it by tomorrow
18:05
leafybas_ has joined #crystal-lang
18:06
leafybas_ has quit [Remote host closed the connection]
18:07
<
a5i >
asterite: How exactl can stacksort be used by Crystal?
18:08
<
asterite >
Well, right now you can't because there are no sort algorithms in crystal in stackoverflow
18:08
weskinner_work has quit [Ping timeout: 276 seconds]
18:08
<
asterite >
but at compile-time you would search for algorithms, try to compile them and if they work you would return that
18:08
Ven has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
18:09
leafybasil has quit [Ping timeout: 264 seconds]
18:09
<
a5i >
how do we integrate our sort algorithm witht he so one?
18:09
<
asterite >
a5i: do a time machine and bring missing code from the future, so we can finish crystal earlier
18:10
<
a5i >
>> return crystal.code.4.years.from_now
18:10
<
DeBot >
a5i: Sorry, that took too long.
18:11
<
a5i >
thats alot of crystal code then
18:11
<
asterite >
That's a good reply message for that code :)
18:13
<
jhass >
no idea, something must be wrong with that VPS again
18:16
weskinner_work has joined #crystal-lang
18:21
havenwood has joined #crystal-lang
18:32
ponga has quit [Remote host closed the connection]
18:40
Ven has joined #crystal-lang
18:56
<
weskinner_work >
probably not as fun as making a pretty girl but maybe more useful to others :P
18:58
<
weskinner_work >
or make your own pixelart editor :)
19:06
leafybasil has joined #crystal-lang
19:25
<
asterite >
weskinner_work: you'll use that for your game?
19:26
<
weskinner_work >
that's the plan
19:27
<
asterite >
It's XML, so it's actually a good idea to see if the XML support in the std is useful
19:28
<
weskinner_work >
I used the xml lib when I was playing around with some RSS scraping. seemed to work well
19:29
<
weskinner_work >
would like some kind of additional layer to make getting map info and tiles easier
19:30
<
weskinner_work >
jhass: 1 of the bottom 2
19:30
<
weskinner_work >
I like the one of the left b/c of the optical illusion
19:31
<
jhass >
yeah, but could be a bit distracting as a more permanent element
19:32
<
jhass >
I like the bottom right one for the most 3d-ish effect
19:32
<
weskinner_work >
the top right one grows on me the more I look at it
19:32
<
jhass >
yeah me too
19:33
<
weskinner_work >
I like the perspective. It seems high up and commanding
19:34
<
jhass >
maybe I should ask him to play with the angle a bit and putting it next to a simple Crystal text
19:34
<
jhass >
by angle I mean rotation
19:34
<
asterite >
jhass: I like the one on the bottom left
19:34
<
asterite >
like the middle part can be the base of both pyramids
19:36
<
jhass >
any suggestions I should make? Or should I just ask for the source files already and post them to the contest? :)
19:45
<
weskinner_work >
they look good to me. we could always go back and polish later
19:46
<
jhass >
yeah, definitely more than you can ask for five bucks :D
19:46
<
weskinner_work >
getting the wife's opinion. she always makes these decisions :P
20:01
<
weskinner_work >
she votes for top right as well
20:02
<
jhass >
cool, I'll take them unmodified them then
20:25
asterite has quit [Quit: Leaving.]
20:30
Ven has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
20:33
Ven has joined #crystal-lang
20:43
a5i has quit [Quit: Connection closed for inactivity]
21:04
bcardiff has quit [Quit: Leaving.]
21:14
nulpunkt has quit [Read error: Connection reset by peer]
21:14
nulpunkt has joined #crystal-lang
21:20
JuryBatenko has quit [Quit: Computer has gone to sleep.]
21:20
Ven has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
21:40
shama has quit [Quit: (╯°□°)╯︵ɐɯɐɥs]
21:54
a5i has joined #crystal-lang
21:55
<
a5i >
jhass, will it be different colors?
21:55
<
jhass >
not from this contract
21:55
<
jhass >
but I think the variants are easy enough to color
21:56
<
jhass >
not sure yet whether we should
21:56
<
jhass >
I specifically asked for something monochrome
21:56
<
a5i >
I like all except the top left
21:56
<
a5i >
Think this needs a vote, if this is the final thing he gave us
21:59
<
jhass >
Sure, I never intended it to be the only option
21:59
<
jhass >
rather to have some options/drafts from somebody skilled/professional
21:59
<
a5i >
how much will he give just for $5 ?
21:59
<
jhass >
I should get the source files for the things on the screen
22:03
<
jhass >
sure, there's lots of room for experimentation
22:03
<
jhass >
I think those provide a nice base though
22:04
<
a5i >
so is the contract with that guy finished? or is he still providing some more
22:04
<
jhass >
and as said, I should get the source files, so swapping out colors should hopefully be easy
22:05
<
jhass >
heh, it's just $5, let's not ask too much ;)
22:07
<
a5i >
tbh its between the top or bottom right
22:07
<
a5i >
the top one integrates more with the spinny thing
22:14
<
weskinner_work >
alright guys, time to talk about the elephant in the room, when are we writing an OS kernel in crystal?...
22:16
colorisco has quit [Ping timeout: 252 seconds]
22:18
<
jhass >
1) rip out libgc, 2) rip out libevent 3) write code not depending on glibc
22:18
<
jhass >
well, I guess you could actually statically link in glibc
22:18
<
a5i >
They have made kernels in Nim, we can do it in Crystal
22:23
k2b6s9j has joined #crystal-lang
22:30
havenwood has quit [Remote host closed the connection]
22:34
weskinner_work has quit [Quit: weskinner_work]
22:44
<
k2b6s9j >
Could someone give me an example of a good Hash?
22:44
<
k2b6s9j >
I need a good example for the Atom grammar I'm working on.
22:48
<
k2b6s9j >
Okay, so Crystal is supporting both Symbol and String keys?
22:49
<
jhass >
any object can be a key
22:49
<
jhass >
and in theory you can mix them all
22:49
<
jhass >
>> {foo: 1, :bar => 2, "baz" => 3, Object.new => 4}
22:49
<
DeBot >
jhass: Error in line 3: can't instantiate abstract class Class
22:50
<
jhass >
hah, I broke it :P
22:50
<
jhass >
>> {foo: 1, :bar => 2, "baz" => 3, {1.0 => 2} => 4}
22:50
<
DeBot >
jhass: {:foo => 1, :bar => 2, "baz" => 3, {1 => 2} => 4}
22:50
<
k2b6s9j >
Beautiful. Thank makes Hash syntax easy to cover.
22:51
<
jhass >
>> {"foo": "bar"}
22:51
<
DeBot >
jhass: {"foo" => "bar"}
22:51
<
jhass >
that one I forgot ;)
23:13
jua_ has quit [Quit: Vision[0.9.7-H-20140108]: i've been blurred!]
23:31
havenwood has joined #crystal-lang
23:37
<
a5i >
Okay lets say this is what I get from a json map
23:38
<
a5i >
how do I only access @text ?
23:44
k2b6s9j has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
23:46
<
a5i >
JSON.parse doesnt seem to work