chouhoulis has quit [Remote host closed the connection]
weaksauce has quit [Read error: Connection reset by peer]
chouhoulis has joined #ruby
<freemo>
al2o3-cr: i dont think thts it cause the border renders just not when i use addstr.. so its not at the terminal level it has to be NCurses specific
xfbs has quit [Quit: afk]
<al2o3-cr>
freemo: what string are you passing to addstr?
xfbs has joined #ruby
<freemo>
al2o3-cr: box drawing characyers, the same ones successfully rendered for the border
<al2o3-cr>
freemo: i've tested and they seem to work.
blackmesa has quit [Ping timeout: 252 seconds]
d^sh has quit [Ping timeout: 244 seconds]
<freemo>
al2o3-cr: yea others have had success too, but not for me
d^sh has joined #ruby
<freemo>
al2o3-cr: let me see your code, maybe there is a clue...
rivalomega has quit [Remote host closed the connection]
rivalomega has joined #ruby
za1b1tsu has joined #ruby
<zenspider>
rawr
nowhere_man has joined #ruby
marahin has quit [Ping timeout: 252 seconds]
rivalomega has quit [Ping timeout: 252 seconds]
reber has quit [Remote host closed the connection]
Snowy has joined #ruby
ur5us has joined #ruby
ur5us has quit [Remote host closed the connection]
GodFather has quit [Read error: Connection reset by peer]
marahin has joined #ruby
Snowy has quit [Read error: Connection reset by peer]
mikecmpbll has joined #ruby
mikecmpbll has quit [Client Quit]
Snowy has joined #ruby
GodFather has joined #ruby
GodFather has quit [Max SendQ exceeded]
mikecmpbll has joined #ruby
clemens3 has quit [Remote host closed the connection]
Blaguvest has joined #ruby
clemens3 has joined #ruby
Puffball has quit [Remote host closed the connection]
GodFather has joined #ruby
lxsameer has joined #ruby
Puffball has joined #ruby
themsay has joined #ruby
moei has quit [Read error: Connection reset by peer]
moei has joined #ruby
phaul has joined #ruby
roshanavand has joined #ruby
GodFather has quit [Ping timeout: 252 seconds]
venmx has joined #ruby
idiocrash has quit [Ping timeout: 245 seconds]
paraxial has quit [Ping timeout: 252 seconds]
idiocrash has joined #ruby
Nicmavr has quit [Read error: Connection reset by peer]
GodFather has joined #ruby
kapil____ has joined #ruby
Nicmavr has joined #ruby
blackmesa has joined #ruby
GodFather has quit [Max SendQ exceeded]
za1b1tsu has quit [Ping timeout: 272 seconds]
blackmesa has quit [Ping timeout: 252 seconds]
ansraliant has quit [Quit: My planet needs me]
blackmesa has joined #ruby
KeyJoo has joined #ruby
phaul has quit [Ping timeout: 250 seconds]
lxsameer has quit [Ping timeout: 252 seconds]
mikecmpbll has quit [Quit: inabit. zz.]
mikecmpbll has joined #ruby
themsay has quit [Ping timeout: 252 seconds]
themsay has joined #ruby
lxsameer has joined #ruby
za1b1tsu has joined #ruby
throwntall has quit [Remote host closed the connection]
throwntall has joined #ruby
_whitelogger has joined #ruby
whysthatso has joined #ruby
mike11 has joined #ruby
<Cork>
if you have callback = -> { puts "works" }, is there a way to get the text "puts \"works\"" or similar from the variable callback?
<Cork>
(both with or without the -> {} works for me)
raulp has quit [Ping timeout: 268 seconds]
rivalomega has joined #ruby
rivalomega has quit [Ping timeout: 246 seconds]
Sp4rKy has quit [Quit: leaving]
Sp4rKy has joined #ruby
KeyJoo has quit [Ping timeout: 268 seconds]
_whitelogger has joined #ruby
Pisuke has quit [Read error: Connection reset by peer]
vondruch has joined #ruby
vondruch has quit [Quit: vondruch]
Blaguvest has quit [Read error: Connection reset by peer]
_whitelogger has quit [Excess Flood]
_whitelogger has joined #ruby
Pisuke has joined #ruby
paraxial has joined #ruby
themsay has quit [Ping timeout: 272 seconds]
themsay has joined #ruby
dionysus69 has quit [Quit: ZNC 1.7.1+deb2 - https://znc.in]
dbz has joined #ruby
dionysus69 has joined #ruby
blackmesa has quit [Quit: WeeChat 2.2]
dbz has quit [Ping timeout: 268 seconds]
<phage>
I'm crawling a site to get some specific output. I have the following code that returns the correct data, but I only need every second line from the output. Any ideas? https://dpaste.de/HHkU#L16
xfbs has joined #ruby
SolarAquarion has quit [Ping timeout: 250 seconds]
za1b1tsu has quit [Ping timeout: 252 seconds]
SolarAquarion has joined #ruby
Tuor has quit [Ping timeout: 246 seconds]
qolq3 has joined #ruby
qolq has quit [Read error: Connection reset by peer]
qolq3 is now known as qolq
za1b1tsu has joined #ruby
<Cork>
phage: .each_with_index.select {|a,b| b % 2 == 1 } is one option
<phage>
Cork: Thanks. I changed my approach a bit and made it work with this: https://dpaste.de/ZR1X
jetchisel has quit [Quit: Unfortunately time is always against us -- [Morpheus]]
apeiros_ has joined #ruby
roshanavand has quit [Ping timeout: 252 seconds]
dbz has quit [Ping timeout: 244 seconds]
zerocold has joined #ruby
bmurt has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
kurko_ has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
knight33 has joined #ruby
xfbs has joined #ruby
eckhardt has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
SeepingN_ is now known as SeepingN
jetchisel has joined #ruby
salasrod has quit [Quit: /quit]
justicefries has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
bmurt has joined #ruby
salasrod has joined #ruby
justicefries has joined #ruby
Snowy is now known as iAmAnon
crankharder has joined #ruby
iAmAnon is now known as ReporterMan
desperek has joined #ruby
sarmiena_ has joined #ruby
cd has quit [Quit: cd]
sarmiena_ has quit [Quit: sarmiena_]
zerocold has quit [Ping timeout: 252 seconds]
Rapture has quit [Ping timeout: 260 seconds]
cyberRodent has quit [Ping timeout: 276 seconds]
za1b1tsu has joined #ruby
ReporterMan has quit [Remote host closed the connection]
ReporterMan has joined #ruby
dbz has joined #ruby
za1b1tsu has quit [Ping timeout: 276 seconds]
darkhanb has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
ivanskie has joined #ruby
Reporter_ has joined #ruby
ReporterMan has quit [Ping timeout: 246 seconds]
Eiam has joined #ruby
dbz has quit [Ping timeout: 252 seconds]
conta1 has quit [Ping timeout: 252 seconds]
lxsameer has quit [Ping timeout: 276 seconds]
rippa has joined #ruby
kapil____ has joined #ruby
tycoon177 has joined #ruby
<tycoon177>
if i wanted to use a database connection with a sinatra app, what gems should i look at? the database that i'd need to connect to would be microsoft sqlserver
<tycoon177>
i *really* want to try Sequel at some point, but I think that this project will only need like 1 or 2 database calls so i don't think it's worth the setup
<tycoon177>
i could get by with making an API and doing this all from js actually...
<tycoon177>
maybe i'll do that
<tycoon177>
i'm going to a ruby meetup in about 30 minutes actually :) it'll be my first time going. i'm really excited
<havenwood>
tycoon177: Awesome!
sarmiena_ has quit [Read error: Connection reset by peer]
Reporter_ has quit [Remote host closed the connection]
ReporterMan has joined #ruby
<Eiam>
Sequel for sure, its pretty easy to pop into
<Eiam>
#sequel is a very helpful crew too
<tycoon177>
Eiam: is it really worth it to add that as a dependency if i really just need maybe 2 sql queries?
ReporterMan has quit [Ping timeout: 272 seconds]
MoritaShinobu has quit [Ping timeout: 252 seconds]
darkhanb has joined #ruby
nowhere_man has joined #ruby
<Eiam>
are you going to write raw SQL queries that take input from the wild or other sources?
<Eiam>
someone has to setup your DB connections and deal with the data
<Eiam>
its probably 3 lines in Sequel to have it do it for you
<Eiam>
but I'm not the one managing your code thats you =)
<havenwood>
orbyt_: I really prefer benchmark-ips for a couple reasons.
<havenwood>
orbyt_: Warmup, std deviation, etc.
lytol_ has joined #ruby
wildermind has quit [Quit: Connection closed for inactivity]
Fr4n has joined #ruby
<havenwood>
ivanskie: Rake is a good option for parallel execution of dependent tasks.
<ivanskie>
i meant serial.
<ivanskie>
one after another
<ivanskie>
unless ruby is already async?
<havenwood>
ivanskie: Rake is great for that.
<ivanskie>
right
<ivanskie>
thank you :)
dbz has joined #ruby
<apeiros_>
19:18 ivanskie: kind of in async await way..
<apeiros_>
you mean… like… normal program code? :D
<ivanskie>
lol yes :(
dbz has quit [Remote host closed the connection]
<apeiros_>
(still rake, though, as it's a good task execution framework)
dbz has joined #ruby
<ivanskie>
i forget if have def run_stuff {func1();func2();func3()}. if it runs all and doesnt wait for one to finish before the next or not.
dbz has quit [Remote host closed the connection]
<ivanskie>
dumb question now that i think about it
armyriad has quit [Read error: Connection reset by peer]
dbz has joined #ruby
armyriad has joined #ruby
jetchisel has quit [Ping timeout: 252 seconds]
cthulchu has quit [Read error: Connection reset by peer]
<apeiros_>
I'm honestly tempted to write an "async" gem which allows you to do `async { foo }; async { bar }; …`
<apeiros_>
(and all it does is `module Kernel; module_function def async(&block); Thread.new(&block); end; end`
<apeiros_>
)
<ivanskie>
heh
xfbs has quit [Quit: afk]
<apeiros_>
ok, if I'd do it well I'd actually create a Promise emulating class instead of a bare Thread.
<orbyt_>
havenwood That gem seems to be good for determining iterations per sec for a given block of code...can I use it for the use case shown in my gist?
<orbyt_>
I just want to compare executing time of string comparisons
<ivanskie>
isn't there already a gem for performance tracking?
<orbyt_>
Theres a built in benchmark thing but it's in seconds
<orbyt_>
which is too large
<orbyt_>
see my gist above
<ivanskie>
ah
<havenwood>
orbyt_: I assumed you wanted to compare execution time, not figure out how many ns it takes.
<havenwood>
orbyt_: You can easily extend it to do whatever you really want. But keep in mind that variances at the nanosecond level are extreme, so it's best to test many iterations.
mikecmpbll has joined #ruby
whysthatso has joined #ruby
<orbyt_>
havenwood Oh neat, will give that a quick go
<orbyt_>
Was just speaking to a colleague and he'd only used Benchmark as well
<havenwood>
apeiros_: I swear it was Tenderlove who announced async support in Ruby a while back with: Async = Thread
<havenwood>
>.>
<apeiros_>
aaahahaha, quite possible
<orbyt_>
havenwood Is there a reason that that only reports in 10^3 nanoseconds? Eg 4000, 5000, 6000 ns