NeverDie has quit [Quit: I'm off to sleep. ZZZzzz…]
zipR4ND has joined #crystal-lang
NeverDie has joined #crystal-lang
zipR4ND has quit [Ping timeout: 240 seconds]
c355E3B has quit [Quit: Connection closed for inactivity]
shama has joined #crystal-lang
Cidan is now known as zz_Cidan
zz_Cidan is now known as Cidan
Cidan is now known as zz_Cidan
mdz_ has quit [Remote host closed the connection]
Sadin has joined #crystal-lang
havenwood has joined #crystal-lang
shama has quit [Quit: (╯°□°)╯︵ɐɯɐɥs]
willl has quit [Quit: Connection closed for inactivity]
zz_Cidan is now known as Cidan
Cidan is now known as zz_Cidan
havenwood has quit [Remote host closed the connection]
bcardiff has joined #crystal-lang
mdz_ has joined #crystal-lang
mdz_ has quit [Ping timeout: 244 seconds]
bcardiff has quit [Quit: Leaving.]
datanoise has quit [Ping timeout: 264 seconds]
zz_Cidan is now known as Cidan
Cidan is now known as zz_Cidan
willl has joined #crystal-lang
datanoise has joined #crystal-lang
havenwood has joined #crystal-lang
BlaXpirit has joined #crystal-lang
Netfeed has quit [Quit: WeeChat 0.3.0]
datanoise has quit [Quit: WeeChat 1.2]
datanoise has joined #crystal-lang
datanoise has quit [Client Quit]
datanoise has joined #crystal-lang
datanoise has quit [Client Quit]
datanoise has joined #crystal-lang
unshadow has joined #crystal-lang
<unshadow>
What would it take to add exec to the top level namespace ?
<datanoise>
there is system and ` already
Ven has joined #crystal-lang
mdz_ has joined #crystal-lang
<unshadow>
well, maybe I should just explain my situation, I want to execute a file without needing to "drop down" to the shell enviroment, both system() and `` do use the shell to execute my commands, maybe exec does that too, if there a way to execute an external file without the need to drop down to shell
<unshadow>
?
<datanoise>
Process.run is the way to go then
mdz_ has quit [Ping timeout: 256 seconds]
<unshadow>
datanoise: thanks :)
<unshadow>
lets say I want to run "ls /tmp" how can I do this ? it seems that Process.run("ls", "/tmp/", STDOUT) want's something which is not string as command
<unshadow>
NM, i saw it wanted an Array so I changed it to Process.run("ls", ["/tmp/"], STDOUT) :)
Ven has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
datanoise has quit [Ping timeout: 264 seconds]
Sadin has quit [Ping timeout: 276 seconds]
Ven has joined #crystal-lang
Locke23rus has joined #crystal-lang
Ven has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
leafybasil has quit [Remote host closed the connection]
datanoise has joined #crystal-lang
havenwood has quit [Ping timeout: 252 seconds]
JBat has joined #crystal-lang
datanoise has quit [Ping timeout: 250 seconds]
leafybasil has joined #crystal-lang
NeverDie has quit [Quit: I'm off to sleep. ZZZzzz…]
Ven has joined #crystal-lang
sandelius has joined #crystal-lang
JBat has quit [Quit: Computer has gone to sleep.]
JBat has joined #crystal-lang
datanoise has joined #crystal-lang
datanoise has quit [Ping timeout: 245 seconds]
JBat has quit [Ping timeout: 255 seconds]
c355E3B has joined #crystal-lang
Ven has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
<unshadow>
Lets say i have this array, [1,1,1,0] and I want to do something like : if everything in the array is == 1 do something, else do something else
<unshadow>
how can I do that ?
<jhass>
if .all? &.==1
<jhass>
if (arr - [1]).empty?
<jhass>
if .count(1) == .size
<jhass>
stick to the first :P
<unshadow>
>> 0.size
<DeBot>
unshadow: Error in line 4: undefined method 'size' for Int32 - http://carc.in/#/r/1k6
<unshadow>
You know what would be cool to add to Crystal ? a --obfuscate flag, which will generate extra code and change the methods names and classes to numbers and will make the code less human readable to make it harder for disassamble
<jhass>
unshadow: man strip
<jhass>
though in general, if your security depends on obfuscation you're on a lost boat and IMO deserve to be owned
<unshadow>
Security should never depend on one thing, it should depend on multiple layers. obfuscation is a single layer in the whole security idea
bcardiff has joined #crystal-lang
<jhass>
if you manage to completely forget that you do obfuscation when designing your real security, I can agree
<crystal-gh>
[crystal] asterite pushed 6 new commits to master: http://git.io/vkAYy
<crystal-gh>
crystal/master d934978 Ary Borenszweig: Time: correctly compare time instances with different kinds (local, utc)
<crystal-gh>
crystal/master b57ce40 Ary Borenszweig: Allow invoking methods on abstract types (from the compiler's point of view), as these can never be instantiated.