apeiros_ has quit [Remote host closed the connection]
Guest52470 has left #ruby-lang [#ruby-lang]
steez has joined #ruby-lang
krohrbaugh has quit [Quit: Leaving.]
rue has quit [Read error: Connection reset by peer]
rue has joined #ruby-lang
davidbalber|away is now known as davidbalbert
havenn has joined #ruby-lang
tenderlove has quit [Remote host closed the connection]
intellitech has joined #ruby-lang
spuk has joined #ruby-lang
dous has quit [Ping timeout: 248 seconds]
davidbalbert is now known as davidbalber|away
enebo has quit [Quit: enebo]
faustman has quit [Ping timeout: 256 seconds]
Mon_Ouie has joined #ruby-lang
jtoy has joined #ruby-lang
banisterfiend has quit [Ping timeout: 250 seconds]
Erlkoenig has joined #ruby-lang
dankest is now known as dankest|away
<Erlkoenig>
str.gsub!([0xA9].pack("C"),"\\'a9") <-- i have a string in CP-1252 encoding, and want to replace occurences of the 0xA9 symbol with some kind of escaping sequence. however i get this error: in `gsub!': incompatible encoding regexp match (ASCII-8BIT regexp with CP850 string) (Encoding::CompatibilityError) ... how to do it correctly?
<drbrain>
why do you need to escape them?
dankest|away is now known as dankest
<zenspider>
zentest 4.8.3 released
<Erlkoenig>
drbrain: because some retarded software (WiX) refuses to read the character when its unescaped
<drbrain>
Erlkoenig: how about: s.force_encoding Encoding::Binary; s.gsub "\xA9", '\\\\\'a9'
<drbrain>
oops, that should be BINARY
<drbrain>
I'm assuming you wanted the result to be \'A9
<Erlkoenig>
yes, exactly
stonerfish has quit [Quit: Leaving.]
<drbrain>
a) since you're working no bytes, let ruby know by saying your string is only bytes
<drbrain>
b) gsub requires extra \ because \ has special meaning
stonerfish has joined #ruby-lang
<Erlkoenig>
a) yep, i didn't know how to do that... b) yeah i noticed that... is there no "plain&stupid" string replace function?
<drbrain>
to replace a character with more characters, no
<drbrain>
if you're swapping, #tr can do it
Carnage\ has quit []
<Erlkoenig>
hmm okay
Mon_Ouie has quit [Ping timeout: 240 seconds]
<Erlkoenig>
ruby doesnt accept the "\xA9", but [0xA9].pack("C") works...
<drbrain>
you can use gsub with a block to get away from the \ rules, but that seems silly
<drbrain>
you may need to set your file coding
<drbrain>
I think [0xA9].pack "C" forces the result string to be binary
<Erlkoenig>
hmm okay... probably i'll just use pack
sent-hil has quit [Remote host closed the connection]
madish has quit [Quit: ChatZilla 0.9.89 [Firefox 16.0.1/20121026125834]]
sent-hil has joined #ruby-lang
__butch__ has quit [Quit: Leaving.]
sent-hil has quit [Remote host closed the connection]
mjio has quit []
tdy has joined #ruby-lang
sent-hil has joined #ruby-lang
runeb has joined #ruby-lang
banisterfiend has joined #ruby-lang
wyhaines has quit [Ping timeout: 260 seconds]
seanstickle has joined #ruby-lang
<zenspider>
ruby_parser 3.1.0 released
spuk has quit [Changing host]
spuk has joined #ruby-lang
havenn has quit [Remote host closed the connection]
sent-hil has quit [Remote host closed the connection]
wyhaines has joined #ruby-lang
runeb has quit [Ping timeout: 260 seconds]
Erlkoenig has quit [Quit: Leaving.]
<zenspider>
sexp_processor 4.1.3 released
WillMarshall has joined #ruby-lang
WillMarshall has quit [Client Quit]
jtoy has quit [Quit: jtoy]
wyhaines has quit [Remote host closed the connection]
gregmore_ has quit [Ping timeout: 264 seconds]
chimkan_ has quit [Quit: chimkan_]
sent-hil has joined #ruby-lang
<banisterfiend>
crankharder: ping
<zenspider>
minitest 4.3.3 released
seydar has joined #ruby-lang
jtoy has joined #ruby-lang
gsav has joined #ruby-lang
<zenspider>
ok. so seattle.rb normally has a weekly meeting that's just a low-key nerd party / hackfest
<zenspider>
but for the past 3 months, we've started doing monthly meetings with sponsors, pizza, and beer. we've got up to 3 talks, and we TRY to have lightning talks.
<zenspider>
we had ONE person who was not a regular give a lightning talk
<zenspider>
(and it was awesome... he talked about using interrobang in method names to make them confusing)
<seydar>
so. IO#getch does not seem to use buffered input. i.e., if i type a bunch of characters while i'm waiting for IO.getch to get called, it WON'T read from the characters that I've typed. anyone know a way to fix that? i'd like to have the benefit of having it in raw mode
kith_ has joined #ruby-lang
<zenspider>
but everyone else who has given a lightning talk has been a regular member
<zenspider>
what should I do to make more people give lightning talks?
<zenspider>
I am threatening to hijack the beer until 5 people sign up
<zenspider>
seydar: yeah. you want raw mode
<drbrain>
seydar: ruby -r io/console -e 'p $stdin.getch' prints a character as soon as I type one
<zenspider>
you can write a wrapper method to call out to stty, yield, and set it back; or find one of the gems to do it
jarsoflars has joined #ruby-lang
<zenspider>
or that
<drbrain>
zenspider: IO#getch does that
jarsoflars has left #ruby-lang [#ruby-lang]
<seydar>
right, that's not my issue
<seydar>
my issue is that I'd like it to read characters that were already typed
<zzak>
buy me a plane ticket
<seydar>
so: def read; sleep 1; STDIN.getch; end
<drbrain>
ah
<seydar>
yeah. call the method, type a bunch, i want to see the first character i typed
kith has quit [Ping timeout: 244 seconds]
<seydar>
zenspider: that's a tricky question you pose. i'm interested in hearing the solution when you get one
<drbrain>
is raw mode supposed to work that way?
rsl has quit [Quit: Computer has gone to sleep.]
ruskie has quit [Quit: ...]
<drbrain>
$stdin.raw { sleep 1; p $stdin.getch } is no better
<seydar>
the hard-work method is to reach out to individuals who aren't regulars. 1 on 1 talk to/email them and say "i want you to give a lightning talk"
runeb has quit [Read error: Connection reset by peer]
runeb- is now known as runeb
runeb- has joined #ruby-lang
runeb has quit [Read error: Connection reset by peer]
runeb- is now known as runeb
runeb- has joined #ruby-lang
runeb has quit [Read error: Connection reset by peer]
runeb- is now known as runeb
runeb- has joined #ruby-lang
runeb has quit [Read error: Connection reset by peer]
runeb- is now known as runeb
|Vargas| has joined #ruby-lang
runeb has quit [Read error: Connection reset by peer]
|Vargas| has quit [Changing host]
|Vargas| has joined #ruby-lang
runeb has joined #ruby-lang
runeb- has joined #ruby-lang
runeb has quit [Read error: Connection reset by peer]
runeb- is now known as runeb
runeb has quit [Killed (asimov.freenode.net (Nickname regained by services))]
runeb has joined #ruby-lang
runeb- has joined #ruby-lang
runeb- is now known as runeb
runeb is now known as Guest27637
Guest27637 has quit [Killed (wright.freenode.net (Nickname regained by services))]
runeb- has joined #ruby-lang
runeb- is now known as runeb
runeb- has joined #ruby-lang
runeb is now known as Guest40176
Guest40176 has quit [Read error: Connection reset by peer]
runeb- is now known as runeb
runeb- has joined #ruby-lang
runeb has quit [Read error: Connection reset by peer]
runeb- is now known as runeb
banister`sleep has quit [Ping timeout: 240 seconds]
runeb has quit [Read error: Connection reset by peer]
runeb has joined #ruby-lang
runeb- has joined #ruby-lang
runeb has quit [Killed (sturgeon.freenode.net (Nickname regained by services))]
runeb- is now known as runeb
runeb- has joined #ruby-lang
runeb has quit [Killed (pratchett.freenode.net (Nickname regained by services))]
runeb- is now known as runeb
PhilCK has joined #ruby-lang
runeb has quit [Read error: Connection reset by peer]
runeb- has joined #ruby-lang
runeb- is now known as runeb
runeb- has joined #ruby-lang
runeb has quit [Read error: Connection reset by peer]
runeb- is now known as runeb
runeb- has joined #ruby-lang
runeb has quit [Read error: Connection reset by peer]
runeb- is now known as runeb
runeb- has joined #ruby-lang
runeb has quit [Read error: Connection reset by peer]
runeb- is now known as runeb
runeb- has joined #ruby-lang
runeb has quit [Read error: Connection reset by peer]
runeb- is now known as runeb
kith_ is now known as kith
runeb has quit [Read error: Connection reset by peer]
runeb has joined #ruby-lang
banister`sleep has joined #ruby-lang
runeb- has joined #ruby-lang
runeb- is now known as runeb
runeb has quit [Killed (zelazny.freenode.net (Nickname regained by services))]
runeb has joined #ruby-lang
lsegal has quit [Quit: Quit: Quit: Quit: Stack Overflow.]
runeb has quit [Read error: Connection reset by peer]
runeb has joined #ruby-lang
runeb- has joined #ruby-lang
runeb has quit [Read error: Connection reset by peer]
runeb- is now known as runeb
<jaska>
holy nick change
runeb has quit [Read error: Connection reset by peer]
runeb has joined #ruby-lang
runeb- has joined #ruby-lang
runeb has quit [Read error: Connection reset by peer]
runeb- is now known as runeb
runeb- has joined #ruby-lang
runeb has quit [Read error: Connection reset by peer]
runeb- is now known as runeb
dc5ala has joined #ruby-lang
runeb has quit [Read error: Connection reset by peer]
runeb has joined #ruby-lang
runeb- has joined #ruby-lang
runeb is now known as Guest69698
runeb- is now known as runeb
Guest69698 has quit [Killed (sturgeon.freenode.net (Nickname regained by services))]
runeb- has joined #ruby-lang
runeb has quit [Read error: Connection reset by peer]
runeb- is now known as runeb
<intellitech>
runeb, luckily I have a mute button, since I can't disable my channel notifications on a per event per user basis. if I didn't, I'd be raging about your constant join/parting.
runeb has quit [Read error: Connection reset by peer]
<intellitech>
ffs
runeb has joined #ruby-lang
runeb- has joined #ruby-lang
runeb is now known as Guest42590
runeb- is now known as runeb
Guest42590 has quit [Killed (calvino.freenode.net (Nickname regained by services))]
<jaska>
i have joins quits leaves ignored.. guess i need to add the nick changes :D
runeb has quit [Read error: Connection reset by peer]
drbrain has joined #ruby-lang
runeb has joined #ruby-lang
intellitech has left #ruby-lang [#ruby-lang]
runeb has quit [Read error: Connection reset by peer]
gnufied has quit [Quit: Leaving.]
runeb has joined #ruby-lang
runeb- has joined #ruby-lang
runeb has quit [Read error: Connection reset by peer]
runeb- is now known as runeb
drbrain- has quit [Ping timeout: 246 seconds]
runeb has quit [Read error: Connection reset by peer]
runeb- has joined #ruby-lang
runeb- is now known as runeb
runeb- has joined #ruby-lang
runeb has quit [Read error: Connection reset by peer]
runeb- is now known as runeb
runeb- has joined #ruby-lang
runeb- is now known as runeb
runeb has quit [Killed (niven.freenode.net (Nickname regained by services))]
dankest is now known as dankest|away
dankest|away is now known as dankest
runeb has joined #ruby-lang
runeb- has joined #ruby-lang
runeb has quit [Read error: Connection reset by peer]
runeb- is now known as runeb
runeb has quit [Read error: Connection reset by peer]
justinseiter has quit [Ping timeout: 240 seconds]
ryanf has quit [Quit: leaving]
<zenspider>
zzak: which?
<zenspider>
zzak: if you're referring to the minitest travis PR, the answer is a firm "no" at this point. I'm getting spammed by travis CI already
kingcrawler has quit [Quit: Computer has gone to sleep]
icooba has joined #ruby-lang
vlad_starkov has joined #ruby-lang
jsilver has joined #ruby-lang
swav has quit [Remote host closed the connection]
gnufied has joined #ruby-lang
judofyr has joined #ruby-lang
dankest is now known as dankest|away
dankest|away is now known as dankest
mixandgo has joined #ruby-lang
<yorickpeterse>
Morning
rue|w has joined #ruby-lang
swav has joined #ruby-lang
waffleau has joined #ruby-lang
marr has joined #ruby-lang
mixandgo has quit [Quit: mixandgo]
sepp2k has quit [Quit: Leaving.]
dankest is now known as dankest|away
adambeynon has joined #ruby-lang
CoverSlide has quit [Read error: Operation timed out]
swav has quit [Ping timeout: 256 seconds]
postmodern has quit [Ping timeout: 248 seconds]
postmodern has joined #ruby-lang
lele has quit [Ping timeout: 246 seconds]
gaveen has joined #ruby-lang
gaveen has quit [Changing host]
gaveen has joined #ruby-lang
rohit has joined #ruby-lang
marr has quit [Ping timeout: 252 seconds]
PhilCK has quit [Quit: PhilCK]
lele has joined #ruby-lang
swav has joined #ruby-lang
GarethAdams has joined #ruby-lang
sebastianb has quit [Ping timeout: 246 seconds]
workmad3 has joined #ruby-lang
apeiros_ has joined #ruby-lang
sebastianb has joined #ruby-lang
sebastianb has quit [Ping timeout: 246 seconds]
krz has quit [Quit: krz]
rohit has quit [Read error: Connection reset by peer]
sebastianb has joined #ruby-lang
robbyoconnor has quit [Ping timeout: 244 seconds]
tbuehlmann has joined #ruby-lang
sebastianb has quit [Read error: Connection reset by peer]
rohit has joined #ruby-lang
dr_bob has quit [Quit: Leaving.]
vlad_starkov has quit [Remote host closed the connection]
dr_bob has joined #ruby-lang
wallerdev has quit [Quit: wallerdev]
jbsan has quit [Quit: jbsan]
vlad_starkov has joined #ruby-lang
cultureulterior_ has joined #ruby-lang
io_syl has quit [Quit: Computer has gone to sleep.]
sn0wb1rd has quit [Quit: I will be right back]
sebastianb has joined #ruby-lang
jbsan has joined #ruby-lang
blowmage has quit [Ping timeout: 260 seconds]
adgar has quit [Ping timeout: 264 seconds]
adgar has joined #ruby-lang
blowmage has joined #ruby-lang
mars777 has quit [Quit: mars777]
rohit has quit [Quit: Leaving]
dankest|away has quit [Quit: Leaving...]
dr_bob has left #ruby-lang [#ruby-lang]
ruurd has quit [Quit: Leaving...]
waffleau has quit [Read error: Connection reset by peer]
<yorickpeterse>
Hmm, then I suppose it's time to move my site over to nanoc
<yorickpeterse>
running a DB for something that only changes once/twice a year is an overkill
<yorickpeterse>
ddfreyne: so is nanoc webscale?
<yorickpeterse>
or do I need to install Node.js for that?
* yorickpeterse
runs
<injekt>
or use java
gnufied has joined #ruby-lang
<gnufied>
ddfreyne: awesomeness
tbuehlmann has quit [Remote host closed the connection]
waffleau has joined #ruby-lang
dous has joined #ruby-lang
seoaqua has joined #ruby-lang
banisterfiend has quit [Read error: Connection timed out]
banisterfiend has joined #ruby-lang
luikore has joined #ruby-lang
dous has quit [Remote host closed the connection]
<andrewvos>
judofyr: Nothing lately no
luikore has left #ruby-lang [#ruby-lang]
<andrewvos>
judofyr: I wanted to play with that Levenshtein distance code and maybe write something for capybara/rspec that can do better error messages
<andrewvos>
judofyr: Like if you try click a link with the id "usernme" it could say "did you mean 'username'?"
<judofyr>
andrewvos: hm… "did you mean"?
<andrewvos>
Yea
<judofyr>
cool
<andrewvos>
judofyr: But nothing too interesting :(
<ddfreyne>
yorickpeterse: it generates static HTML files so that should scale pretty well :)
<yorickpeterse>
nah man, it needs node.js
<yorickpeterse>
Are there any plugins for it that can minify CSS/JS for you or do I have to do that myself?
<ddfreyne>
yeah those exist. There’s Rainpress and YUICompressor
<yorickpeterse>
I meant as some rake task that does it
<yorickpeterse>
Or something similar
<manveru>
write your own, takes like 3 lines including "end"
<manveru>
though i say that about pretty much everything :)
<ddfreyne>
yorickpeterse: you’d implement that as a filter that you run
<ddfreyne>
yorickpeterse: so you’d run markdown first, then erb, then rubypants, and finally a compressor filter, or something like that
cored has quit [Ping timeout: 248 seconds]
<yorickpeterse>
hmm
cored has joined #ruby-lang
cored has joined #ruby-lang
cored has quit [Changing host]
<whitequark>
zenspider: why do RP tests fail?
<whitequark>
/home/whitequark/ruby_parser/test/test_ruby_parser.rb:30:in `<class:RubyParserTestCase>': undefined method `make_my_diffs_pretty!' for RubyParserTestCase:Class (NoMethodError)
<whitequark>
oh, and it also depends on hoe-isolate which is nowhere to be found.
s1n4 has joined #ruby-lang
MaddinXx has joined #ruby-lang
kurko_ has joined #ruby-lang
spuk has quit [Quit: Human beings were created by water to transport it uphill.]
x0F has quit [Disconnected by services]
x0F_ has joined #ruby-lang
x0F_ is now known as x0F
jxie has quit [Quit: leaving]
lushious has left #ruby-lang [#ruby-lang]
seoaqua has left #ruby-lang ["离开"]
MaddinXx has quit [Remote host closed the connection]
zmack has quit [Remote host closed the connection]
aef has quit [Remote host closed the connection]
alvaro_o has joined #ruby-lang
burgestrand has joined #ruby-lang
aef has joined #ruby-lang
burgestrand has quit [Read error: Connection reset by peer]
Uranio has quit [Quit: WeeChat 0.3.8]
headius has joined #ruby-lang
havenn has quit [Remote host closed the connection]
jgable has quit []
tenderlove has joined #ruby-lang
WillMarshall has joined #ruby-lang
alvaro_o has quit [Quit: Ex-Chat]
sullenel has quit [Quit: Leaving.]
alvaro_o has joined #ruby-lang
headius_ has joined #ruby-lang
davidbalber|away is now known as davidbalbert
swav has joined #ruby-lang
headius has quit [Read error: Connection reset by peer]
headius_ is now known as headius
_sillymarkets has joined #ruby-lang
<_sillymarkets>
Can anyone help me with using %x to send system terminal commands, really quickly? I want to use ruby to kick off a Beyond Compare script
<_sillymarkets>
but it is erroring with: "not found"
_carloslopes has quit [Remote host closed the connection]
kirill is now known as olyryk
olyryk is now known as banisterfiend
<ddd>
btw, its %x[]
ryanf has quit [Quit: broken pipes |||]
<ddd>
never seen %x() before
<ddd>
oh damn! i guess it does work. ignore me.
<ddd>
don't put each on in "#{}" of their own. if you're trying to build up a full commandline then use a single set of "" and interpolate in the single string buildup
<ddd>
and what is the @ for?
<_sillymarkets>
i kind of follow you, can you give a brief example?
<_sillymarkets>
the @ is necessary for bcompare to kick off... bcompare needs this command from terminal to auto-start ........ bcompare @"script.txt" "file1.txt" "file2.txt" "report.html"
dankest is now known as dankest|away
<_sillymarkets>
thats the string i need Ruby to pass to system/shell and it should auto kick off Bcompare
<_sillymarkets>
I believe bcompare needs those quotes around the separate file names for it take the command, so the single string may not work
<ddd>
yeah seeing it now. even with ls
<ddd>
gimme a sec
<ddd>
ahh got it
<_sillymarkets>
what did you try?
<ddd>
don't use the "". like this: asset1 = "-alh" ; asset2 = "./" ; %x[ls #{asset1} #{asset2}]
<ddd>
look closely in the %x format
<ddd>
now let me see about passing the "" themselves
Mon_Ouie has joined #ruby-lang
Mon_Ouie has quit [Changing host]
Mon_Ouie has joined #ruby-lang
<ddd>
%x[ls #{asset1} \"hello there.txt\"] works
ebouchut has joined #ruby-lang
<ddd>
in the shell you need either "" around the full filename, or use '\ to hardcode the space in the name. since you're using "" I used that. put \" to pass the " explicitly. worked here
ruurd has joined #ruby-lang
<ddd>
see if %x(bcompare @\"bcompare_html_script.txt #{variable1} #{variable2} reports.html\")
<ddd>
works
<ddd>
you shojuldn't need that @ either
<_sillymarkets>
beyondcompare requires that @
<ddd>
ahh might have to \ t too idk
mame0 has quit [Ping timeout: 244 seconds]
<_sillymarkets>
it took the other stuff, but its not taking that @
headius_ has joined #ruby-lang
headius has quit [Read error: Connection reset by peer]
headius_ is now known as headius
<_sillymarkets>
hmm
<ddd>
w or w/o the \ ?
<ddd>
try \\@
<ddd>
might need to pass the \ directly to the shell, so escape the \ itself (two \)
bluepojo has joined #ruby-lang
bluepojo has quit [Client Quit]
ruurd has quit [Quit: Leaving...]
banister_ has joined #ruby-lang
mame0 has joined #ruby-lang
bluepojo has joined #ruby-lang
bluepojo is now known as 13WAAC35D
<_sillymarkets>
hm, now i got it saying "sh: 1: not found" but it fully displays the entire string
<_sillymarkets>
its just trying to open a file with that name instead of passing it to terminal to envoke beyond compare, it seems
workmad3 has joined #ruby-lang
<_sillymarkets>
think i got it
nick_h has quit [*.net *.split]
banisterfiend has quit [*.net *.split]
aef has quit [*.net *.split]
chendo_ has quit [*.net *.split]
kennyvb has quit [*.net *.split]
totallymike has quit [*.net *.split]
nazty has quit [*.net *.split]
ottbot has quit [*.net *.split]
meise has quit [*.net *.split]
knu has quit [*.net *.split]
kaliya_ has quit [*.net *.split]
mksm has quit [*.net *.split]
neurodamage has quit [*.net *.split]
LanceHaig has quit [*.net *.split]
<_sillymarkets>
using "system()" instead of %x
<_sillymarkets>
thanks for your help man
setmeaway has quit [Read error: No buffer space available]
setmeaway has joined #ruby-lang
ryanf has joined #ruby-lang
aef has joined #ruby-lang
16WABGBA3 has joined #ruby-lang
kaliya_ has joined #ruby-lang
meise has joined #ruby-lang
totallymike has joined #ruby-lang
nick_h has joined #ruby-lang
knu has joined #ruby-lang
ottbot has joined #ruby-lang
mksm has joined #ruby-lang
kennyvb has joined #ruby-lang
neurodamage has joined #ruby-lang
LanceHaig has joined #ruby-lang
nazty has joined #ruby-lang
tenderlove has quit [Remote host closed the connection]
aef has quit [Excess Flood]
justinseiter has quit [Excess Flood]
totallymike has quit [Excess Flood]
tenderlove has joined #ruby-lang
tenderlove has quit [Read error: Connection reset by peer]
tenderlove has joined #ruby-lang
joaovrmaia has quit [Quit: joaovrmaia]
aef has joined #ruby-lang
totallymike has joined #ruby-lang
wallerdev has joined #ruby-lang
totallymike is now known as Guest51135
justinseiter has joined #ruby-lang
fsvehla has quit [Quit: fsvehla]
tenderlove has quit [Ping timeout: 250 seconds]
lcdhoffman has quit [Quit: lcdhoffman]
<ddd>
_sillymarkets: no problem :)
fsvehla has joined #ruby-lang
gaveen has quit [Remote host closed the connection]
havenn has joined #ruby-lang
swav has quit [Remote host closed the connection]
havenn has quit [Remote host closed the connection]
workmad3 has quit [Ping timeout: 255 seconds]
havenn has joined #ruby-lang
havenn has quit [Read error: No route to host]
ebouchut has quit [Quit: This computer has gone to sleep]
cored has quit [Ping timeout: 240 seconds]
cored has joined #ruby-lang
cored has quit [Changing host]
cored has joined #ruby-lang
faustman has joined #ruby-lang
facest has joined #ruby-lang
faces has quit [Ping timeout: 250 seconds]
ddd has quit [Quit: Leaving.]
havenn has joined #ruby-lang
ddd has joined #ruby-lang
headius has quit [Read error: Connection reset by peer]
headius has joined #ruby-lang
arooni-mobile has joined #ruby-lang
workmad3 has joined #ruby-lang
ryanf has quit [Quit: broken pipes |||]
arooni-mobile has quit [Ping timeout: 240 seconds]
ryanf has joined #ruby-lang
matled has quit [Ping timeout: 246 seconds]
dankest|away has quit [Quit: Leaving...]
drbrain- has joined #ruby-lang
imperator has joined #ruby-lang
drbrain has quit [Ping timeout: 240 seconds]
davidbalbert is now known as davidbalber|away
<imperator>
howdy
<zzak>
imperator: hi!
justinseiter has quit [Ping timeout: 240 seconds]
ryanf_ has joined #ruby-lang
swav has joined #ruby-lang
WillMarshall has quit [Quit: Computer has gone to sleep.]
ryanf has quit [Quit: broken pipes |||]
ryanf_ is now known as ryanf
marr has joined #ruby-lang
justinseiter has joined #ruby-lang
vlad_starkov has quit [Remote host closed the connection]
ebouchut has joined #ruby-lang
ebouchut has quit [Client Quit]
justinseiter has quit [Ping timeout: 252 seconds]
vlad_starkov has joined #ruby-lang
dankest has joined #ruby-lang
methods has joined #ruby-lang
methods has quit [Client Quit]
methods has joined #ruby-lang
stonerfish has joined #ruby-lang
justinseiter has joined #ruby-lang
methods has left #ruby-lang [#ruby-lang]
sailias has quit [Quit: Leaving.]
vlad_starkov has quit [Ping timeout: 252 seconds]
WillMarshall has joined #ruby-lang
justinseiter has quit [Read error: Operation timed out]
WillMarshall has quit [Client Quit]
kurko_ has quit [Quit: Computer has gone to sleep.]
justinseiter has joined #ruby-lang
justinseiter has quit [Ping timeout: 244 seconds]
workmad3 has quit [Ping timeout: 240 seconds]
seydar has joined #ruby-lang
imperator has quit [Quit: This computer has gone to sleep]
<seydar>
whitequark: let's talk about this mysterious embedded compiler you're writing
pangel has joined #ruby-lang
drbrain has joined #ruby-lang
justinseiter has joined #ruby-lang
<seydar>
unrelated: i am looking for guinea pigs to try a Ruby shell
drbrain- has quit [Ping timeout: 245 seconds]
rsl has quit [Quit: Computer has gone to sleep.]
<pangel>
I want to send and receive to/from multiple peers in UDP without blocking. I don't know much about network programming. Is it possible to do it all on a single port using events?
<seydar>
pangel: on one port, yes. think of an HTTP server: it sends packets to multiple peers and receives packets from multiple peers, all from port 80
<seydar>
i thought you could with both, and then i read something just now where a guy was complaining that all of his UDP connected peers were on one port
tonni has joined #ruby-lang
justinseiter has joined #ruby-lang
<seydar>
so hold up, how does TCP deal with multiple clients? does it switch them to alternate ports?
<drbrain>
as a TCP client you can talk to one server
<drbrain>
as a TCP server you can talk to many clients (by calling accept on the socket and getting a new socket
<drbrain>
but you can't be a server and client on the same socket
<drbrain>
with UDP you can use #send with a destination socket address (third argument) and receiv
vlad_starkov has joined #ruby-lang
leopard_me has joined #ruby-lang
<drbrain>
Socket#recvfrom gives you the message nda the sender's addrinfo
<seydar>
d'oh, i'm conflating socket with port. how close are the two?
<drbrain>
a socket is a pipe
<drbrain>
it runs on some port on some address
<drbrain>
(hand waving past UNIX sockets)
<seydar>
are there a limited amount of ports?
<drbrain>
it depends on the protocol, UDP and TCP have 65535 ports available each (0 is special)
<seydar>
probs, which is why we have load balancers
justinseiter has quit [Remote host closed the connection]
<drbrain>
load balancers solve a different problem
dabradley has quit [Quit: WeeChat 0.3.8]
<drbrain>
for HTTP or HTTPS balancing you only connect to port 80 and 443, so you don't have a problem with port exhaustion
<rue>
You can have umpteen gabillion connections to your 65535 ports
<seydar>
ok, explain that magic: http/s can only connect to port 80/443. but they deal with multiple clients concurrently
justinseiter has joined #ruby-lang
<seydar>
rue: right there. that magic
<drbrain>
if you want to test your load handling capability for TCP protocols you need lets of outbound ports
<drbrain>
(depending on how big you are)
<seydar>
oh. once again. the conflation of ports and sockets.
<rue>
He’s about 6'2"
<seydar>
ports are needed so i can have 65535 different programs listening at once
<seydar>
and each of them can take umpteen gabillion connections
<drbrain>
seydar: or making outbound TCP connection
<seydar>
right, thank you
sn0wb1rd has joined #ruby-lang
zmack has joined #ruby-lang
vlad_starkov has quit [Ping timeout: 255 seconds]
xyzodiac has quit [Quit: Computer has gone to sleep.]
<seydar>
bizarre problem: every link i click to on youtube takes me to soundcloud.com/... instead. same url for everything after the domain
justinseiter has quit [Ping timeout: 264 seconds]
justinseiter has joined #ruby-lang
dabradley has joined #ruby-lang
sent-hil has joined #ruby-lang
dankest has quit [Quit: Leaving...]
tonni has quit [Ping timeout: 248 seconds]
headius has quit [Quit: headius]
krohrbaugh has quit [Quit: Leaving.]
dankest has joined #ruby-lang
tonni has joined #ruby-lang
<rue>
It’s probably a bacterium
justinseiter has quit [Ping timeout: 260 seconds]
<seydar>
like i'm actually so confused.
<seydar>
this happened once before where facebook went to myspace
slyphon has quit [Quit: WeeChat 0.3.8]
krohrbaugh has joined #ruby-lang
justinseiter has joined #ruby-lang
sn0wb1rd_ has joined #ruby-lang
sn0wb1rd has quit [Ping timeout: 250 seconds]
sn0wb1rd has joined #ruby-lang
justinseiter has quit [Ping timeout: 252 seconds]
sn0wb1rd_ has quit [Ping timeout: 265 seconds]
headius has joined #ruby-lang
mindbender1 has quit [Ping timeout: 264 seconds]
justinseiter has joined #ruby-lang
sent-hil has quit [Remote host closed the connection]
justinseiter has quit [Ping timeout: 240 seconds]
thatdutchguy has joined #ruby-lang
JoelMcCracken has joined #ruby-lang
acyed has joined #ruby-lang
justinseiter has joined #ruby-lang
justinseiter has quit [Ping timeout: 252 seconds]
justinseiter has joined #ruby-lang
justinseiter has quit [Ping timeout: 264 seconds]
outoftime has quit [Quit: Leaving]
justinseiter has joined #ruby-lang
seydar has quit [Quit: leaving]
havenn has quit [Remote host closed the connection]
justinseiter has quit [Ping timeout: 240 seconds]
wyhaines has quit [Remote host closed the connection]
havenn has joined #ruby-lang
robbyoconnor has joined #ruby-lang
seydar has joined #ruby-lang
<seydar>
how do I find the last day of the month?
justinseiter has joined #ruby-lang
<seydar>
derp. Date.new 2013, -1, -1
<seydar>
but still. a method for an already instantiated date object would be 1337
havenn has quit [Ping timeout: 255 seconds]
seydar has quit [Quit: leaving]
justinseiter has quit [Ping timeout: 250 seconds]
havenn has joined #ruby-lang
justinseiter has joined #ruby-lang
blacktul_ has quit [Remote host closed the connection]
ReshadN has joined #ruby-lang
headius has quit [Quit: headius]
justinseiter has quit [Read error: Connection reset by peer]
justinseiter has joined #ruby-lang
chimkan has quit [Quit: chimkan]
davidbalber|away is now known as davidbalbert
justinseiter has quit [Read error: Operation timed out]
<zenspider>
Has _anyone_ used $= = true ????
justinseiter has joined #ruby-lang
sent-hil has joined #ruby-lang
chimkan_ has joined #ruby-lang
<apeiros_>
why? want to gather a lynch mob? :)
WillMarshall has joined #ruby-lang
* apeiros_
thinks those globals are a horrible thing and shouldn't be touched
JoelMcCracken has quit [Ping timeout: 252 seconds]
<zzak>
zenspider: i was talking about racc
<zenspider>
apeiros_: just never seen it used. can't come up with a usecase for it. don't get it
<zenspider>
zzak: oh. that's up to tenderlove, not me.
justinseiter has quit [Ping timeout: 264 seconds]
<zzak>
zenspider: ok i will ping him
tenderlove has joined #ruby-lang
nerd has quit [Ping timeout: 260 seconds]
<apeiros_>
zenspider: as said, I think actually using them is IMO a horrible idea
<tpope>
$= sounds pretty terrible even as far as globals go
<apeiros_>
I mean how to better break code than change behavior globally…
<apeiros_>
(and rather unexpectedly)
<apeiros_>
plays in a similar league as mathn's monkey patch of Integer#/
justinseiter has joined #ruby-lang
<Spaceghostc2c>
Dear god of lolwat. :(
<whitequark>
$= is deprecated really long ago, isn't it?
<zenspider>
tpope: yeah. this one seems particularly heinous... not sure how long it has been deprecated.
<zenspider>
maybe we could push for removal now
krohrbaugh has quit [Quit: Leaving.]
<zzak>
zenspider: did you see ri ruby:globals yet?
* apeiros_
would remove all single letter $ vars
banister_ has left #ruby-lang [#ruby-lang]
<zzak>
it is verbatim
banisterfiend has joined #ruby-lang
gsav_ has joined #ruby-lang
tenderlove has quit [Remote host closed the connection]
<whitequark>
apeiros_: +1
imajes has quit [Excess Flood]
imajes has joined #ruby-lang
<whitequark>
but things like $: are used by a whole lot of people
<zenspider>
zzak: no, I haven't
<zenspider>
take away my $: and I'll use some other impl
<tpope>
zenspider: $= isn't even from perl. it was invented for ruby :/
<apeiros_>
whitequark: deprecation with a sensible message
justinseiter has quit [Read error: Operation timed out]
<apeiros_>
"$: is deprecated, please use $LOAD_PATH"
<whitequark>
well, $: is quite better than $INCLUDE_PATH or how it is
<whitequark>
ah, $LOAD_PATH
krohrbaugh has joined #ruby-lang
<apeiros_>
$: tells nothing
<apeiros_>
$LOAD_PATH at least is guessable
<whitequark>
$: is very common
<whitequark>
and it is quite convenient where it's used
<apeiros_>
and if you don't like writing, your editor surely allows you to add an expansion for $: to $LOAD_PATH
<whitequark>
on the other hand, things like $` or $' are rarely ever used
<apeiros_>
(and if not, *use another editor* ffs :-p)
<whitequark>
apeiros_: I don't like reading that, but yes, you have a point.
gsav has quit [Ping timeout: 264 seconds]
<whitequark>
it would also be weird to deprecate every other global and keep $:
<tpope>
$` and $' are in a separate category because they're not really globals
<whitequark>
kinda missing the point.
<whitequark>
tpope: we're talking about names here
gsav_ has quit [Ping timeout: 255 seconds]
<whitequark>
I know they're frame-local
<whitequark>
which also makes them way more evil, but I digress
<apeiros_>
:)
justinseiter has joined #ruby-lang
<whitequark>
what I'd definitely vote to keep is $1..$262144
<whitequark>
github style guide recommends using named capture groups, but they're a hack on their own
<tpope>
does it really go to $262144? :/
<whitequark>
tpope: yeah, I've checked that some time ago
<tpope>
I put $` and $' in the same category
<tpope>
the category of "kind of weird and gross, but the other methods are comparatively awkward"
<whitequark>
tpope: have you ever seen them being used, or, have you ever seen a person who could say what they do?
<whitequark>
$3 is quite obvious if you've ever used regexps
<tpope>
I feel like I've used $` and $' before
<tpope>
admittedly rarely
<tpope>
and $&
<tpope>
I wish the block form of gsub passed a match object
<whitequark>
and, for that matter, the fact that you need to parse regexps in order to find which local variables are defined in your programs, or that you need to know that regexps can introduce new local variables in the scope if they're used in a certain position relative to the match operator...
justinseiter has quit [Ping timeout: 265 seconds]
<apeiros_>
and without interpolations
<whitequark>
seriously, $2 is _way_ easier
<whitequark>
apeiros_: oh. lovely. another quirk.
<tpope>
yeah that's even worse
<yorickpeterse>
Hm, seems gems testers died a silent death
<tpope>
$2 at least tells you "look for the nearest regexp"
<apeiros_>
yorickpeterse: yes, erikh said something about heroku(?) losing his DB…
<whitequark>
tpope: I mean, I appreciate the fact that they tried to make it better, but it's kinda fail :/
<yorickpeterse>
apeiros_: lol?
<tpope>
the matchdata object should reign surpreme
<whitequark>
tpope: isn't there a frame-local gvar which returns the matchdata object?
<tpope>
$~
matled has joined #ruby-lang
<apeiros_>
$~ is actually vital
<apeiros_>
there's things you can't do without it
nerd has joined #ruby-lang
<apeiros_>
(well, ok, you could use the Regexp.last_match equivalent)
<tpope>
same difference
<whitequark>
aliased as $LAST_MATCH_INFO
justinseiter has joined #ruby-lang
<tpope>
I mean it should be explicitly returned instead of grabbed from thin air
thatdutchguy has quit [Remote host closed the connection]
gregmoreno has quit [Ping timeout: 244 seconds]
justinseiter has quit [Ping timeout: 256 seconds]
<whitequark>
if I'd be the one to decide (and it's probably a good thing that I am not), I'd nuke everything except $:, $!, $<, $> and possibly $?, and then discuss everything else
chimkan_ has quit [Ping timeout: 248 seconds]
<whitequark>
$; and $, are on a similar level of evilness as the $=
<banisterfiend>
what does $= do
justinseiter has joined #ruby-lang
<whitequark>
banisterfiend: globally makes string comparisons case-insensitive
<zenspider>
wow... did I derail this into some mentabatory BS or what??? I win!
<whitequark>
zenspider: oh, yes, that sentence is very consistent with the way your code is written.
<tpope>
burn?
<zenspider>
heh
<whitequark>
tpope: if I'd rewrite everything I don't like, I won't have a life. or have even less life than I do now.
<zenspider>
I'm making the assertion lists look like sorta-actual code rather than arg names
<whitequark>
zenspider: that sounded more harsh than it probably should have been, sorry. what I was referring to is just the RubyParserExtras, which practically consists of hacks hacking hacks.
nignaztic has joined #ruby-lang
ilyam has joined #ruby-lang
<whitequark>
and yes, I understand that the proc sometimes returns s(:args) and sometimes 0 in place of it because ParseTree did that, but no, that doesn't make it less fucked up.
justinseiter has joined #ruby-lang
<whitequark>
or make it a better design.
vlad_starkov has joined #ruby-lang
<zenspider>
whitequark: no offense taken. I know you come off like a bit of a dick and I calibrate accordingly. :P
<zenspider>
0 says that no args is enforced. s(:args) is loose
tenderlove has joined #ruby-lang
marr has quit [Ping timeout: 240 seconds]
<whitequark>
zenspider: what I want is to be able to simply recursively iterate the AST
<whitequark>
and when AST sometimes has symbols/integers and sometimes Sexps in the same place, it's not easy nor convenient
<zenspider>
that's nice. I had a discussion when RP was in beta to discuss the format of args for iters. I blogged it. Had a ticket open. Etc... you didn't speak up. It will stay the way it is until at least 4.0
<whitequark>
zenspider: I missed that, unfortunately.
<zzak>
zenspider: you using rdoc? i patched English.rb to be a little nicer
wyhaines has joined #ruby-lang
<zenspider>
zzak: markdown
<zzak>
sorry, lib/README
<zenspider>
lemme polish a bit and I'll sync up and let you guys bash on it
<zzak>
you can use markdown with rdoc 4
justinseiter has quit [Ping timeout: 255 seconds]
vlad_starkov has quit [Ping timeout: 260 seconds]
<whitequark>
zenspider: you have RSS? I'd definitely want to discuss the sexp format in the future.
<zenspider>
this is part of my website... I don't use rdoc to process it
<zzak>
zenspider: is quickref on github or something? i can merge your changes upstream
<zzak>
ahh
<zenspider>
I have it in perforce :P
<zzak>
ok well ping me or whatever when you update it