<AlexTheLion>
What kind of magic was that ? and also thank you that was useful to know.
symm- has joined #ruby
<Ox0dea>
Ruby magic!
<Ox0dea>
ObjectSpace is a window into the interpreter's soul.
<AlexTheLion>
I just looked it up in Ruby-docs.
RobertBirnie has joined #ruby
<AlexTheLion>
How do people learn about this do I just randomly brows the docs ?
<dtordable2>
Is magical or voodoo?
colegatron has quit [Ping timeout: 256 seconds]
Gaelan has quit [Client Quit]
Gaelan has joined #ruby
diego1 has joined #ruby
diego1 has quit [Changing host]
diego1 has joined #ruby
darkxploit has quit [Ping timeout: 260 seconds]
diegoviola has quit [Ping timeout: 240 seconds]
diego1 is now known as diegoviola
gizless has joined #ruby
hxegon is now known as hxegon_AFK
<lannonbr>
Whoo. Ruby 2.3 is in the Arch Repos!
gizmore has quit [Ping timeout: 264 seconds]
chipotle has joined #ruby
gizmore has joined #ruby
<shevy>
AlexTheLion depends on what kind of basics you already know; the above examples of manipulating ObjectSpace are fairly rare, the ruby core team likes to keep some things secret; you can ask havenwood how he learned the bag of tricks, mostly by reading a lot of code
<Ox0dea>
lannonbr: Consider running [testing]. :P
rodfersou has quit [Remote host closed the connection]
<lannonbr>
It really isn't that bad to wait 6 days
<Ox0dea>
And yet here you are rejoicing.
AlphaAtom has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
gizmore|2 has joined #ruby
<Ox0dea>
In any case, I wasn't being facetious. Run [testing] to help catch bugs before they spread.
<AlexTheLion>
So asumming I know the basics, Is there a book that will go into the advance parts or rubies without going though the basics( or a video course, I am much better at listening then reading) because the tutorials I watched covered something like objectecs, mixins, etc. But never talked about rubygems, what they are ? How to use them ? etc. I ended up researching those things on
<AlexTheLion>
my own and I am just wondering fi there is anything I else missed
gizless has quit [Ping timeout: 272 seconds]
<Ox0dea>
AlexTheLion: "Passive learning" is a myth.
phredus has quit [Read error: Connection reset by peer]
darkxploit has joined #ruby
<ruby-lang857>
Hi I've been searching on the net for a while now but I can't seem to find the answer. Is there a way to take an input/argument as a binary?
<AlexTheLion>
Ox0dea agreed, But sometimes I have no idea how some people know so much
brixen_ is now known as brixen
<Gaelan>
ruby-lang857: do you mean? Convert the input to a binary string?
<Gaelan>
What do you mean?*
<Papierkorb>
AlexTheLion: "I want to do this. No idea how. Googling ..."
ascarter has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
weemsledeux has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
dmr8 has joined #ruby
<ruby-lang857>
for example I want to write a method and use it like so - get_bit(0010, 3) => 1
<ruby-lang857>
it'll get the third bit and return 1
<Ox0dea>
It seems you want to allow users of your code to supply a numeric argument using only 1s and 0s, but that won't work since `010 != 10`. The user wanted to supply the number 2 in binary, but you have no way to disambiguate.
atomical has quit [Ping timeout: 246 seconds]
<ruby-lang857>
but i want to be able to take 0010 as an input without it being converted
<Ox0dea>
ruby-lang857: Why not `0b0010`?
karapetyan has joined #ruby
<Ox0dea>
Masochist?
gizmore has joined #ruby
<ruby-lang857>
got it. so it's not do-able then
<Ox0dea>
Not in the general case, no.
atomical has joined #ruby
<AlexTheLion>
shevy I saw some of the screencasts made by Destory All Software and they were talking about mutations and other weird things (rSpec, Cucumber, etc..). also do I really have to use vim ?
<ruby-lang857>
ok got it! thank you so much. I've been stuck on this for a long time now. really appreaciate it!
<Ox0dea>
I mean, you could parse the source file, but that's crazy.
<Ox0dea>
ruby-lang857: For what it's worth, there's already a "get_bit" method.
<ruboto>
Gaelan # => /tmp/execpad-6f9ff5058de9/source-6f9ff5058de9:2: no .<digit> floating literal anymore; put 0 before ...check link for more (https://eval.in/496122)
<Gaelan>
>> 0.1[1]
<ruboto>
Gaelan # => undefined method `[]' for 0.1:Float (NoMethodError) ...check link for more (https://eval.in/496123)
<Ox0dea>
>> class String; def * n; chars.cycle.take(size * n).join end end; 'foobar' * 2.5
<shevy>
AlexTheLion you must start from the bottom, not from the top
pawnbox has quit [Ping timeout: 240 seconds]
karapetyan has quit [Remote host closed the connection]
<Ox0dea>
AlexTheLion: Listen to your heart.
<Ox0dea>
*thump thump*
gambl0re has quit []
ruby-lang857 has quit [Ping timeout: 252 seconds]
<AlexTheLion>
Ox0dea Funny my old username was AlexTheLionHeart
<AlexTheLion>
Anyway I need to figure out an easy project I can do in Ruby to fill in the gaps
Guest38 has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
<AlexTheLion>
I am thinking a web spider but don't know how complex it can get
<shevy>
something that you can use
<shevy>
something simpler
thejamespinto has quit [Remote host closed the connection]
<Gaelan>
AlexTheLion: I think a Twitter clone would be pretty simple, if you wanted to go towards the webside of things.
kalopsian has joined #ruby
symm- has quit [Quit: Leaving...]
<AlexTheLion>
Gaelan I am learning Rails too but I would like to learn Ruby as Scripting+Web not just Web
<AlexTheLion>
because I LOVE it's syntax
<AlexTheLion>
*its
weemsledeux has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
<Gaelan>
AlexTheLion: Just wail till you find out about the semantics. They’re even better!
colegatron has joined #ruby
thejamespinto has joined #ruby
curses has joined #ruby
weemsledeux has joined #ruby
bkxd has quit [Ping timeout: 276 seconds]
<Ox0dea>
AlexTheLion: How do you mean?
framling has joined #ruby
kegan_ has joined #ruby
CloCkWeRX1 has quit [Quit: Leaving.]
ibouvousaime has quit [Ping timeout: 250 seconds]
Dimik has quit [Ping timeout: 276 seconds]
bithon has left #ruby ["WeeChat 1.3"]
weemsledeux has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
<diegoviola>
happy new year
stamina has quit [Ping timeout: 276 seconds]
bkxd has joined #ruby
duckpuppy has joined #ruby
iateadonut has joined #ruby
dmr8 has quit [Read error: Connection reset by peer]
duckpuppy has quit [Ping timeout: 276 seconds]
stannard has quit [Remote host closed the connection]
aspire has quit [Quit: Leaving]
babblebre has quit [Quit: Connection closed for inactivity]
hackeron_ has quit [Ping timeout: 240 seconds]
colegatron has quit [Ping timeout: 264 seconds]
emptyflask has quit [Remote host closed the connection]
chipotle has quit [Ping timeout: 264 seconds]
hackeron has joined #ruby
DLSteve has joined #ruby
aibot has joined #ruby
build22 has quit [Remote host closed the connection]
Gaelan has quit [Quit: Gaelan]
last_staff has quit [Quit: last_staff]
bkxd has quit [Ping timeout: 256 seconds]
bkxd_ has joined #ruby
RobertBirnie has quit [Ping timeout: 246 seconds]
Gaelan has joined #ruby
colegatron has joined #ruby
QpQ4__ has joined #ruby
govg has joined #ruby
QpQ4__ has quit [Client Quit]
bkxd_ has quit [Ping timeout: 260 seconds]
yfeldblum has quit [Ping timeout: 240 seconds]
nanoz has joined #ruby
Plazma has joined #ruby
ascarter has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
jdawgaz has joined #ruby
mic_e has quit [Ping timeout: 260 seconds]
arquebus has joined #ruby
robh71 has joined #ruby
robh71 has quit [Max SendQ exceeded]
emptyflask has joined #ruby
RobertBirnie has joined #ruby
jdawgaz has quit [Client Quit]
ruid has joined #ruby
ruid has quit [Changing host]
ruid has joined #ruby
arquebus has quit [Client Quit]
jdawgaz has joined #ruby
tenseiten has joined #ruby
A124 has quit [Read error: Connection reset by peer]
tenseiten has quit [Ping timeout: 256 seconds]
dlitvak has joined #ruby
skcin7 has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
A124 has joined #ruby
yeticry has quit [Read error: Connection reset by peer]
dlitvak has quit [Ping timeout: 255 seconds]
DarkElement has joined #ruby
yeticry has joined #ruby
<DarkElement>
Looking for help with a sequel problem. Is this an alright place to ask?
<shevy>
problem is that not that many here know sequel
<shevy>
you can still try to ask
<DarkElement>
Alright
<havenwood>
DarkElement: The Sequel gem?
<DarkElement>
Problem is that i'm trying to check if there are rows in a table that match the right where condition, so I do result = listings_tbl.filter(:address => listing_addr). Except it never returns the result, just gets stuck.
<DarkElement>
Yes, the Sequel gem.
<DarkElement>
Whether the element be present or not, it doesn't find the result. My connection is fine since I can insert values, just can't do this for some reason.
<havenwood>
DarkElement: What DB?
<DarkElement>
havenwood: localhost one.
<DarkElement>
Oh
<havenwood>
DarkElement: (Curious if it's sqlite.)
<DarkElement>
MySQL
<DarkElement>
mysql2 for the adapter
<havenwood>
aha
<havenwood>
hem
<DarkElement>
It does an insert query the line before just fine
<DarkElement>
But even if i remove the insert query, nothing
bkxd has joined #ruby
<DarkElement>
Ok, progress made. I tried printing it directly instead of assigning variable, and that seemed to work
mary5030 has quit [Remote host closed the connection]
<DarkElement>
Problem solved, I was the problem
<DarkElement>
<--too stupid
weemsledeux has joined #ruby
<Ox0dea>
DarkElement: Filtering is lazy.
<Ox0dea>
Computation only when necessary!
<DarkElement>
Ox0dea: you're lazy
<DarkElement>
It's necessary.
<DarkElement>
And also, got em
<Ox0dea>
When you go to print it, yes.
<havenwood>
Laziness is a virtue.
<DarkElement>
I was going to look up how to do a select count(*) instead of * with sequel
<DarkElement>
But had to fix problem first.
DLSteve has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
<Gaelan>
Guess that would be an OK alternative. Working on (ab)using operator overloads for pretty mongo queries e.g. RubyQuery.mongo { |person| person.name == ‘Bob’ && person.age > 18 }
<Ox0dea>
These metabooks should've been called "1000 Magical Beasts and Herbs" and "Fantastic Funguys and Where to Find Them".
charliesome has quit [Read error: Connection reset by peer]
iateadonut has joined #ruby
charliesome has joined #ruby
iateadonut has quit [Client Quit]
<agent_white>
Do magical beasts eat herbs and fungi?
<Ox0dea>
Some of them even eat funguys! :'(
juddey has quit [Remote host closed the connection]
atomical has quit [Ping timeout: 246 seconds]
<agent_white>
Ox0dea: Ohhh. I see! :D
<agent_white>
I'm a bit slow. I figured there must be fun people who go to find magical beasts, and if you find them you find magical beasts. Though I still believe this to to be true.
kegan_ has quit [Ping timeout: 272 seconds]
charliesome has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
harai54 has joined #ruby
<Ox0dea>
I would certainly agree with that conclusion.
charliesome has joined #ruby
skade has joined #ruby
charliesome has quit [Client Quit]
griff has joined #ruby
<agent_white>
Hopefully there wouldn't be snaketoids who like PB and J's.
pawnbox has quit [Remote host closed the connection]
gregf has joined #ruby
pawnbox has joined #ruby
katxic has joined #ruby
katxic has left #ruby [#ruby]
karapetyan has joined #ruby
Ishido has joined #ruby
karapetyan has quit [Remote host closed the connection]
karapetyan has joined #ruby
karapetyan has quit [Remote host closed the connection]
karapetyan has joined #ruby
tenseiten has joined #ruby
Axel___ has quit [Ping timeout: 256 seconds]
jondot has joined #ruby
PedramT_ has joined #ruby
tenseiten has quit [Ping timeout: 245 seconds]
PedramT has quit [Ping timeout: 276 seconds]
tujv has quit [Quit: Leaving...]
karapetyan has quit [Remote host closed the connection]
karapetyan has joined #ruby
decoponio has joined #ruby
houhoulis has quit [Remote host closed the connection]
karapetyan has quit [Remote host closed the connection]
DarkElement has joined #ruby
<DarkElement>
How can I use one function over and over again for different threads? It seems to just end the one I started previously when making a new thread
duckpuppy has joined #ruby
<DarkElement>
Argh I have to use mutex or sync
atmosx has quit [Ping timeout: 250 seconds]
ta_ has quit [Read error: Connection reset by peer]
PedramT_ has quit [Remote host closed the connection]
duckpuppy has quit [Ping timeout: 265 seconds]
AlphaAtom has joined #ruby
pandaant has joined #ruby
ta has joined #ruby
Jackneill has joined #ruby
<[spoiler]>
DarkElement: If there's data races you need a Mutex. Otherwise, you should be able to call the same method from different threads without a problem
TheHodge has joined #ruby
Axel___ has joined #ruby
toretore has joined #ruby
grassass has joined #ruby
Pathfinder has joined #ruby
agit0 has quit [Quit: zzzZZZ….]
Xeago has quit [Remote host closed the connection]
Xeago has joined #ruby
Xeago has quit [Remote host closed the connection]
chipotle has quit [Quit: cheerio]
haraigoshi has joined #ruby
Axel___ has left #ruby [#ruby]
Axel___ has joined #ruby
haraigo has quit [Ping timeout: 246 seconds]
harai has joined #ruby
haraigoshi has quit [Ping timeout: 240 seconds]
pandaant has quit [Remote host closed the connection]
build22 has joined #ruby
stamina has joined #ruby
curses has joined #ruby
tmtwd has joined #ruby
andywojo has joined #ruby
kmckelvin has joined #ruby
curses has quit [Ping timeout: 250 seconds]
andywojo has quit [Ping timeout: 250 seconds]
govg has quit [Ping timeout: 256 seconds]
govg has joined #ruby
RegulationD has joined #ruby
robbyoconnor has joined #ruby
futilegames has joined #ruby
gccostabr has joined #ruby
RegulationD has quit [Ping timeout: 272 seconds]
grassass has quit [Read error: Connection reset by peer]
sandstrom has joined #ruby
karapetyan has joined #ruby
harai has quit [Ping timeout: 256 seconds]
dmr8 has joined #ruby
futilegames has quit [Quit: futilegames]
duckpuppy has joined #ruby
llfwf33 has joined #ruby
llfwf33 has quit [Max SendQ exceeded]
karapetyan has quit [Remote host closed the connection]
karapetyan has joined #ruby
__chris has joined #ruby
fgo has joined #ruby
devbug has quit [Read error: Connection reset by peer]
duckpuppy has quit [Ping timeout: 250 seconds]
Snowy has joined #ruby
karapetyan has quit [Remote host closed the connection]
karapetyan has joined #ruby
stamina has quit [Quit: WeeChat 1.3]
skade has joined #ruby
last_staff has joined #ruby
Snowy has quit []
karapetyan has quit [Remote host closed the connection]
TomyLobo has joined #ruby
psy_ has quit [Read error: No route to host]
Jet4Fire has joined #ruby
karapetyan has joined #ruby
pawnbox has quit [Remote host closed the connection]
karapetyan has quit [Remote host closed the connection]
fgo has quit [Quit: WeeChat 1.3]
fgo has joined #ruby
yfeldblum has quit [Ping timeout: 240 seconds]
spider-mario has joined #ruby
render___ has joined #ruby
renderfu_ has quit [Ping timeout: 260 seconds]
Xeago has joined #ruby
pawnbox has joined #ruby
bradleyprice has quit [Remote host closed the connection]
tmtwd has quit [Ping timeout: 260 seconds]
colegatron has quit [Ping timeout: 260 seconds]
asam1304 has joined #ruby
xet7 has quit [Ping timeout: 240 seconds]
last_staff has quit [Quit: last_staff]
mdw has quit [Quit: Sleeping Zzzzz]
smactive has joined #ruby
Xeago has quit [Ping timeout: 260 seconds]
neoliis has joined #ruby
nerium has joined #ruby
sdothum has joined #ruby
smactive has quit [Ping timeout: 260 seconds]
solocshaw has joined #ruby
Axel___ has quit [Ping timeout: 276 seconds]
colegatron has joined #ruby
karapetyan has joined #ruby
asam1304 has quit [Ping timeout: 252 seconds]
FooMunki has joined #ruby
Drakevr has quit [Changing host]
Drakevr has joined #ruby
tenseiten has joined #ruby
nerium has quit [Quit: nerium]
nerium has joined #ruby
karapetyan has quit [Remote host closed the connection]
karapetyan has joined #ruby
tenseiten has quit [Ping timeout: 260 seconds]
nanoz] has joined #ruby
nerium has quit [Client Quit]
yes`r has quit [Ping timeout: 265 seconds]
charliesome_ has joined #ruby
charliesome has quit [Read error: Connection reset by peer]
nanoz has quit [Ping timeout: 250 seconds]
fahio2 has joined #ruby
adgtl has joined #ruby
Rutix has joined #ruby
Rutix has quit [Changing host]
Rutix has joined #ruby
karapetyan has quit [Remote host closed the connection]
karapetyan has joined #ruby
karapetyan has quit [Remote host closed the connection]
kies has quit [Ping timeout: 240 seconds]
charliesome_ has quit [Read error: Connection reset by peer]
<adgtl>
Guys, I have input array like [20,30,40,50,60,80] and I want to group this array if elements total is, lets say 70
mary5030 has quit [Remote host closed the connection]
tvon has joined #ruby
shyn has left #ruby ["WeeChat 1.3"]
dtordable has quit [Remote host closed the connection]
dtordable has joined #ruby
jdawgaz has joined #ruby
<dtordable>
Hello ladies and gentleman
thejamespinto has quit [Ping timeout: 250 seconds]
<Ox0dea>
dtordable: Which one?
<dtordable>
You damn hobbit 0xdea :)
<shevy>
lol
Guest88361 has joined #ruby
<shevy>
that was probably the best description given so far
<shevy>
Gollum was a hobbit once
<Ox0dea>
apeiros: Which rules are they breaking?
rkazak_ has quit [Quit: Sleep.....ing....]
harai54 has joined #ruby
xet7 has joined #ruby
<dtordable>
Rules are meant to break them
* dtordable
does a gitar execution
cpup has quit [Ping timeout: 250 seconds]
harai has quit [Ping timeout: 264 seconds]
colegatron has joined #ruby
<dtordable>
Shit, rock has died...
* dtordable
cries
jdawgaz has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
rkazak has joined #ruby
xet7 has quit [Client Quit]
nerium has joined #ruby
senayar has joined #ruby
existensil has quit [Ping timeout: 272 seconds]
tenseiten has joined #ruby
cpup has joined #ruby
OdicforceSounds has joined #ruby
futilegames has joined #ruby
xet7 has joined #ruby
<OdicforceSounds>
hi all, I am trying to install vmail in a debain box and I get this error: "mkmf.rb can't find header files for ruby at /usr/lib/ruby/include/ruby.h" .. does anyone know what is going on?
nerium has quit [Client Quit]
chipotle_ is now known as chipotle
bkxd has joined #ruby
Guest88361 has quit [Remote host closed the connection]
<Ox0dea>
OdicforceSounds: You'll need the ruby-dev package.
tenseiten has quit [Ping timeout: 255 seconds]
<[spoiler]>
vmail used to be cool, but it got kinda annoying so I switched to mutt
<[spoiler]>
annoying as in unstable
<[spoiler]>
it would randomly crash and, as it's usually with such things, at the wrong time.
bkxd has quit [Ping timeout: 250 seconds]
<OdicforceSounds>
hmm.. well my experience with vmail was good.. but I don't know if something change.. I will check before moving to mutt or other email client like
pwelch has joined #ruby
vikaton has joined #ruby
<OdicforceSounds>
thank you!
fantazo has joined #ruby
pwelch has left #ruby [#ruby]
<shevy>
got mkmf to work?
SylarRuby has quit []
dfinninger has quit [Remote host closed the connection]
Guest88361 has joined #ruby
chipotle has quit [Ping timeout: 245 seconds]
pawnbox has quit [Ping timeout: 250 seconds]
sankaber has joined #ruby
dfinninger has joined #ruby
<dtordable>
[spoiler], mutt is interesting
pawnbox has joined #ruby
stannard has joined #ruby
<shevy>
hah... for a moment I read that as if you were trying to spoil a movie
<[spoiler]>
shevy, :P
<OdicforceSounds>
ok.. is getting more errors.. damn it..
<[spoiler]>
dtordable: Yeah, I love mutt. It's simple, but powerful
<shevy>
OdicforceSounds that's what usually happens!
Jet4Fire has quit [Quit: Leaving...]
<dtordable>
A bit, mixing it with vim gets great
<shevy>
OdicforceSounds what error are you getting? if it is a simple one then it could be fixed, when it comes to compiling from source, one typically has to make the debian-base sane first
rom1504 has left #ruby [#ruby]
ElFerna has quit [Quit: ElFerna]
atmosx has joined #ruby
mary5030 has joined #ruby
sergey_makagon has joined #ruby
neoliis has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
djbkd has joined #ruby
FooMunki has quit [Quit: FooMunki]
ruid has quit [Ping timeout: 260 seconds]
FooMunki has joined #ruby
<atmosx>
does ruby has any equivalent to python's fabric library?
spider-mario has quit [Read error: Connection reset by peer]
senayar has quit [Remote host closed the connection]
<ruurd>
shevy does it need to be maintained then
Guest15 has joined #ruby
diego1 has joined #ruby
andywojo has joined #ruby
Guest15 is now known as cybernaught007
PedramT_ has quit [Remote host closed the connection]
thejamespinto has quit [Ping timeout: 240 seconds]
cybernaught007 is now known as foobar123
<shevy>
ruurd dunno, I mean it's a symbiosis between users and developers. If a project is well polished, useful etc... then it is more likely to find acceptance
PedramT has joined #ruby
OdicforceSounds has left #ruby [#ruby]
bradleyprice has joined #ruby
ziyadb has quit [Quit: Connection closed for inactivity]
diego1 has quit [Changing host]
diego1 has joined #ruby
diego1 is now known as diegoviola
<shevy>
I hoped that rubocop could fix all problems related to old code. rubocop is quite good but it's like fixing up to... 80% or so of that project
<choke>
first i've heard of this rubocop -- looks pretty cool.
nerium has quit [Quit: nerium]
jondot has quit [Ping timeout: 276 seconds]
<shevy>
hehe
<shevy>
the style guide I found annoying, but the autocorrect part is really cool
senayar has joined #ruby
senayar has quit [Changing host]
senayar has joined #ruby
AlexTheLion has joined #ruby
pawnbox has quit [Remote host closed the connection]
jdawgaz has joined #ruby
pawnbox has joined #ruby
<choke>
i'm looking at the style guide right now actually... some of it is nice, some of it is just preference and is in no way ( i wouldn't think ) "community standards" ( such as spaces vs tabs )
<choke>
could also be layed out I think to be more of a "documentation" style instead of a readme
futilegames has quit [Quit: futilegames]
kadoppe has quit [Ping timeout: 240 seconds]
Kero has quit [Quit: Changing server]
houhoulis has quit []
Kero has joined #ruby
kadoppe has joined #ruby
<choke>
and some of it i just don't understand ( which makes sense when you realize i've learned ruby and rails less than a year ago )
<shevy>
I use ruby since more than a year and a lot of it I don't understand anyway
<shevy>
spaces vs tabs is really minor, we all know that spaces are the way to go :D
<choke>
most definitely! give me spaces or give me death! lol
<choke>
yeah, i've written an entire json api ( albeit it's horrible code and if i showed it you'd want to kill yourself i'm sure ) using rails... I don't think I have anything of this sort in the entire thing
Kero has joined #ruby
<shevy>
(Though I would use %w() rather than ['foo','bar' ...])
<choke>
Me personally, I take the middle one -- specifically because to me it's easier to read
<choke>
%w would be nice too -- i had to google what it meant lol
<choke>
the :: i can understand... same problem I have with PHP and systems like Drupal that condone the use of ::
<shevy>
yeah I'd go with the middle one to, only with the middle one though, I don't like the third option either, it feels to break up the reading flow compared to the middle one
sameerynho has quit [Quit: Leaving]
<shevy>
%w() is nice because you can omit all the ' and the ,
futilegames has joined #ruby
<shevy>
php namespace separator is insanity
<choke>
I hate :: specifically because it's the "Global Scope Operator" -- may as well be using register globals at that point... php i'm a big fan of the object operator ( -> )
<choke>
kinda same rules apply for that as what is listed in this ruby doc
luluapple has quit [Remote host closed the connection]
Azure has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
ruid has quit [Ping timeout: 256 seconds]
Azure has joined #ruby
luluapple has joined #ruby
greenglyph has joined #ruby
hxegon has joined #ruby
dfinninger has quit [Remote host closed the connection]
davedev24 has joined #ruby
<greenglyph>
I have kind of a noob question...
<greenglyph>
(happy new year, btw1)
davedev2_ has quit [Ping timeout: 240 seconds]
<greenglyph>
Is it better to make a bunch of smaller method calls. or pass a larger array?
<greenglyph>
i.e. form a memory/performance standpoint.
<shevy>
array should be faster
<shevy>
small methods will be easier to refactor/maintain
<greenglyph>
that lines up with my intuition, just wanted to check. thanks!
dagda1 has joined #ruby
duckpuppy has joined #ruby
greenglyph has left #ruby [#ruby]
cpup has quit [Ping timeout: 264 seconds]
andywojo has quit [Ping timeout: 255 seconds]
cpup has joined #ruby
griff has joined #ruby
m4ck3r has joined #ruby
futilegames has quit [Ping timeout: 265 seconds]
duckpuppy has quit [Ping timeout: 272 seconds]
diegoviola has quit [Ping timeout: 256 seconds]
peeja has quit [Read error: Connection reset by peer]
peeja_ has joined #ruby
Zarthus_ has joined #ruby
senayar has quit [Remote host closed the connection]
Zarthus has quit [Quit: I can't go to hell. I'm all out of vacation days.]
Zarthus_ is now known as Zarthus
mary5030 has quit [Remote host closed the connection]
existensil has joined #ruby
skade has quit [Quit: Computer has gone to sleep.]
m4ck3r has quit []
maxclocktrees has joined #ruby
AlexTheLion_ has joined #ruby
adgtl has joined #ruby
unreal_ has joined #ruby
Cohedrin has joined #ruby
diegoviola has joined #ruby
bkxd has joined #ruby
ElFerna has joined #ruby
fantazo has quit [Quit: Verlassend]
unreal has quit [Ping timeout: 272 seconds]
AlexTheLion has quit [Ping timeout: 276 seconds]
maxclocktrees has left #ruby [#ruby]
adgtl has quit [Ping timeout: 255 seconds]
CloCkWeRX1 has quit [Quit: Leaving.]
The_Phoenix has quit [Quit: Leaving.]
stannard has quit [Remote host closed the connection]
blaxter has joined #ruby
jxs_ has quit [Ping timeout: 250 seconds]
marcdel has joined #ruby
diegoviola has quit [Changing host]
diegoviola has joined #ruby
bkxd has quit [Ping timeout: 260 seconds]
griff has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
jxs_ has joined #ruby
krobzaur has quit [Ping timeout: 265 seconds]
holbach has joined #ruby
jxs_ has quit [Max SendQ exceeded]
jxs_ has joined #ruby
toretore has quit [Ping timeout: 240 seconds]
toretore has joined #ruby
sankaber has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
solocshaw has joined #ruby
diegoviola has quit [Quit: WeeChat 1.3]
ur5us has quit [Remote host closed the connection]
blackgoat has joined #ruby
agent_white has joined #ruby
thejamespinto has joined #ruby
nfk|laptop has joined #ruby
<[spoiler]>
I generally follow the style guide, except that I sometimes prefer to use `def abc()` instead of `def abc` (talking about method definition with parentheses or without them). I am conflicted about it, to be honest.
<[spoiler]>
I am happy that Crystal made it so they are mandatory in method defs
chipotle has quit [Ping timeout: 265 seconds]
<[spoiler]>
So that I don't have to be conflicted about it
codecop has quit [Remote host closed the connection]
<[spoiler]>
I don't understand how method calls/array compares, lol
<[spoiler]>
Array just passes by reference anyway, it's not like it's copied.
chipotle has joined #ruby
<[spoiler]>
oh they left anywat
<[spoiler]>
I'm too drunk for this channel. I'll get off. Have fun everyone! :*
djbkd has quit [Remote host closed the connection]
djbkd has joined #ruby
<shevy>
lol
last_staff has joined #ruby
jxs_ has quit [Ping timeout: 276 seconds]
<dtordable>
Alcohol
stannard has joined #ruby
<dtordable>
Today morning, 1st of January got drunk
<shevy>
[spoiler] oh, I am fine to omit the () when there are no arguments; strangely enough, I have no hard feelings about when you invoke a method and don't use () either, but when it comes to method definitions, with arguments, I always use (); those who omit the () have a point though, you actually save one keystroke since you can omit the last ')'; the first '(' would be equivalent to a ' ' of course so there i
<shevy>
s no save
s2013 has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
<apeiros>
Ox0dea: what? who?
<dtordable>
And today I'm getting divorced
griff has joined #ruby
gregf has quit [Quit: WeeChat 1.3]
<shevy>
happy new year apeiros!!!
<apeiros>
shevy: thanks, you too :)
ur5us has joined #ruby
djbkd has quit [Ping timeout: 260 seconds]
toretore has quit [Ping timeout: 276 seconds]
s00pcan_ has joined #ruby
holbach has quit [Quit: holbach]
yqt has joined #ruby
yfeldblum has joined #ruby
tenseiten has joined #ruby
toretore has joined #ruby
ur5us has quit [Ping timeout: 264 seconds]
Waheedi has quit [Quit: Waheedi]
Elysia has quit [Quit: WeeChat 1.4-rc1]
ur5us has joined #ruby
tenseiten has quit [Ping timeout: 265 seconds]
tmtwd has joined #ruby
thisirs has quit [Ping timeout: 240 seconds]
pawnbox has quit [Remote host closed the connection]
absolutejam has quit [Ping timeout: 240 seconds]
AlexTheLion_ has quit [Quit: Be back later ...]
skade has joined #ruby
s2013 has joined #ruby
rippa has quit [Quit: {#`%${%&`+'${`%&NO CARRIER]
absolutejam has joined #ruby
blaxter has quit [Quit: foo]
dlitvak has quit [Remote host closed the connection]
AlexTheLion_ has joined #ruby
last_staff has quit [Quit: last_staff]
last_staff has joined #ruby
griff has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
pawnbox has joined #ruby
s00pcan_ has quit [Ping timeout: 256 seconds]
ElFerna has quit [Ping timeout: 272 seconds]
sankaber has joined #ruby
Elysia has joined #ruby
toretore has quit [Ping timeout: 240 seconds]
last_staff has quit [Client Quit]
pawnbox has quit [Ping timeout: 250 seconds]
last_staff has joined #ruby
toretore has joined #ruby
ElFerna has joined #ruby
skade has quit [Quit: Computer has gone to sleep.]
phrozen77 has joined #ruby
last_staff has quit [Quit: last_staff]
diegoviola has joined #ruby
cfa6rtx8 has joined #ruby
dmmr has quit [Ping timeout: 265 seconds]
doublemalt_ has quit [Ping timeout: 246 seconds]
skade has joined #ruby
sorbo_ has quit [Remote host closed the connection]
CorySimmons has joined #ruby
CorySimmons has quit [Max SendQ exceeded]
jottr has joined #ruby
jdawgaz has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
CorySimmons has joined #ruby
s2013 has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
jdawgaz has joined #ruby
rkazak has quit [Quit: Sleep.....ing....]
agit0 has quit [Quit: zzzZZZ….]
jottr has quit [Ping timeout: 260 seconds]
chipotle has quit [Read error: Connection reset by peer]
chipotle has joined #ruby
skade has quit [Quit: Computer has gone to sleep.]
sankaber has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
rkazak_ has joined #ruby
sergey_makagon has quit [Remote host closed the connection]
smactive has joined #ruby
dlitvak has joined #ruby
PedramT has quit [Ping timeout: 245 seconds]
pawnbox has joined #ruby
skade has joined #ruby
fantazo has joined #ruby
aaronm has joined #ruby
chipotle_ has joined #ruby
smactive has quit [Ping timeout: 272 seconds]
chipotle has quit [Ping timeout: 240 seconds]
pawnbox has quit [Ping timeout: 246 seconds]
tomchapin has joined #ruby
nullwarp has joined #ruby
TheMoonMaster has joined #ruby
KineticX has quit [Remote host closed the connection]
dlitvak has quit [Read error: Connection reset by peer]
KineticX has joined #ruby
arup_r has quit []
dlitvak has joined #ruby
dlitvak has quit [Read error: Connection reset by peer]
dlitvak has joined #ruby
KineticX has quit [Read error: No route to host]
KineticX has joined #ruby
nullwarp has quit [Ping timeout: 250 seconds]
karapetyan has quit [Remote host closed the connection]
Xeago has joined #ruby
KineticX has quit [Remote host closed the connection]
CorySimmons has quit [Quit: Bye!]
TheMoonMaster has quit [Ping timeout: 246 seconds]
pawnbox has joined #ruby
s2013 has joined #ruby
<headius>
yorickpeterse: I'm confused by TCPSocket.new('localhost', 0)...it's supposed to be connecting to what port?
<headius>
using JDK APIs for this connection I get a bind error because it's attempting to connect to a remote host on port zero
<headius>
which translates to EADDR, but your test expects ECONN
ElFerna has quit [Ping timeout: 265 seconds]
pawnbox has quit [Ping timeout: 264 seconds]
<headius>
oh, heh...MRI does the same thing
ziyadb has joined #ruby
<headius>
so this spec is another red herring...MRI won't pass it on OS X either
andywojo has joined #ruby
<atmosx>
happy new year shevy apeiros dtordable and headius
<headius>
atmosx: happy new year to you as well!
symm- has joined #ruby
<dtordable>
And the rest atmosx?
<ruurd>
yes. what about us lurkers...
sorbo_ has joined #ruby
yfeldblum has quit [Ping timeout: 240 seconds]
<headius>
yorickpeterse: do you want patches to fix bad specs? I think the 0 port thing only works like that on linux
<headius>
or at least, it doesn't work the same on OS X
<adaedra>
works how?
duckpuppy has joined #ruby
<headius>
TCPSocket.new('localhost', 0) on linux raises connection refused, but on OS X it raises EADDR for address not available
<atmosx>
dtordable: I already gave my wishes to the channel earlier in the morning :-P
Ebok has quit [Quit: Internet is down or Computer is restarting. I'll be back.]
Xeago has quit [Remote host closed the connection]
jottr has joined #ruby
<dtordable>
Ah....
<headius>
the spec is intended to test that a socket raises ECONN when trying to connect with no server listening, so I think picking a different port would be better than relying on this oddity of linux connect(2)
<atmosx>
hm or maybe not, can't tell :-P happy new year to 'everyone'
andywojo has quit [Ping timeout: 240 seconds]
Rodya_ has joined #ruby
bkxd has joined #ruby
duckpuppy has quit [Ping timeout: 264 seconds]
stannard has quit [Remote host closed the connection]
Xeago has joined #ruby
akem has joined #ruby
dlitvak has quit [Read error: Connection reset by peer]
dlitvak has joined #ruby
skade has quit [Quit: Computer has gone to sleep.]
tomchapin has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
bkxd has quit [Ping timeout: 260 seconds]
andywojo has joined #ruby
dlitvak has quit [Remote host closed the connection]
dlitvak has joined #ruby
gizless has joined #ruby
neoliis has joined #ruby
neoliis has quit [Client Quit]
griff has joined #ruby
gizmore has quit [Ping timeout: 250 seconds]
dlitvak has quit [Remote host closed the connection]
marcdel has quit [Ping timeout: 260 seconds]
peeja_ has quit [Ping timeout: 272 seconds]
dwfait has joined #ruby
hacworld has joined #ruby
zenlot1 has joined #ruby
zenlot has quit [Ping timeout: 276 seconds]
<yorickpeterse>
headius: port 0 works fine
<yorickpeterse>
it means it will connect to a randomly generated port
<yorickpeterse>
at least when used in combination with bind
<headius>
yorickpeterse: ahh, ok, perhaps I'll test against that branch for now
<headius>
I'm only using the specs but making good progress
bkxd has joined #ruby
<headius>
yay, only 4 fails on TCPSocket and they're all just JDK choosing different canonicalizations of addresses
Xeago has joined #ruby
atomical has joined #ruby
Xeago has quit [Remote host closed the connection]
AwchinBruh has left #ruby ["Leaving"]
AwchinBruh has joined #ruby
atomical_ has quit [Ping timeout: 276 seconds]
stannard has joined #ruby
stannard has quit [Remote host closed the connection]
ElFerna has joined #ruby
AlphaAtom has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
yfeldblum has joined #ruby
j4cknewt has joined #ruby
tenseiten has joined #ruby
ElFerna has quit [Ping timeout: 250 seconds]
dlitvak has joined #ruby
s00pcan_ has quit [Ping timeout: 250 seconds]
ElFerna has joined #ruby
dlitvak has quit [Remote host closed the connection]
dlitvak has joined #ruby
zast has joined #ruby
andywojo has quit [Ping timeout: 276 seconds]
tenseiten has quit [Ping timeout: 260 seconds]
pawnbox has joined #ruby
s00pcan_ has joined #ruby
dlitvak has quit [Remote host closed the connection]
andywojo has joined #ruby
pawnbox has quit [Ping timeout: 245 seconds]
dlitvak has joined #ruby
dlitvak has quit [Remote host closed the connection]
jdawgaz has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
zeroDivisible has quit [Quit: WeeChat 1.3]
zeroDivisible has joined #ruby
<shevy>
RbConfig::CONFIG['host'] yields to me "i686-pc-linux-gnu". I am trying to translate some shell code to ruby
<shevy>
the shell code uses: "case $(uname -m) in i?86)" I could use "uname -m" too but I assume that this may not work on windows. Is RbConfig::CONFIG['host'] equivalent to "uname -m" though?
krobzaur has quit [Ping timeout: 250 seconds]
<bnagy>
shevy: check host_cpu instead
FernandoBasso has quit [Quit: Leaving]
<shevy>
ah
<dtordable>
I'm going to sleep
<shevy>
yep that is it, thanks bnagy!
<bnagy>
there's host_cpu and target_cpu, I am not sure offhand what the difference is
<bnagy>
might be a jruby thing?
<headius>
bnagy: running on versus built for
<headius>
on JRuby I don't think they're ever different since we're built for JVM
<bnagy>
oic like 32 bit mri on x64
jdawgaz has joined #ruby
<headius>
yeah
dlitvak has joined #ruby
s2013 has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
s2013 has joined #ruby
<bnagy>
shevy: so I guess target_cpu might be most likely to be what you want to check
<bnagy>
you're probably only checking 'not arm' or something though I guess
<headius>
yorickpeterse: not sure how I can get these to pass:
<headius>
Expected "0:0:0:0:0:0:0:1"
<headius>
to equal "::1"
<dtordable>
Local host
Waheedi has joined #ruby
Waheedi has quit [Client Quit]
<headius>
well, the specs basicall use ::1 to create sockets and then expect that to be there in sock.local_address
<headius>
but the JDK classes appear to normalize to the longer form
Helheim has quit [Ping timeout: 245 seconds]
s2013 has quit [Client Quit]
s2013 has joined #ruby
aspire has quit [Quit: Leaving]
Jammy_Work has joined #ruby
arescorpio has joined #ruby
Helheim has joined #ruby
vikaton has quit [Quit: Connection closed for inactivity]
nerium has joined #ruby
Hammy_Work has quit [Ping timeout: 250 seconds]
chipotle has quit [Ping timeout: 245 seconds]
krobzaur has joined #ruby
hxegon is now known as hxegon_AFK
firstdayonthejob has quit [Ping timeout: 276 seconds]
PedramT has joined #ruby
rgb-one has joined #ruby
Phage has left #ruby [#ruby]
<rgb-one>
I would like to slit the first page of a pdf document into a new pdf document. Any ideas?
houhoulis has quit [Remote host closed the connection]
Contigi777 has joined #ruby
s00pcan_ has quit [Ping timeout: 276 seconds]
legohead258 has joined #ruby
Mia has joined #ruby
Mia has quit [Changing host]
Mia has joined #ruby
s00pcan_ has joined #ruby
tvon_ has joined #ruby
PedramT has quit [Ping timeout: 260 seconds]
dlitvak_ has joined #ruby
jtdowney has joined #ruby
jtdowney has joined #ruby
ta_ has joined #ruby
amitchellbullard has quit [Ping timeout: 250 seconds]
arthurnn has quit [Ping timeout: 250 seconds]
im0b_ has joined #ruby
Contigi has quit [Ping timeout: 250 seconds]
SirFunk has quit [Ping timeout: 250 seconds]
_kfpratt has joined #ruby
andywojo has quit [Ping timeout: 245 seconds]
Legohead has quit [Ping timeout: 250 seconds]
Axy has quit [Ping timeout: 250 seconds]
davidcelis_ has quit [Ping timeout: 250 seconds]
hxegon_AFK is now known as hxegon
dlitvak_ has quit [Remote host closed the connection]
robbyoconnor has quit [Read error: Connection reset by peer]
gbailey has quit [Ping timeout: 250 seconds]
jxf_ has joined #ruby
peteyg_ has joined #ruby
Sthebig has quit [Ping timeout: 250 seconds]
pfg_ has joined #ruby
amitchellbullard has joined #ruby
morfin60 has joined #ruby
s2013 has quit [Ping timeout: 250 seconds]
genpaku has quit [Ping timeout: 250 seconds]
SirFunk has joined #ruby
lianj_ has joined #ruby
kent\n_ has joined #ruby
Puffball_ has joined #ruby
iamdevnul_ has joined #ruby
jlyndon_ has joined #ruby
it_tard has joined #ruby
ur5us has quit [Remote host closed the connection]