qard has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
qard has joined #crystal-lang
faustinoaq has quit [Quit: IRC client terminated!]
hightower has joined #crystal-lang
codenoid has quit [Ping timeout: 240 seconds]
<hightower>
Are there daily snapshots/binaries available somewhere?
<FromGitter>
<kazzkiq> Is it possible to compile binaries with docker mimicking production environment?
hightower has quit [Ping timeout: 268 seconds]
<FromGitter>
<aisrael> @kazzkiq What do you mean “mimicking production environment”? Isn’t it that you build an image and that’s what you deploy to production?
<FromGitter>
<graken> Hi!, ⏎ can i reopening or inject new methods to classes ?
<FromGitter>
<bew> What are you trying to do with this module?
<FromGitter>
<bew> Include the methods in the module, in Tags?
<FromGitter>
<graken> I would like to extend a library class with modules
<FromGitter>
<bew> You can reopen the class and include a module with the extra methods you want to add to the class, or just reopen the class, and add the methods directly there
<FromGitter>
<graken> great!, thanks
cremes has joined #crystal-lang
greengriminal has joined #crystal-lang
cremes has quit [Client Quit]
qard has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
jnyw has joined #crystal-lang
greengriminal has quit [Quit: This computer has gone to sleep]
return0e has quit [Remote host closed the connection]
greengriminal has joined #crystal-lang
snsei has joined #crystal-lang
codenoid has joined #crystal-lang
cremes has joined #crystal-lang
codenoid has quit [Quit: Leaving]
cremes has quit [Quit: cremes]
greengriminal has quit [Ping timeout: 240 seconds]
greengriminal has joined #crystal-lang
snsei has quit [Remote host closed the connection]
cremes has joined #crystal-lang
snsei has joined #crystal-lang
snsei has quit [Ping timeout: 240 seconds]
snsei has joined #crystal-lang
snsei has quit [Ping timeout: 260 seconds]
snsei has joined #crystal-lang
snsei has quit [Ping timeout: 240 seconds]
qard has joined #crystal-lang
rohitpaulk has joined #crystal-lang
greengriminal has quit [Quit: This computer has gone to sleep]
rohitpaulk has quit [Remote host closed the connection]
rohitpaulk has joined #crystal-lang
rohitpaulk has quit [Ping timeout: 276 seconds]
Liothen has quit [Remote host closed the connection]
Liothen has joined #crystal-lang
rohitpaulk has joined #crystal-lang
qard has quit [Quit: qard]
Liothen has quit [Quit: The Dogmatic Law of Shadowsong]
Liothen has joined #crystal-lang
return0e has joined #crystal-lang
<FromGitter>
<iambudi> > codenoid: yes, the current GC is really bad in regards to wanting to use "a lot" of memory :-( ⏎ ⏎ @asterite will this happen any time or in what case this happend so we can avoid having this issue?
cremes_ has joined #crystal-lang
cremes has quit [Ping timeout: 268 seconds]
cremes_ is now known as cremes
alex`` has joined #crystal-lang
DTZUZO has quit [Ping timeout: 240 seconds]
alex`` has quit [Ping timeout: 256 seconds]
alex`` has joined #crystal-lang
mark_66 has joined #crystal-lang
hightower has joined #crystal-lang
jnyw has quit [Quit: WeeChat 2.0.1]
foxbot has quit [Ping timeout: 256 seconds]
jokke has quit [Ping timeout: 240 seconds]
jokke has joined #crystal-lang
jokke has quit [Ping timeout: 260 seconds]
jokke has joined #crystal-lang
jokke has quit [Ping timeout: 240 seconds]
jokke has joined #crystal-lang
DTZUZO has joined #crystal-lang
A124 has quit [Ping timeout: 256 seconds]
hightower3 has joined #crystal-lang
A124 has joined #crystal-lang
hightower2 has quit [Ping timeout: 256 seconds]
aarongodin has quit []
aarongodin has joined #crystal-lang
jokke has quit [Ping timeout: 260 seconds]
jokke has joined #crystal-lang
hightower has quit [Ping timeout: 240 seconds]
<FromGitter>
<asterite> it will happen if you allocate "a lot" of memory. I don't know the details. I think there's a GC setting that you can tweak, but in my opinion it's ridiculous, you should be able to allocate as much memory as you want
greengriminal has joined #crystal-lang
greengriminal has quit [Read error: No route to host]
greengriminal has joined #crystal-lang
rohitpaulk has quit [Ping timeout: 240 seconds]
rohitpaulk has joined #crystal-lang
greengriminal has quit [Quit: This computer has gone to sleep]
greengriminal has joined #crystal-lang
greengriminal has quit [Ping timeout: 240 seconds]
greengriminal has joined #crystal-lang
<FromGitter>
<kazzkiq> @aisrael I want to deliver a binary to a low-memory environment. But Crystal can't be easily compiled in said environment because of high memory usage. My question is, could I use docker in my development machine, so I can compile the binary and simply copy it to the low-memory production environment?
<FromGitter>
<kazzkiq> By using docker I mean using a linux image close to what I will have in my production env, etc.
<FromGitter>
<fridgerator> @kazzkiq yes you can compile a crystal using docker and copy the executable to a server
<FromGitter>
<fridgerator> its my preferred deployment method
<FromGitter>
<straight-shoota> @kazzkiq You could even cross-compile for the target architecture. Then you just need to link the compiled program on the target machine.
<FromGitter>
<j8r> @kazzkiq You can see my ugly project https://github.com/DFabric/apps-static , specially `source/dppm-static`where I do this. I'm currently working on the aarch64 and armhf target also. The binary will be *statically linked*, all is self contained - you have just to worry about the architecture :)
rohitpaulk has quit [Ping timeout: 260 seconds]
rohitpaulk has joined #crystal-lang
snsei has quit [Remote host closed the connection]
snsei has quit [Remote host closed the connection]
<FromGitter>
<bararchy> Branches are github things, you need to use git to 'clone' a branch , then build it . please search for 'clone specific github branch'
<FromGitter>
<r00ster91> oooh
<knight_>
oops, sorr
snsei has joined #crystal-lang
snsei has quit [Ping timeout: 276 seconds]
<FromGitter>
<straight-shoota> @r00ster91 only the latest Crystal release is distributed as binary package. Everything else you'll need to build from source.
dannyAAM has quit [Quit: znc.saru.moe : ZNC 1.6.2 - http://znc.in]
LastWhisper____ has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
LastWhisper____ has joined #crystal-lang
<watzon>
So if I have a class that I want to basically have all the same features as the Array class, but I don't want to extend the array class; is there a way to do that? I have a single property that's an array and I want all of the array methods to affect that property.
codenoid has joined #crystal-lang
<oprypin>
watzon, there's no good way to have *all* the methods of Array (because frankly most of them shouldnt be Array-specific) but the right approach is to include Indexable
<oprypin>
also your use case is not clear to me
<watzon>
Ahh that makes sense
<watzon>
I'm probably thinking about the problem wrong. I have a class TextBuffer which has a @buffer property that is an Array of Chars. I want to be able to use Array methods on TextBuffer and have them relayed to the @buffer. But now that I think about it that's probably more of a Ruby `method_missing` type thing and not very Crystal like
<Yxhuvud>
watzon: even in Ruby I'd go for delegation and implement whatever of Enumerable and Indexable I needed and have the necessary parts delegate to the underlying array.
<dragonkh>
hi - I've got an Array(UInt8) and I want to convert it to a hex string - I can't seem to figure it out
<FromGitter>
<bew> sth like: `arr.to_unsafe.to_slice(arr.size).hexstring` where does the array come from?
<dragonkh>
its a myhexstring.bytes
<FromGitter>
<bew> What are you trying to do exactly? Just learning how to do stuff?
<dragonkh>
I'm trying to convert a public_key between hex and bytes and and the other way
<dragonkh>
for my crypto lib
<dragonkh>
so this public_key = "d68fca4a2e96b50ea39ddeff1089d8964af82d8e8629791015ccb7816e5f3661260344ba9b6677dca2a66ca038a23494e18ed3bd1806f98e158c7c658d93e4b5"
<dragonkh>
public_key.bytes - gives me Array(UInt8) - a byte array
<dragonkh>
and from that byte array - I want to get back to that hex string
<FromGitter>
<bew> So you already have the hexstring, what's the point of converting it ?
<dragonkh>
because I need it as bytes when dealing with another lib
<dragonkh>
and also as hex for my lib
<dragonkh>
so have to be able to go between them
<dragonkh>
unfortunately your suggested code makes a different string - one half the size
<FromGitter>
<bew> Ok, then just store the hexstring in your lib and pass the bytes to the other lib?
<dragonkh>
well I'm also getting back bytes from the other lib as well - which I want to have as hex
<FromGitter>
<bew> I don't think `public_key.bytes` is what you actually want
<frojnd>
I am having this problem with *.ecr files. Crystal code is highlighted but html is not.
<FromGitter>
<bew> Yes, that's normal
<FromGitter>
<bew> How should it know that the rest of the file that is not crystal code is actually html code?
<FromGitter>
<bew> It could be anything elsr
<FromGitter>
<bew> You can try to apply both html & crystal highlighting for the file, by doing `:set filetype=crystal.html<cr>` then reload the file with `:e<cr>` but I can't promise it will look good
<FromGitter>
<bew> It's a common problem when you have multiple languages in the same file