freezey has quit [Remote host closed the connection]
staafl_alt has joined #ruby
<ziggles>
hi guys, quick gem question bc I'm not exactly sure where to start looking.... How does a gem add a command to the user's PATH? ie "rails" from the command line doesn't need to be invoked by calling ruby
staafl has quit [Ping timeout: 272 seconds]
predator117 has joined #ruby
<fryguy>
ziggles: depends a bit on your ruby config (whether you are using rvm or rbenv or something else), but it just writes things to a bin directory, and that directory is added to your path
asym has quit [Ping timeout: 255 seconds]
ryannielson has quit [Remote host closed the connection]
<postmodern>
ziggles, check `gem env`
<postmodern>
ziggles, or do `which rails`
<ziggles>
fryguy: ah ok... So just for fun i'm gonna attempt to write a pomodoro timer as a gem and i want to be able to invoke it from the command line. Does this mean that within in the gem's file structure i need to add a /bin directory and basically write a shell script that calls my script?
<fryguy>
ziggles: yep
<fryguy>
doesn't need to be a shell script, it can be ruby
chrishough has quit [Quit: chrishough]
davidh_ has joined #ruby
<ziggles>
fryguy: Oh... got it. So basically anything in /bin just gets added to PATH "for free"
<ziggles>
?
chrishough has joined #ruby
idkazuma has quit [Remote host closed the connection]
<fryguy>
yep
<ziggles>
Maybe this is a stupid question but in order for that script to execute i need to set a+x permissions on it.... but git ignores file permissions...
iamvery has quit [Remote host closed the connection]
<ziggles>
I don't really understand how when someone installs a gem the bin/ scripts can run?
<fryguy>
ziggles: ?
<ziggles>
fryguy: When you create a script that's going to be an executable, don't you need to do something like "chmod +x" to make it executable?
<fryguy>
ziggles: yes
kofno has joined #ruby
wsterling has quit [Remote host closed the connection]
<ziggles>
fryguy: i'm thinking when i push that code to github or ruby gems the +x on my script will be lost bc git ignores file ownership/permissions (to my knowledge)
<fryguy>
it doesn't
d11wtq has quit [Ping timeout: 252 seconds]
<fryguy>
also i'm guessing the gemspec takes care of it
<ziggles>
damn, i swear i read somewhere that git ignored that.
pioz has joined #ruby
jeffean has joined #ruby
pioz has quit [Client Quit]
<ziggles>
fryguy: thanks a lot sir
<ziggles>
:)
jonathanwallace has quit [Ping timeout: 252 seconds]
jnoob22 has joined #ruby
nari has joined #ruby
passerine has joined #ruby
tyl has quit [Ping timeout: 245 seconds]
csaunders has quit [Quit: Computer has gone to sleep.]
ziggles has quit [Remote host closed the connection]
idkazuma has joined #ruby
<kenichi>
any sidekiq users around?
iamvery has joined #ruby
pkrnj has joined #ruby
csaunders has joined #ruby
freezway has joined #ruby
akhet has joined #ruby
akhet has joined #ruby
akhet has quit [Changing host]
<davidh_>
has anyone here ever played around with blimlimb?
iamvery has quit [Ping timeout: 256 seconds]
<Ontolog>
can someone recommend a gem for printing out a table of values (to the terminal)?
sambao21 has joined #ruby
xcv has quit [Remote host closed the connection]
Ng|Adonixx8359 has joined #ruby
julian-delphiki has joined #ruby
freakazoid0223 has joined #ruby
chrisja has quit [Quit: leaving]
<V8Energy>
i am trying to parse json using JASON.parse but it doesn't work. here's what the variable looks like: "{\"json_class\":\"Fortune\",\"tags\":[\"fortunes\"],\"quote\":\"You should g o home.\",\"link\":\"http://iheartquotes.com/fortune/show/46962\",\"source\":\"f ortune\"}"
axxT has quit [Ping timeout: 245 seconds]
bean has quit [Ping timeout: 272 seconds]
ariedler has joined #ruby
hogeo has joined #ruby
dankest has quit [Quit: Leaving...]
Arzaga has joined #ruby
DonRichie has quit [Ping timeout: 245 seconds]
DonRichie has joined #ruby
nezumi has joined #ruby
csaunders has quit [Quit: Computer has gone to sleep.]
daniel_- has quit [Ping timeout: 252 seconds]
cloke_ has joined #ruby
mercwithamouth has quit [Ping timeout: 245 seconds]
csaunders has joined #ruby
momomomomo has quit [Ping timeout: 245 seconds]
tealmage has quit [Remote host closed the connection]
cloke has quit [Ping timeout: 245 seconds]
cloke_ is now known as cloke
three18ti has quit [Ping timeout: 245 seconds]
mercwithamouth has joined #ruby
timmow has joined #ruby
yshh has quit [Remote host closed the connection]
denbuzze4 has joined #ruby
bhaarat has quit [Quit: bhaarat]
three18ti has joined #ruby
csaunders has quit [Client Quit]
<davidh_>
there is a show going on on #blimlimb
CapnPiCards has joined #ruby
baroquebobcat has quit [Quit: baroquebobcat]
momomomomo has joined #ruby
<denbuzze4>
Hey everyone, is there a way to do the following in a neater way:
<denbuzze4>
`ENV["ENABLED"] ||= "true"` `if ENV["ENABLED"] == "true"` ? I've tried if `ENV["ENABLED"] ||= "true"` but no luck so far.
ekampf has quit [Quit: ekampf]
schickung has quit [Quit: schickung]
bhaarat has joined #ruby
idkazuma has quit [Remote host closed the connection]
timmow has quit [Ping timeout: 252 seconds]
chessguy has joined #ruby
dooleyburger has joined #ruby
Arzaga has quit [Quit: Computer has gone to sleep.]
theRoUS has joined #ruby
<Spooner>
V8Energy, That is perfectly good JSON. Are you using JASON rather than JSON?
<V8Energy>
I am using Json
Arzaga has joined #ruby
<V8Energy>
ArgumentError: can't get const Fortune: uninitialized constant Fortune
<V8Energy>
when I do puts for the variable of unparsed json, this is what I get: {"json_class":"Fortune","tags":["codehappy","pete_incavigila"],"quote":"\"People think we make $3 million and $4 million a year. They don't realize that most of us only make $500,000.\" -- Pete Incavigila, baseball player for the Texas Rang ers.","link":"http://iheartquotes.com/fortune/show/12367","source":"codehappy"}
<Spooner>
Well, what that means is that it is trying to create an object of Fortune class, which is what that JSON is a serialised version of.
<Spooner>
Though it should just happily parse it into a regular Hash.
<davidokner>
Am I right that RubMine IDE can't build the jRuby applition into an executable .jar file?
<V8Energy>
what I am doing is: response = Net::HTTP.get_response('www.iheartquotes.com','/api/v1/random?format=json&max_lines=1&max_characters=320') and then JSON.parse(response.body)
<davidokner>
I am very disapointed that I can't build the ruby applicaiton into a .jar file.
Ontolog has quit [Remote host closed the connection]
<fryguy>
and scaling/updating will be a pain. you'd be much better served to externalize the java app and expose an api for it, via soap/json-rpc/thrift/rest/0mq/rabbitmq/somethingelse
nari has joined #ruby
hmarr has quit []
sleetdrop has joined #ruby
io_syl has quit [Quit: Computer has gone to sleep.]
Vert has quit [Ping timeout: 252 seconds]
ariedler has quit [Remote host closed the connection]
soulofpeace has joined #ruby
tvw has quit [Ping timeout: 245 seconds]
pkrnj has joined #ruby
gyre007 has quit [Ping timeout: 252 seconds]
<lethjakm1>
fryguy: maybe I'm making this sound too serious. I just want to make a on/off button for my friends minecraft server.
<lethjakm1>
this doesn't need to scale.
yacks has joined #ruby
<lethjakm1>
however rabbitmq looks really cool....would you recommend it for other projects?
johnnygoodmancpa has left #ruby [#ruby]
<fryguy>
lethjakm1: so you are going ot load minecraft inside of rails?
<fryguy>
lethjakm1: yes, rabbitmq is pretty great
tealmage has quit [Ping timeout: 252 seconds]
<lethjakm1>
fryguy: no, I just want to run the command to start it and stop it from rails
<lethjakm1>
I need to check the running processes and see if it's running
<lethjakm1>
be able to kill it
<lethjakm1>
and be able to start it
<fryguy>
lethjakm1: take a minecraft init.d script and port that instead
gyre008 has quit [Ping timeout: 256 seconds]
<fryguy>
or just use god/supervisord/something else instead to do it
kpshek has joined #ruby
Vert has joined #ruby
<arubin>
lethjakm1: What you want is something else that runs the Minecraft server that responds to commands in some way.
<lethjakm1>
fryguy: would I just run the bash through ruby?
<arubin>
lethjakm1: There are many Minecraft wrappers that will probably do this.
GeissT has quit [Ping timeout: 245 seconds]
<lethjakm1>
arubin: I'm mainly just trying to figure out how to communicate with something that isn't ruby.
<arubin>
lethjakm1: You are thinking about this the wrong way.
<r0bgleeson>
lethjakm1: are you looking to be able to manage subprocesses?
<arubin>
You do not need Java and Ruby to talk at all.
<lethjakm1>
arubin: ok, who does ruby need to talk to?
<lethjakm1>
r0bgleeson: in a sense, yeah.
miroatme_ has joined #ruby
kpshek has quit [Ping timeout: 252 seconds]
<r0bgleeson>
lethjakm1: Ruby subprocesses, or Java ones?
<lethjakm1>
r0bgleeson: in this case java, I understand subprocessing within a language already
<arubin>
lethjakm1: You wrap the Minecraft server in a script which accepts external commands in some fashion.
<sickn3ss>
arubin I've read that however I can not find any way in the documentation to specify a source IP address. Which of course should be different then the IP address which sends the packet
nminus1 has quit [Ping timeout: 248 seconds]
<sickn3ss>
doing this with Scapy in Python is fine, however, I would really like to see how it can be done in Ruby
momomomomo has quit [Quit: momomomomo]
ZachBeta has joined #ruby
ukd1 has quit [Ping timeout: 256 seconds]
mythical has quit [Ping timeout: 246 seconds]
<r0bgleeson>
.bu9
nminus1 has joined #ruby
<r0bgleeson>
oops
hhyakfish has joined #ruby
Matip has quit [Ping timeout: 256 seconds]
tommyvyo has joined #ruby
wargasm has joined #ruby
mando has joined #ruby
tevio has quit [Read error: Connection reset by peer]
security has joined #ruby
tevio has joined #ruby
megha has quit [Ping timeout: 264 seconds]
dmiller has quit [Remote host closed the connection]
bradleyp_ has quit [Remote host closed the connection]
freeayu has joined #ruby
radic has joined #ruby
LaPetiteFromage has quit [Quit: LaPetiteFromage]
shevy has quit [Ping timeout: 246 seconds]
wsterling has joined #ruby
ckrailo has quit [Quit: Computer has gone to sleep.]
jandres has left #ruby ["ERC Version 5.3 (IRC client for Emacs)"]
kelabot has quit [Remote host closed the connection]
pietr0 has quit [Remote host closed the connection]
pietr0 has joined #ruby
gtuckerkellogg has quit [Ping timeout: 248 seconds]
<bnagy>
ok then I'm out of ideas :) You probably need to ask the gem maintainer
<bnagy>
it's not a ruby bug
dmiller has quit [Ping timeout: 264 seconds]
DefV has quit [Ping timeout: 248 seconds]
<Chepra_>
ok, thanks
baphled_ has quit [Ping timeout: 252 seconds]
Jan_ has joined #ruby
Jan_ is now known as DefV
tealmage has joined #ruby
niklasb has joined #ruby
MrZYX|off is now known as MrZYX
tonini has quit [Remote host closed the connection]
emergion has joined #ruby
tealmage has quit [Ping timeout: 245 seconds]
baphled has joined #ruby
niceguyjames has quit [Quit: Computer has gone to sleep.]
dhruvasagar has quit [Ping timeout: 256 seconds]
dhruvasagar has joined #ruby
kelabot has joined #ruby
clocKwize has joined #ruby
idletom has quit [Ping timeout: 256 seconds]
baphled has quit [Ping timeout: 245 seconds]
timmow_ has joined #ruby
maxmanders has quit [Quit: Computer has gone to sleep.]
locriani_ has quit [Remote host closed the connection]
freeayu has quit [Ping timeout: 245 seconds]
yxhuvud2 has joined #ruby
emergion has quit [Quit: Computer has gone to sleep.]
gener1c has joined #ruby
timmow_ has quit [Ping timeout: 252 seconds]
yxhuvud has quit [Ping timeout: 256 seconds]
Chepra_ has quit [Quit: Chepra_]
beiter has quit [Quit: beiter]
freeayu has joined #ruby
dhruvasagar has quit [Read error: Connection reset by peer]
marcdel_ has quit []
rickmasta has quit [Quit: Leaving...]
Zai00 has joined #ruby
nari has quit [Ping timeout: 245 seconds]
Zai00 has quit [Client Quit]
teddyp1cker has joined #ruby
dhruvasagar has joined #ruby
daniel_- has quit [Quit: WeeChat 0.4.0]
jeffreylevesque_ has quit [Read error: Connection reset by peer]
jeffreylevesque has joined #ruby
tesuki has quit [Remote host closed the connection]
emergion has joined #ruby
ehellman has joined #ruby
hemanth has quit [Read error: Connection reset by peer]
security has joined #ruby
megha has quit [Ping timeout: 245 seconds]
backjlack has quit [Remote host closed the connection]
tonini has joined #ruby
backjlack has joined #ruby
security has quit [Excess Flood]
chussenot has quit [Ping timeout: 276 seconds]
vlad_sta_ has joined #ruby
timonv has quit [Ping timeout: 245 seconds]
security has joined #ruby
Astral__ has joined #ruby
robottinosino has quit [Quit: WeeChat 0.4.0]
cantonic has quit [Ping timeout: 272 seconds]
Astral__ has quit [Client Quit]
Spooner has joined #ruby
gyre007 has joined #ruby
gyre008 has joined #ruby
gyre008 has quit [Max SendQ exceeded]
LongLiveBacon has joined #ruby
chussenot has joined #ruby
timonv has joined #ruby
Astralum has joined #ruby
tonini has quit [Ping timeout: 248 seconds]
vlad_starkov has quit [Ping timeout: 245 seconds]
cantonic has joined #ruby
niklasb has quit [Ping timeout: 264 seconds]
enriclluelles has joined #ruby
robottinosino has joined #ruby
rakl has quit [Quit: sleeping]
swex has joined #ruby
ry4nn has quit [Remote host closed the connection]
robottinosino has quit [Client Quit]
ry4nn has joined #ruby
Astral_ has quit [Ping timeout: 264 seconds]
soc42 has joined #ruby
niceguyjames has joined #ruby
gyre008 has joined #ruby
ARCADIVS has quit [Quit: WeeChat 0.3.8]
gyre008 has quit [Max SendQ exceeded]
gyre008 has joined #ruby
chase-work has joined #ruby
robottinosino has joined #ruby
bradhe has joined #ruby
gener1c has quit [Ping timeout: 240 seconds]
jeebster has quit [Quit: Leaving.]
tonini has joined #ruby
bradhe has quit [Ping timeout: 245 seconds]
<martinklepsch>
Having a Time object is there a way to shift it by one month similar to whats possible with << for Date?
passerine has left #ruby ["Ex-Chat"]
MrZYX is now known as MrZYX|off
dmiller has joined #ruby
timonv has quit [Ping timeout: 246 seconds]
sayan has joined #ruby
yasu has quit [Ping timeout: 256 seconds]
miso1337 has quit [Ping timeout: 246 seconds]
EvErLaSt has joined #ruby
techlife has quit [Ping timeout: 252 seconds]
coldie_ has joined #ruby
timonv has joined #ruby
slainer68 has quit [Read error: Connection reset by peer]
yasu has joined #ruby
cpruitt has quit [Read error: Connection reset by peer]
TheNixNinja has quit [Read error: Connection reset by peer]
pcarrier has quit [Quit: Computer has gone to sleep.]
slainer68 has joined #ruby
cpruitt has joined #ruby
dmiller has quit [Ping timeout: 264 seconds]
techlife has joined #ruby
techlife has quit [Max SendQ exceeded]
coldie has quit [Ping timeout: 256 seconds]
backjlack has quit [Remote host closed the connection]
techlife has joined #ruby
hiyakashi has joined #ruby
h0rnyFut has quit [Ping timeout: 248 seconds]
miso1337 has joined #ruby
tesuki has joined #ruby
mneorr has quit [Remote host closed the connection]
codenapper has quit [Quit: codenapper]
tealmage has joined #ruby
LnL has quit [Quit: LnL]
bijumon has joined #ruby
tesuki has quit [Remote host closed the connection]
tesuki has joined #ruby
adkron_ has joined #ruby
bulters has quit [Ping timeout: 255 seconds]
tonini has quit [Remote host closed the connection]
tealmage has quit [Ping timeout: 252 seconds]
a_a_g has quit [Quit: This computer has gone to sleep]
maxmanders has joined #ruby
LongLiveBacon has quit [Ping timeout: 240 seconds]
mneorr has joined #ruby
forlin has joined #ruby
adkron has quit [Ping timeout: 255 seconds]
tonini has joined #ruby
schickung has joined #ruby
bulters has joined #ruby
schickung has quit [Client Quit]
jnoob22 has joined #ruby
niklasb has joined #ruby
arturaz has quit [Ping timeout: 245 seconds]
sylvinus has quit [Quit: sylvinus]
Mon_Ouie has joined #ruby
davetherat has quit [Remote host closed the connection]
davetherat has joined #ruby
rippa has quit [Ping timeout: 240 seconds]
evenix has joined #ruby
miso1337 has quit [Quit: afk]
timmow_ has joined #ruby
dmiller has joined #ruby
yxhuvud has joined #ruby
tommyvyo has joined #ruby
iamvery has joined #ruby
yxhuvud2 has quit [Ping timeout: 264 seconds]
k610 has joined #ruby
timmow_ has quit [Ping timeout: 252 seconds]
gyre007_ has joined #ruby
gyre007_ has quit [Remote host closed the connection]
bluOxigen has quit [Ping timeout: 256 seconds]
dmiller has quit [Ping timeout: 245 seconds]
k611 has joined #ruby
arya has joined #ruby
maxmanders has quit [Quit: Computer has gone to sleep.]
iamvery has quit [Ping timeout: 252 seconds]
vlad_starkov has joined #ruby
swex_ has joined #ruby
gyre008 has quit [Ping timeout: 245 seconds]
swex has quit [Ping timeout: 245 seconds]
gyre007 has quit [Ping timeout: 252 seconds]
kelabot has quit [Ping timeout: 264 seconds]
browndawg has quit [Ping timeout: 245 seconds]
postmodern has quit [Quit: Leaving]
gyre007 has joined #ruby
gyre007 has quit [Max SendQ exceeded]
vlad_starkov has quit [Remote host closed the connection]
gyre007 has joined #ruby
vlad_sta_ has quit [Ping timeout: 245 seconds]
gyre007 has joined #ruby
vlad_starkov has joined #ruby
gyre008 has joined #ruby
gyre008 has quit [Max SendQ exceeded]
sylvinus has joined #ruby
wmoxam has joined #ruby
gyre008 has joined #ruby
mikecmpbll has joined #ruby
LongLiveBacon has joined #ruby
adkron has joined #ruby
ZuzzleBuzzer has joined #ruby
smiler has joined #ruby
adkron_ has quit [Ping timeout: 246 seconds]
niceguyjames has quit [Quit: Computer has gone to sleep.]
vlad_starkov has quit [Ping timeout: 264 seconds]
threesome has quit [Ping timeout: 245 seconds]
Domon has quit [Remote host closed the connection]
genta has quit [Read error: Connection reset by peer]
netto has quit [Quit: netto]
cmar has joined #ruby
genta has joined #ruby
netto has joined #ruby
thebastl has quit [Remote host closed the connection]
parallel211 has joined #ruby
backjlack has joined #ruby
kofno has joined #ruby
freeayu has quit [Ping timeout: 245 seconds]
backjlack has quit [Remote host closed the connection]
F1skr has joined #ruby
Zai00 has joined #ruby
tvw has joined #ruby
sleetdrop has quit [Ping timeout: 256 seconds]
LongLiveBacon has quit [Ping timeout: 264 seconds]
backjlack has joined #ruby
freeayu has joined #ruby
ehellman has quit []
parallel211 has left #ruby [#ruby]
bradhe has joined #ruby
pcarrier has joined #ruby
enriclluelles has quit [Remote host closed the connection]
hiyakashi has quit [Quit: お前は知りすぎた]
chussenot has quit [Quit: chussenot]
threesome has joined #ruby
<Spooner>
martinklepsch, Use DateTime instead?
bradhe has quit [Ping timeout: 260 seconds]
<injekt>
time + 2419200
pioz has joined #ruby
<injekt>
but yeah I'd use DateTime too
<injekt>
then you can do >> or << on the DateTime object, and do to_time to get your Time object back
oneirophren has joined #ruby
teddyp1cker has quit [Remote host closed the connection]
chase-work has quit [Quit: Computer has gone to sleep.]
pac1 has joined #ruby
gyre007 has quit [Remote host closed the connection]
gyre008 is now known as gyre007
Asher has quit [Read error: Connection reset by peer]
gyre007 has quit [Quit: Computer has gone to sleep.]
yshh has quit [Remote host closed the connection]
adkron_ has joined #ruby
dhruvasagar has quit [Ping timeout: 260 seconds]
tealmage has joined #ruby
spider-mario has joined #ruby
dhruvasagar has joined #ruby
JonnieCache has quit [Ping timeout: 245 seconds]
adkron has quit [Ping timeout: 264 seconds]
wmoxam has quit [Ping timeout: 264 seconds]
allanm has joined #ruby
perun0 has quit [Ping timeout: 256 seconds]
balishag has joined #ruby
tealmage has quit [Ping timeout: 248 seconds]
gyre007 has joined #ruby
gyre008 has joined #ruby
skattyadz has joined #ruby
netto_ has joined #ruby
netto has quit [Ping timeout: 252 seconds]
MisterPostIT has quit [Changing host]
MisterPostIT has joined #ruby
netto_ is now known as netto
subbyyy has joined #ruby
kelabot has joined #ruby
divout has quit [Remote host closed the connection]
coderhut has quit [Quit: Page closed]
Chepra_ has joined #ruby
browndawg has joined #ruby
bhaarat has joined #ruby
dooleyburger has joined #ruby
timmow_ has joined #ruby
yxhuvud2 has joined #ruby
perun0 has joined #ruby
thatRD has joined #ruby
r0bgleeson has joined #ruby
yxhuvud has quit [Ping timeout: 245 seconds]
soc42 has quit [Remote host closed the connection]
timmow_ has quit [Ping timeout: 252 seconds]
danneu has quit [Ping timeout: 245 seconds]
lmf40 has joined #ruby
mark_locklear has joined #ruby
tyl_ has joined #ruby
kornnflake has quit [Ping timeout: 264 seconds]
tyl has quit [Ping timeout: 255 seconds]
tyl_ is now known as tyl
netto has quit [Ping timeout: 260 seconds]
kornnflake has joined #ruby
netto has joined #ruby
centipedefarmer has joined #ruby
keymone has quit [Quit: keymone]
pac1 has quit [Quit: I got it one line of code at a time]
k610 has quit [Quit: Leaving]
tevio has quit [Remote host closed the connection]
JonnieCache has joined #ruby
krz has quit [Quit: krz]
LongLiveBacon has joined #ruby
<guardian>
hello, I'm using builder to build my atom feed. how to prevent feed.title from being escaped?
<guardian>
is there something less verbose than using << ?
ZuzzleBuzzer has quit [Quit: ZuzzleBuzzer]
pac1 has joined #ruby
niceguyjames has joined #ruby
pac1 has quit [Remote host closed the connection]
sayan has quit [Read error: Connection reset by peer]
cmyers_ has joined #ruby
dawkirst has quit [Ping timeout: 255 seconds]
xcv has joined #ruby
<cmyers_>
so I have a class full of rspec tests (class FooTest < ActionController::IntegrationTest) where each test is named "test_blah". I want to take some subset of these tests, and run them twice with two different parameters (say, http and https). What is the best way to structure/refactor this?
<cmyers_>
I was thinking I could rename teh methods to not start with test_, then make test_http and test_https that calls each appropriate test, is there some way to pass a list of function names to add them to the queue or something?
divout has joined #ruby
mercwithamouth has joined #ruby
mneorr has quit [Remote host closed the connection]
vlad_starkov has joined #ruby
slainer68 has quit [Read error: Connection reset by peer]
slainer68 has joined #ruby
LongLiveBacon has quit [Ping timeout: 255 seconds]
<JoeHazzers>
how should i be structuring my classes (which use networking), so that they are easy to test?
sambao21 has joined #ruby
<bnagy>
LOL
niklasb has quit [Ping timeout: 246 seconds]
mercwithamouth has quit [Ping timeout: 256 seconds]
tommyvyo has quit [Quit:]
vlad_starkov has quit [Read error: Connection reset by peer]
geekbri has joined #ruby
<cmar>
JoeHazzers you want to encapsulate all the networking calls in a class, then you can mock that class in your tests
<JoeHazzers>
okay
<cmar>
JoeHazzers its best to avoid making actual network calls in the tests
<JoeHazzers>
yeah, i was wondering how to go about emulating the network, though
xcv has quit [Remote host closed the connection]
<JoeHazzers>
which i suppose i can do easily if i structure my app like that
bradhe has joined #ruby
xcv has joined #ruby
<cmar>
JoeHazzers exactly, then if you want to write tests for the class that makes the network calls, you can use something like VCR
tommyvyo has joined #ruby
rlb3 has joined #ruby
Czupa has joined #ruby
beiter has joined #ruby
<cmyers_>
JoeHazzers: if you are using any http client in ruby, see WebMock
<cmyers_>
if not, try to do somethign similar using a generic mocking lib like Mocha
dawkirst has joined #ruby
<cmyers_>
hmm, Looks like Test::Unit has testsuites that will let me do what I need to
ryannielson has joined #ruby
bradhe has quit [Ping timeout: 260 seconds]
sthetz has joined #ruby
skattyadz has quit [Quit: skattyadz]
kurk has joined #ruby
nickbuff has joined #ruby
tk has joined #ruby
Neandre has joined #ruby
tk is now known as Guest93367
<emergion>
What do most people recommend when handling config files for their ruby applications ? I find Ruby misses the boat a little in that department ?
yalue has joined #ruby
v0n has joined #ruby
carloslopes has joined #ruby
<Banistergalaxy>
Emergion ruby or yaml
<emergion>
Banistergalaxy, yeah cool, seems like you have to do a fair bit of hacking though
jnoob22 has quit [Remote host closed the connection]
<Banistergalaxy>
No..
jnoob22 has joined #ruby
NiteRain has quit [Ping timeout: 256 seconds]
tommyvyo has quit [Quit:]
niceguyjames has quit [Quit: Computer has gone to sleep.]
goganchic has joined #ruby
<emergion>
Banistergalaxy, got an example ?
<Banistergalaxy>
I'm on phone, at gym right now sry
pskosinski has joined #ruby
<cmyers_>
isn't it just somethign like config_hash = YAML.parse(yml_file_path) to read it in, and File.open(...) {|f| f.write(config_hash.to_yml) } to write it out
Al___ has joined #ruby
<cmyers_>
go read the rdocs for the YAML module
skattyadz has joined #ruby
tealmage has joined #ruby
<Mon_Ouie>
How is it not just that?
jnoob22 has quit [Ping timeout: 245 seconds]
ZachBeta has quit [Quit: Computer has gone to sleep.]
<emergion>
cmyers_, sure, that will give you a hash. But that's all. It becomes hopeless when you want to do things like have nested data and check if values exist IMO
<sthetz>
I'm struggling with nokogiri segfaulting when parsing a lot of xml/html in many threads.Celluloid or native ruby threads — doesn't matter, segfaults anyway.
tealmage has quit [Read error: Connection reset by peer]
<Mon_Ouie>
Oh, I misread that
<Mon_Ouie>
emergion: You can have nested hashes, use Hash#has_key?, etc.
tealmage has joined #ruby
jnoob22 has joined #ruby
<emergion>
Mon_Ouie, sure. But I would prefer my code is not littered with logic like that
<Hanmac2>
ntzrmtthihu777: did you use some toolkit for the ingame gui?
yshh has quit [Ping timeout: 256 seconds]
<ntzrmtthihu777>
hmm? what you mean?
generalissimo has joined #ruby
mayankkohaley has quit [Ping timeout: 252 seconds]
mneorr has joined #ruby
timmow_ has joined #ruby
yxhuvud has joined #ruby
<Hanmac2>
ntzrmtthihu777: in our project i want to use something like that http://www.cegui.org.uk/wiki for ingame gui
basex has joined #ruby
wmoxam has joined #ruby
Jalada is now known as Pxibot
NimeshNeema has joined #ruby
Pxibot is now known as Jalada
Xeago has joined #ruby
yxhuvud2 has quit [Ping timeout: 264 seconds]
<ntzrmtthihu777>
Hanmac2: the in-game gui is based off of "window skins", a png file containing 1. the fill color of the window 2. the border style. 3. a highlight cursor, and 4. a host of odds and ends arrows and such. these are layed out in a standard manner and stretched & tiled as needed.
jeffreylevesque_ has joined #ruby
yekta has joined #ruby
<Hanmac2>
ntzrmtthihu777: yeah its because yours copies the older enterbrain makers .. for our project i plan an total rebirth
hasse has joined #ruby
timmow_ has quit [Ping timeout: 252 seconds]
hmarr has quit [Ping timeout: 252 seconds]
<ntzrmtthihu777>
*shrug* I'm making this for the community I'm part of. I want it to be familiar, but more powerful and flexible.
<hasse>
I'm using the 'pg' lib. Is there a way to see the query that is actually executed? Can't find a logger.
whowantstolivefo has joined #ruby
hmarr has joined #ruby
danneu has quit [Ping timeout: 252 seconds]
jeffreylevesque has quit [Ping timeout: 264 seconds]
Gwyxx has quit [Quit: Leaving]
<Hanmac2>
currently ours are familar too, so you have Actors and Enemies, but you have more fun inside like passive abilities or other funny things like enemies can hold equipment too
LnL has joined #ruby
<ntzrmtthihu777>
Hanmac2: quite frankly I'm not just cloning XP.
browndawg has quit [Ping timeout: 245 seconds]
chussenot has joined #ruby
tealmage has quit [Remote host closed the connection]
<Hanmac2>
you can show me some code if you want ;P
Hanmac has joined #ruby
<ntzrmtthihu777>
bleh, its nothing fancy. I'm just working on creating the "blank game", then I'll build the editor around it.
<Hanmac2>
we did the other way areound, some features of the editor, like the map is working, but the game is not finish yet (currently i write on a new script engine )
DonRichie has quit [Ping timeout: 256 seconds]
browndawg has joined #ruby
<ntzrmtthihu777>
heh. I've been pulling resources from the community, polls and such
DonRichie has joined #ruby
<ntzrmtthihu777>
finding out what is needed & wanted by the community.
hogeo has quit [Remote host closed the connection]
<Hanmac2>
we will see, maybe you wants to join us with our project later ...
enriclluelles has joined #ruby
jerius has joined #ruby
<ntzrmtthihu777>
I don't think we're heading in the same direction.
ekampf has joined #ruby
<ntzrmtthihu777>
enterbrain already stole from our sdk code :/
kofno has quit [Remote host closed the connection]
sailias has joined #ruby
vlad_starkov has joined #ruby
iamvery has joined #ruby
<Hanmac2>
löl
<ntzrmtthihu777>
folk put alot of work into the RPG Maker XP sdk, then they release XV with the exact same code :/
nezumi has quit [Ping timeout: 245 seconds]
jonathanwallace has quit [Quit: WeeChat 0.3.9.2]
wolcanus has joined #ruby
wolcanus has quit [Remote host closed the connection]
Scriptor has joined #ruby
tommyvyo has joined #ruby
akemrir has joined #ruby
<ntzrmtthihu777>
*shrug* oh well. full circle it came, and here I am working on this :P
<Hanmac2>
ntzrmtthihu777: with the exact same errors too? (i remember that vx and ace had some bugs inside the scripts part)
wolcanus has joined #ruby
akemrir has quit [Client Quit]
ekampf has quit [Ping timeout: 240 seconds]
<ntzrmtthihu777>
exact same errors in vx or in my project?
akemrir has joined #ruby
jtharris has joined #ruby
<Hanmac2>
no i mean that if enterbrain stoles your code, does it stole your possible errors too? ;P
tevio has joined #ruby
<ntzrmtthihu777>
lol, not my code, the community's. before my joining.
<ntzrmtthihu777>
interesting concept, I'll ask one of the old timers about it next time they are in channel
v0n has quit [Ping timeout: 245 seconds]
ananthakumaran has quit [Quit: Leaving.]
bhaarat has quit [Quit: bhaarat]
chussenot has quit [Quit: chussenot]
<Hanmac2>
ntzrmtthihu777: i will show you more of our project ... when there is more to shown ... like i said i am currently at the scripting part .. and i mean this part that does not use gui
<cmyers_>
goddamnit, I just spent 30 minutes starting at my test wondering why the fuck it wasn't making the call it was supposed to
<cmyers_>
then I realized I wrote the caching TOO good
cmarques has joined #ruby
solidoodlesuppor has joined #ruby
<cmyers_>
and this behavior was intentional =|
tonini has quit [Remote host closed the connection]
codecop has quit [Read error: Connection reset by peer]
<ntzrmtthihu777>
cmyers_: always sucks when you're better than you think you are XD
d11wtq has joined #ruby
niklasb has joined #ruby
jgarvey has joined #ruby
camilasan has quit [Remote host closed the connection]
sambao21 has quit [Quit: Computer has gone to sleep.]
hasse has quit [Ping timeout: 245 seconds]
chussenot has joined #ruby
chrisja has joined #ruby
arya_ has joined #ruby
puppeh has quit [Remote host closed the connection]
bradhe has joined #ruby
tonini has joined #ruby
quazimodo has quit [Ping timeout: 245 seconds]
uris has joined #ruby
newUser1234 has joined #ruby
dallasm has joined #ruby
thone_ has joined #ruby
thone has quit [Read error: Operation timed out]
arya has quit [Ping timeout: 276 seconds]
newUser1234 has quit [Remote host closed the connection]
hiyakashi has quit [Quit: お前は知りすぎた]
acrussell has joined #ruby
catphish has joined #ruby
catphish has quit [Changing host]
catphish has joined #ruby
bradhe has quit [Ping timeout: 264 seconds]
skattyadz has quit [Quit: skattyadz]
<catphish>
what is the best way to embed UTF8 strings in ascii ruby code?
Hanmac1 has joined #ruby
<catphish>
currently I am doing (as an example) "Respuesta autom\u00E1tica".force_encoding('UTF-8')
Czupa has quit [Remote host closed the connection]
Hanmac has quit [Ping timeout: 245 seconds]
Hanmac2 is now known as Hanmac
Mattx has quit [Ping timeout: 245 seconds]
mellow880 has joined #ruby
mneorr has quit [Read error: Connection reset by peer]
mneorr_ has joined #ruby
elux has joined #ruby
skattyadz has joined #ruby
skattyadz has quit [Client Quit]
<mellow880>
hi
<mellow880>
if I create two threads one after the other, the second one does not start
Morkel has quit [Quit: Morkel]
<mellow880>
anyone knows why?
gyre007 has quit [Remote host closed the connection]
<mellow880>
like Thread.new(func1()) Thread.new(func2()) , func2 won't start
elux has quit [Remote host closed the connection]
gyre007 has joined #ruby
security is now known as megha
unflores has joined #ruby
techlife has quit [Ping timeout: 276 seconds]
<netto>
i have some data in html format, but now I'm only accepting plain text in my textarea, the problem is: how do I do when update a record that have html? I can strip_tags but I'd like to know if exist a way to keep some formats, like line breaks.
CaptainKnots has quit [Quit: bazinga!]
dallasm has quit [Remote host closed the connection]
dallasm has joined #ruby
cody--1 has joined #ruby
cody--1 has left #ruby [#ruby]
<netto>
can someone help me?
<catphish>
mellow880: i normally start threds with a block like this: Thread.new {some_instance.do_something}
techlife has joined #ruby
<ericwood>
I encountered this exact problem recently...
techlife has quit [Max SendQ exceeded]
Criztian has quit [Remote host closed the connection]
<ericwood>
netto: I couldn't find a reliable way...
<netto>
;/
rdark has quit [Quit: Lost terminal]
<waxjar_>
net to just store the text in your database like that, but when displaying it convert characters to html entities
<catphish>
netto: sounds like a framework question
_cupnoodles has joined #ruby
<netto>
i'm searching, but it's dificult
techlife has joined #ruby
techlife has quit [Max SendQ exceeded]
<catphish>
netto: are you using some framework?
sambao21 has joined #ruby
<netto>
rails
<ericwood>
nokogiri will help, but you want to convert <br> and <p>s to whitespace
rdark has joined #ruby
<catphish>
netto: then ask in #rubyonrails
<waxjar_>
there's probably something in your template engine that'll take care of it. if not check out CGI in the std lib, it can escape and unescape HTML
<catphish>
they will know better
<netto>
maybe sanitize
techlife has joined #ruby
techlife has quit [Max SendQ exceeded]
<ericwood>
sanitize won't do what you want
<netto>
ok, thank you guys
<akhet>
np
<ericwood>
you can strip all tags and crap, but you won't get the linebreaks you want other than the ones that are already there
<netto>
ericwood: why?
<ericwood>
because
<catphish>
also, it doesn't make sense to store formatted data, usually better to format it when you print it
<ericwood>
that's how it is
techlife has joined #ruby
techlife has quit [Max SendQ exceeded]
lex_ has joined #ruby
<lex_>
hello
arya_ has quit [Ping timeout: 248 seconds]
<ericwood>
catphish: WYSIWYG editors are the issue
<lex_>
can someone explain what "<% if something -%>" means? if some variable = true?
Banistergalaxy has quit [Ping timeout: 272 seconds]
jbueza has joined #ruby
skattyadz has joined #ruby
danslo has joined #ruby
ekampf has quit [Quit: ekampf]
carloslopes has quit [Remote host closed the connection]
<smiler>
I've found a breaking change in ruby 2.0s mkmf makefile generator. When using create_makefile('foo/foo') to get an external lib file foo.so to be put into lib/foo/foo.so it will actually put the binary into lib and be named foo if the gems lib directory doesn't already have that foo directory for some other reason. Anyone know about a workaround for this.?
Assurbanipal has quit [Remote host closed the connection]
Voodoofish430 has joined #ruby
Banistergalaxy has joined #ruby
<smiler>
Placing a dummy file into lib/foo and including it in the gemspec is one workaround that works
banjara has joined #ruby
tesuki has joined #ruby
lukeholder has joined #ruby
wolcanus has quit [Ping timeout: 252 seconds]
adamjleonard has joined #ruby
jblack has joined #ruby
iamjarvo has joined #ruby
<iamjarvo>
is there an end of life policy somewhere?
retry has joined #ruby
<iamjarvo>
basically i want to read what the end of life means
theRoUS_ has quit [Changing host]
theRoUS_ has joined #ruby
theRoUS has quit [Disconnected by services]
theRoUS_ is now known as theRoUS
skattyadz has quit [Read error: Connection reset by peer]
theRoUS_ has joined #ruby
Vainoharhainen has quit [Quit: Leaving...]
<iamjarvo>
found a snippet
<iamjarvo>
thank you
momomomomo has quit [Ping timeout: 264 seconds]
mellow888 has joined #ruby
tesuki has quit [Remote host closed the connection]
<mellow888>
hi
<mellow888>
anyone experienced with threads?
dhruvasagar has quit [Ping timeout: 255 seconds]
sambao21 has quit [Quit: Computer has gone to sleep.]
mattbl has joined #ruby
pdswan has quit [Quit: pdswan]
pdswan has joined #ruby
yxhuvud2 has joined #ruby
heliumsocket has joined #ruby
mityaz has joined #ruby
ariedler has quit [Remote host closed the connection]
axl_ has joined #ruby
ariedler has joined #ruby
asym has joined #ruby
yxhuvud has quit [Ping timeout: 258 seconds]
Rym has quit [Quit: Rym]
miso1337 has joined #ruby
sambao21 has joined #ruby
arya__ has joined #ruby
filipe has quit [Remote host closed the connection]
Czupa has joined #ruby
<mellow888>
?
anderson has joined #ruby
dooleyburger has quit [Quit: This computer has gone to sleep]
<MrZYX>
mellow888: meta question
<mellow888>
haha
<mellow888>
my question is
<mellow888>
I have the followingcode t1 = Thread.new do puts "a" end t2 = Thread.new do puts "b" end t1.join t2.join
arya has quit [Ping timeout: 246 seconds]
cloke has joined #ruby
bradhe has quit [Remote host closed the connection]
<axl_>
elaptics: what if my variable is either a nil or an empty string ?
<tommylommykins>
"hello" if "".empty?
heliumsocket has quit [Quit: heliumsocket]
<elaptics>
axl_: what is the purpose of the line itself?
<martinklepsch>
r0bgleeson, Hanmac: thanks for your feedback :)
<axl_>
well, i have a variable which is a string or a nil
<axl_>
and if it is an nil or an empty string i want to return the default
Rym has joined #ruby
<tommylommykins>
mellow888: what's happening at the moment is that Ruby is creating the two threads, and then instantly exiting without waiting for the threads to finish what they're doing first
<axl_>
and i was hoping to not write too many if conditions - make it more axiomatic
<tommylommykins>
axl_: variable = default if special_case.empty?
Al___ has quit [Quit: Al___]
maxmanders has joined #ruby
<ChristianS>
axl_: x = 'hello' if x.nil? || x.empty?
<elaptics>
axl_: so temp = a_var_which_might_be_nil_or_empty || "hello" # meaning you always want temp to not be nil or an empty string?
AxonetBE has quit [Quit: Leaving.]
<axl_>
no
<tommylommykins>
elaptics: that doesn't work if the var is empty
<elaptics>
tommylommykins: I'm just asking what the specific functionality required is
unstable has quit [Changing host]
unstable has joined #ruby
<axl_>
temp = my_var || 'default' where i want temp never to be nil or empty
<axl_>
and my_var can be nil or empty
<axl_>
but its actually not a local variable it is a value from a hash
<elaptics>
axl_: that's what I was asking, so if my_var is "bob" then temp would == "bob"
moofy has left #ruby [#ruby]
<axl_>
yep
Nom- has quit [Read error: Operation timed out]
niceguyjames has quit [Quit: Computer has gone to sleep.]
<tommylommykins>
temp = default if temp.empty?
<elaptics>
axl_: so it's actually a hash param…that makes it easy :)
<axl_>
how so ?
<axl_>
is there a method on hash ?
Asher has joined #ruby
Nom- has joined #ruby
<elaptics>
axl_: temp = hash.fetch(:key_of_value_that_might_exist, "default value if not")
buibex has quit [Remote host closed the connection]
dooleyburger has quit [Ping timeout: 256 seconds]
<elaptics>
axl_: read the ruby docs for the #fetch method on hashes
<axl_>
hmmm… sounds good. ill use that
<Hanmac>
elaptics: fetch does not work if the key is empty ""
emergion has quit [Quit: Computer has gone to sleep.]
petrjanda_ has joined #ruby
pioz has joined #ruby
petrjanda_ has quit [Remote host closed the connection]
petrjanda has quit [Ping timeout: 252 seconds]
<Hanmac>
axl_ & elaptics: you can use hash = hash.reject {|k,v| v.nil? || v.empty?} and then hash.fetch ... (or better, use a good merge way ... moment ...)
<Hanmac>
axl_ & elaptics: use this: hash = hash.merge(defaut_values) { |key,old,new| old.nil? || old.empty? ? new : old }
cloke has quit [Ping timeout: 245 seconds]
<elaptics>
axl_: yeah, I guess ultimately it depends on what you're really looking for. Would be helpful if you posted your real code. Is it that it's the value of a hash key that could be nil or empty which you want to then set a default on?
maxmanders has joined #ruby
vlad_starkov has quit [Ping timeout: 272 seconds]
wolcanus has joined #ruby
rakl has joined #ruby
fmhr has quit [Read error: Connection reset by peer]
fmhr has joined #ruby
cloke has joined #ruby
Criztian has joined #ruby
<axl_>
so, basically i am setting a locale like this: Globalize.locale = params[:lang] || I18n.locale
<axl_>
elaptics: since you think the code would help
Criztian has quit [Remote host closed the connection]
zeade has joined #ruby
<axl_>
interesting
<axl_>
thats helpful
<axl_>
i am trying to resolve a bug, in which Globalize.locale is getting set incorrectly
<axl_>
and looking through several possibilities
<axl_>
and then was trying to figure out better ways of setting my locale
danslo has quit [Quit: danslo]
<axl_>
anyways, this has been helpful. Thanks guys
maxmanders has quit [Ping timeout: 258 seconds]
dhruvasagar has joined #ruby
Guest93367 has quit [Quit: ばいばい]
mityaz has quit [Quit: See ya!]
jeebster has joined #ruby
schickung has joined #ruby
carloslopes has joined #ruby
heliumsocket has joined #ruby
xcv has quit [Ping timeout: 255 seconds]
<jeebster>
are there any convenience methods for stripping text of encoded characters? I've had someone enter a ™ symbol and it becomes a ?, I assume because of a copy-pasted character from the internet with some funky encoding
asgardBSD_ has joined #ruby
asgardBSD_ has quit [Client Quit]
s2013 has joined #ruby
asgardBSD_ has joined #ruby
xScaryKid has joined #ruby
kelabot has joined #ruby
s2013_ has joined #ruby
s2013_ has left #ruby [#ruby]
s2013 has quit [Read error: Connection reset by peer]
supernullset has joined #ruby
niklasb has joined #ruby
psyprus_ has joined #ruby
schickung has quit [Quit: schickung]
enriclluelles has quit [Remote host closed the connection]
Chinorro has quit [Remote host closed the connection]
psyprus has quit [Read error: Connection reset by peer]
sambao21 has quit [Quit: Computer has gone to sleep.]
Zolo has joined #ruby
mayankkohaley has quit [Ping timeout: 252 seconds]
Nisstyre-laptop has quit [Quit: Leaving]
<bean>
jeebster: what ruby version are you using?
<jeebster>
bean: 1.9.3
<jeebster>
is this a utf-8 issue?
miso1337 has quit [Quit: afk]
axl_ has quit [Quit: axl_]
ph^ has quit [Remote host closed the connection]
<bean>
well, how are you getting the text
asgardBSD_ has quit [Read error: Connection reset by peer]
<bean>
is this rails magic?
<bean>
lol
gyre007 has quit [Read error: Connection reset by peer]
<Hanmac>
bean: look at str.encode it has options what todo with invalid or undefined chars
camilasan has quit [Remote host closed the connection]
hmarr has quit [Read error: Connection reset by peer]
s2013 has joined #ruby
<jeebster>
bean: lol, I dunno. something a client is entering in a form
<bean>
is true.
<bean>
jeebster: ah, so likely a rails project, you may want to look at how the string is getting encoded.
<bean>
like what Hanmac said
gyre007 has joined #ruby
kpshek has quit []
<jeebster>
bean: yes, a rails project. ah, this must be an encoding set at the application level
<bean>
likely
locriani has quit [Remote host closed the connection]
<bean>
your question might be better suited for a rails channel
chussenot has quit [Ping timeout: 264 seconds]
Neandre has quit [Remote host closed the connection]
pcarrier has quit [Quit: Computer has gone to sleep.]
idkazuma has quit [Remote host closed the connection]
<jeebster>
yes, I appreciate the response regardless
adamjleonard has quit [Quit: Leaving...]
rupee has joined #ruby
hmarr has joined #ruby
<jeebster>
how can I determine what encoding is used for a character, say ™ in OSX
hamakn has quit [Remote host closed the connection]
Coolhand has joined #ruby
ssvo has quit [Ping timeout: 246 seconds]
chrishunt has joined #ruby
pioz has quit [Quit: This computer has gone to sleep]
generalissimo has joined #ruby
Elhu has joined #ruby
ssvo has joined #ruby
ToApolytoXaos has joined #ruby
<unstable>
I was playing with the google api for fun, just to build little projects and learn ruby. Now I'm playing with the yelp api. With google I could just JSON.parse(RestClient.get(url)). With yelp though I'm not sure what I'm getting. I think it's json.. though JSON.parse(RestClient.get(url)) doesn't put the data into ruby data structures. The output looks like this: \"neighborhoods\": [\"SoHo\"], \"postal_code\": \"10012\",
maxmanders has joined #ruby
<unstable>
Am I supposed to use nokogiri to get rid of all the \ first or somethign?
<otters>
that looks like JSON without brackets
<peta_>
MrZYX: indeed, I added magic encoding comments to all MY project files and now it works
Uranio has quit [Quit: while you reading this, a kitty dies]
atno has quit [Ping timeout: 245 seconds]
megha has quit [Ping timeout: 246 seconds]
dhruvasagar has quit [Ping timeout: 246 seconds]
<unstable>
o wait nevermind, I'm doing something completely wrong.
kuzushi has quit [Ping timeout: 258 seconds]
lmf40 has joined #ruby
forrest has joined #ruby
mahmoudimus has joined #ruby
lmf40 has quit [Remote host closed the connection]
wolcanus has joined #ruby
dankest has joined #ruby
momomomomo_ has joined #ruby
sylvinus has quit [Quit: sylvinus]
pcarrier has joined #ruby
momomomomo has quit [Ping timeout: 252 seconds]
momomomomo_ is now known as momomomomo
supernullset has quit [Remote host closed the connection]
<unstable>
http://pastebin.com/hM6Ly008 .. so this code works now. Should I try to get this working with addressable? The problem is I need to make the request through the token. So for google, addressable worked easier.. I just embeded the key string. With this though.. I don't think i can use addressable? Also is it better to serialize the oauth token and store it.. then just reference it when I need it? Am I generating new ones constantly?
reset has joined #ruby
lmf40 has joined #ruby
indyrl has joined #ruby
atno has joined #ruby
jeffreylevesque_ has quit [Remote host closed the connection]
angusigu1ss has joined #ruby
supernullset has joined #ruby
megha has joined #ruby
alex__c2022 has quit [Quit: alex__c2022]
ferdev has quit [Quit: ferdev]
Nahra has quit [Remote host closed the connection]
angusiguess has quit [Disconnected by services]
Andreo has joined #ruby
Squarepy_ has joined #ruby
Squarepy_ is now known as Squarepy
Elhu has quit [Quit: Computer has gone to sleep.]
wildcard0 has quit [Ping timeout: 256 seconds]
jhn has joined #ruby
wildcard0 has joined #ruby
momomomomo has quit [Quit: momomomomo]
jonathanwallace has quit [Quit: WeeChat 0.3.9.2]
vikhyat has quit [Remote host closed the connection]
<MrZYX>
I actually almost left the project for the months before that and came back
<banister`sleep>
i'd find it kind of depressing to work on something that feels like it's dying
sambio has quit [Ping timeout: 246 seconds]
<banister`sleep>
well...im not sure if it's true, i only go back lack of media attention and discussion in programmer community :)
robottin1 has quit [Quit: WeeChat 0.4.0]
<MrZYX>
well media is and never was highly accurate about the project...
cantonic has joined #ruby
robottinosino has joined #ruby
ferdev has joined #ruby
phinfonet has joined #ruby
<MrZYX>
I don't have the feeling our userbase shrinks, though hard to measure ;)
niceguyjames has joined #ruby
oneirophren has joined #ruby
zmike has quit [Quit: Выходжу]
<MrZYX>
I guess our main problem is that the project was run like a startup that coincidentally had a public github repo but being advertised as open source project
<MrZYX>
that scared away many contributors
atmosx has joined #ruby
kuzushi has joined #ruby
newUser1234 has quit [Remote host closed the connection]
tesuki has joined #ruby
kpshek has joined #ruby
vlad_sta_ has joined #ruby
yxhuvud2 has quit [Ping timeout: 264 seconds]
mneorr has quit [Remote host closed the connection]
vlad_starkov has quit [Ping timeout: 264 seconds]
xcv_ has joined #ruby
yxhuvud has joined #ruby
bburwell has quit [Quit: bburwell]
iamvery has joined #ruby
newUser1234 has joined #ruby
atno has quit [Remote host closed the connection]
mneorr has joined #ruby
xcv_ has quit [Remote host closed the connection]
xcv has quit [Ping timeout: 252 seconds]
theRoUS has quit [Ping timeout: 260 seconds]
artemeff has joined #ruby
<artemeff>
Hi! Can I send big data via sockets with one packet? Hmm... My problem – when I send big string (json) to other application (on erlang) I receive it piece by piece and json don't be decoded. Any ideas? Sorry for my english :C
<MrZYX>
you can't control your path mtu
fschuindt has joined #ruby
<MrZYX>
change your receiver to buffer the whole string and parse it in one go then
nbjahan has joined #ruby
robert__ is now known as robert_
locriani has quit [Remote host closed the connection]
<artemeff>
Hm, thanks
kamsky has joined #ruby
<kamsky>
hi guys, any of you have ever used QtRuby? if so, any thoughts, ideas, suggestions? Im about to start a relatively big project and I think I'm gonna use QtRuby for the GUI
chrishough has quit [Quit: chrishough]
m8 has joined #ruby
hamakn has joined #ruby
reset has quit [Ping timeout: 256 seconds]
slainer68 has joined #ruby
mando has quit [Remote host closed the connection]
atno has joined #ruby
vlad_starkov has joined #ruby
unflores has quit [Quit: unflores]
divout has quit [Remote host closed the connection]
atno has quit [Remote host closed the connection]
Nisstyre-laptop has joined #ruby
centipedefarmer has joined #ruby
xardas has joined #ruby
vlad_sta_ has quit [Read error: Operation timed out]
schickung has quit [Ping timeout: 272 seconds]
hamakn has quit [Ping timeout: 258 seconds]
FenrirReturns has left #ruby [#ruby]
vlad_starkov has quit [Remote host closed the connection]
nbjahan has quit [Quit: nbjahan]
jtharris has joined #ruby
vlad_starkov has joined #ruby
banister`sleep has quit [Remote host closed the connection]
atno has joined #ruby
vikhyat has joined #ruby
schickung has joined #ruby
theRoUS has joined #ruby
theRoUS has quit [Changing host]
theRoUS has joined #ruby
k610 has joined #ruby
forlin has quit [Remote host closed the connection]
artemeff has quit [Remote host closed the connection]
niceguyjames has quit [Quit: Computer has gone to sleep.]
momomomomo has joined #ruby
<tmewett>
i mean him being back
<tmewett>
or posting PCL.
lmf40 has joined #ruby
kurk has joined #ruby
atno has joined #ruby
<EvErLaSt>
With the svn/core and svn/client is there a way to get a new svn object and not use an instance? I need to do checkouts from three repositories
galbert_z has joined #ruby
<tmewett>
why am i so hyped about this
<tmewett>
why are you not?? xD
<Hanmac>
why does _why still exist? ;P
girija has quit [Ping timeout: 248 seconds]
momomomomo has quit [Client Quit]
<EvErLaSt>
is there a website with class documentation on svn library?
ryannielson has quit [Quit: ryannielson]
workmad3 has joined #ruby
Gabri has joined #ruby
<reactormonk>
EvErLaSt, generate it yourself?
momomomomo has joined #ruby
ioNull has quit [Quit: Computer has gone to sleep.]
ariedler has joined #ruby
reset has joined #ruby
mahmoudimus has quit [Quit: Computer has gone to sleep.]
tmewett has quit [Quit: ChatZilla 0.9.90 [Firefox 20.0.1/20130409194949]]
m8 has quit [Quit: Sto andando via]
alanp has quit [Ping timeout: 252 seconds]
alanp_ has joined #ruby
galbert_z has left #ruby ["WeeChat 0.3.7"]
yxhuvud2 has joined #ruby
kofno has quit [Remote host closed the connection]
jkamenik has quit [Quit: Leaving.]
alvaro_o has joined #ruby
pitzips has joined #ruby
sylvinus has joined #ruby
wolcanus has joined #ruby
theRoUS has quit [Ping timeout: 264 seconds]
yxhuvud has quit [Ping timeout: 245 seconds]
keymone has quit [Quit: keymone]
<dougsko>
if i have an array of threads, say, 100, and each one takes about 10 seconds to complete, how can continuously create/kickoff groups of threads every X seconds without having to wait for the first group to all finish?
<MrZYX>
#each_slice ?
<MrZYX>
+ #sleep
galbert_z has joined #ruby
<dougsko>
each thread sleeps inside it. so after calling #join on the threads, i have to wait 1000 seconds before i can loop around again and kick off another group of 100 threds
<eval-in>
dougsko => /tmp/execpad-d8aa2a35566a/source-d8aa2a35566a:2:in `delete': no implicit conversion of Regexp into String (TypeError) ... (http://eval.in/16773)
<Boohbah>
internally Ruby implements break from within a block by throwing an exception!
jonathanwallace has joined #ruby
<dougsko>
:( no regex in #delete
AlSquirrel is now known as AlSquire
newUser1234 has joined #ruby
<MrZYX>
so gsub it is
<dougsko>
indeed
linduxed has quit [Quit: WeeChat 0.3.9.2]
a_a_g has quit [Quit: This computer has gone to sleep]
<unstable>
Error: Cannot locate this method: flatten.
Evropi has joined #ruby
<Spooner>
You need to gem install pry-doc
<MrZYX>
unstable: that ruby-doc link you just posted has a toggle source link...
<Spooner>
For access to C code.
w1ntermute has joined #ruby
<unstable>
MrZYX: Excellent, thanks a lot.
V8Energy has joined #ruby
<Hanmac>
Spooner: does show-source also work for C++ Gems? and that is needed to get it working?
<Spooner>
No idea.
<Evropi>
Hi, try to create a small server program that uses sqlite3-ruby. http://sqlite-ruby.rubyforge.org/sqlite3/classes/SQLite3/Database.html#M000093 says type translation is disabled when using the .new method. This is probably just poor documentation, but does this basically mean that TEXT won't be interpreted as VARCHAR or whatever (SQLite is very clever about that stuff)
<Evropi>
s/try/trying
<Spooner>
Hanmac, Just try it ;)
yxhuvud has joined #ruby
pkrnj has joined #ruby
mayankkohaley has quit [Ping timeout: 264 seconds]
carloslopes has quit [Remote host closed the connection]
rakl has joined #ruby
yxhuvud2 has quit [Ping timeout: 258 seconds]
s2013 has joined #ruby
kpshek has joined #ruby
wolcanus has joined #ruby
<unstable>
ok, show-source works fine after installing pry-doc
<banister`sleep>
damnit, anyone here experienced with sinatra?
<Spooner>
unstable, You can also use show-doc
V8Energy_ has joined #ruby
V8Energy has quit [Ping timeout: 256 seconds]
ToApolytoXaos has quit [Quit: Leaving]
hmarr has joined #ruby
<peta_>
ruby is a strange language
<peta_>
it actively tries to destroy everything I have learned about OOP during the recent years
xcv has joined #ruby
<banister`sleep>
peta_: like what for example
Morkel has quit [Quit: Morkel]
<Hanmac>
peta_: maybe that what you learn before was wrong? ;P
<peta_>
lol … dont think so
<Evropi>
to be honest, I think OO *really* makes sense in fully OO languages. Which is why most people don't use it when programming in C++ (actually just C)
<r0bgleeson>
peta_: did you come from Java?
<banister`sleep>
peta_: can you give an example
<banister`sleep>
peta_: of one OOP preconception it's destroying
<Evropi>
C++ is the worst implementation of OO I've ever seen.
yashshah has quit [Ping timeout: 264 seconds]
<Hanmac>
peta_: let me guess you are come from PHP ?
<Spooner>
Evropi, Even compared to PHP? :D
<banister`sleep>
Hanmac: shush, i want to hear an actual example
<Evropi>
xD
<peta_>
e.g. how "inheritance" is accomplished. that including modules is encourage over classic inheritance. but that alone is something I can get used to
Elhu has joined #ruby
<banister`sleep>
peta_: including modules is not encouraged over classical inheritance, wtf
alo1 has joined #ruby
<Hanmac>
with including, extending , and prepending you have 100% control in wich order the ancestor chain is builded
Elhu has quit [Client Quit]
<Spooner>
Compared to traditional multiple inheritance, it is a joy ;)
KazW_ is now known as KazW
xcv has quit [Ping timeout: 264 seconds]
<peta_>
I've read many source that were encouraging module includes over classic inheritance chains. quoting that e.g. rails is using module includes all over the place instead of class based inheritance
<s2013>
whats the difference between lambda and proc?
<peta_>
then it's hard for me to get used how to the fact that both, classes and class instances can have instance attributes
<injekt>
how they handle arguments
<injekt>
s2013: ^
dooleyburger has quit [Ping timeout: 256 seconds]
forrest has quit [Quit: Leaving]
<peta_>
and that there is even another dimensions when a class is "opened"
<injekt>
and return statements
<injekt>
unfortunately
<Hanmac>
s2013: procs are a bit more lazy about the paramters (so they can be nil)
ebobby has joined #ruby
kiyan has quit [Quit: Leaving]
<Hanmac>
peta_: there are ways that prevent an class from opening again ... but they are black magic (C++ has "final" think about that)
<peta_>
I dont want black magic
balishag_ has quit [Ping timeout: 255 seconds]
<peta_>
I just want to get comfortable to vanilla Ruby
fermion has quit [Quit: Computer has gone to sleep.]
mneorr has joined #ruby
<Hanmac>
peta_: with #freeze you can prevent an object from been changed ... that works on classes too
<EvErLaSt>
aaaahhhhh why do some classes have a is_a method and some don't
<MrZYX>
there's only a is_a? method
baphled_ has joined #ruby
<Hanmac>
i think he means the to_* methods
<s2013>
is_a? is to check if its n array
alo1 has quit [Quit: Lost terminal]
<injekt>
no
<injekt>
it's not
wargasm has joined #ruby
<wagster>
[].is_a? Array
<EvErLaSt>
stupid ? marks are killing me lol
<joshu>
hi is this ok to do in ruby HEROKU_URL + 'access_token=' + CLIENT_SECRET + '&file_name=' + FILE_NAME
artemeff has joined #ruby
<injekt>
joshu: yes, but interpolation is much nicer imo
<joshu>
injekt can you please explain and new to ruby
`brendan has quit [Quit: - nbs-irc 2.39 - www.nbs-irc.net -]
alanp has quit [Read error: Connection reset by peer]
jbueza has joined #ruby
alanp has joined #ruby
<injekt>
banister`sleep: #ror might help more, it would be more complex doing the channel stuff in rails
csaunders has quit [Quit: Computer has gone to sleep.]
emergion has joined #ruby
<joshu>
injekt very kind of you!
mattbl has joined #ruby
gaahrdner has quit [Remote host closed the connection]
d2dchat has joined #ruby
EPIK has joined #ruby
_cupnoodles1 has joined #ruby
solidoodlesuppor has quit [Remote host closed the connection]
_cupnoodles has quit [Quit: Ping]
V8Energy_ has quit [Read error: Connection reset by peer]
mjago` has joined #ruby
<injekt>
joshu: happy coding!
<injekt>
g'night
<unstable>
I want to have a rails controller that receives an ajax call from a javascript web client.. and feeds it 20k of json data from api calls that I wrote methods for.
V8Energy has joined #ruby
<joshu>
injekt thanks night hope to catch you again ;)
<unstable>
I'm not exactly sure where to get started. I've written all the methods for yelp/google maps. I have a javascript trigger that when it occurs.. it will do something. I'm not sure how to do the ajax bits.
wgosling has quit [Quit: Konversation terminated!]
KazW has quit [Read error: Connection reset by peer]
pcarrier has quit [Quit: Computer has gone to sleep.]
Banistergalaxy has quit [Ping timeout: 240 seconds]
arya__ has quit [Client Quit]
wolcanus_ has joined #ruby
yashshah has joined #ruby
pcarrier has joined #ruby
wolcanus_ has quit [Remote host closed the connection]
arya__ has joined #ruby
theRoUS has quit [Ping timeout: 256 seconds]
pkrnj has joined #ruby
agarie has joined #ruby
wolcanus has quit [Ping timeout: 252 seconds]
emergion has quit [Quit: Computer has gone to sleep.]
sepp2k has quit [Ping timeout: 256 seconds]
unflores has quit [Quit: unflores]
malcolmva has quit [Read error: Connection reset by peer]
malcolmva has joined #ruby
fermion has joined #ruby
fermion has quit [Remote host closed the connection]
sambao21 has quit [Quit: Computer has gone to sleep.]
maetthew has quit [Ping timeout: 245 seconds]
erry has quit [Remote host closed the connection]
thams has quit [Quit: thams]
mattbl has joined #ruby
<tommylommykins>
hmm
<tommylommykins>
I want to rescind the GIL while my C extension does its work
<tommylommykins>
how can I do that?
vlad_starkov has quit [Ping timeout: 258 seconds]
zph has joined #ruby
felixjet has quit [Ping timeout: 252 seconds]
wmoxam has quit [Ping timeout: 264 seconds]
rton has left #ruby [#ruby]
kpshek has quit []
soulisson has quit [Quit: Quitte]
johnnyfuchs has quit [Quit: Leaving.]
frem has quit [Ping timeout: 256 seconds]
moted has left #ruby [#ruby]
Eiam has joined #ruby
Eiam has quit [Changing host]
Eiam has joined #ruby
zph has quit [Client Quit]
johnkary has quit [Quit: @johnkary]
robottinosino has quit [Quit: WeeChat 0.4.0]
<ShellFu>
hey all. Im using unicorn. When I start my app workers start. stay up for a little bit then get reaped, and my app goes bye bye. Ive ran without -D but I get no additional output that is helpful.
<ShellFu>
Any ideas or how I can have unicorn be more verbose. Didnt see a verbose option
ph^ has joined #ruby
netto has joined #ruby
BrianJ has joined #ruby
nomenkun has joined #ruby
moted has joined #ruby
mark_locklear has quit [Ping timeout: 260 seconds]
rickmasta has joined #ruby
ryannielson has joined #ruby
newUser1234 has quit [Remote host closed the connection]
tesuki has quit [Remote host closed the connection]
LennyLinux has quit [Remote host closed the connection]
sailias has quit [Quit: Leaving.]
idkazuma has joined #ruby
athst has joined #ruby
bhaarat has quit [Quit: bhaarat]
atno has quit [Remote host closed the connection]
pitzips has joined #ruby
epsylon has quit [Ping timeout: 264 seconds]
balishag has joined #ruby
Mon_Ouie has quit [Ping timeout: 264 seconds]
bhaarat has joined #ruby
zph has joined #ruby
xardas has quit [Ping timeout: 258 seconds]
mahmoudimus has joined #ruby
veinofstars has quit [Quit: veinofstars]
Tricon has quit [Ping timeout: 256 seconds]
Yarou has joined #ruby
atno has joined #ruby
randomautomator has joined #ruby
tootubular has quit [Quit: tootubular]
carlyle has quit [Remote host closed the connection]
chxane has quit [Read error: Connection reset by peer]
mattbl has quit [Quit: This computer has gone to sleep]
atno__ has joined #ruby
centipedefarmer has joined #ruby
randomautomator has quit [Read error: Connection reset by peer]
randomautomator has joined #ruby
epsylon has joined #ruby
pioz has quit [Quit: This computer has gone to sleep]
bitcycle has joined #ruby
<bitcycle>
Hey all. Can someone tell me how to drop into the ruby interactive console from within a script similar to python's "import pdb; pdb.set_trace()"?
bradleyherman has joined #ruby
nezumi has quit [Ping timeout: 276 seconds]
zmanfx has quit [Ping timeout: 245 seconds]
<bradleyherman>
when making an array, why does this work: [1,2, *(100..200)], but not [1,2, *(100..200), *(300..400)]
ariedler has quit [Remote host closed the connection]
<sam113101>
where is MRI's source code hosted?
ephemerian has left #ruby [#ruby]
_nitti has quit [Remote host closed the connection]
<bradleyherman>
sam113101: isn't MRI just in the ruby source code?
zmanfx has joined #ruby
<sam113101>
w-wat do yo umean
ebobby has left #ruby [#ruby]
<bradleyherman>
ruby, the language, is the interpreter
LaPetiteFromage has joined #ruby
mikepack has quit [Remote host closed the connection]
<joshu>
anyone know how I can check my ruby code for syntax errors, variable errors in sublime text 2? i've installed sublimelinter but it doesn't catch errors such as wrong variable names or even if I forget "#{test_var" the last bracket in a string
mattbl has joined #ruby
<callmeivan>
but browser.button(:id, "btnReboot").click does not seem to work because it cannot find it because of all the java shit
<joshu>
this is on a cloud service server in the US and I want European time is Time.zone.now the way to do it?
Scriptor has joined #ruby
<ariedler>
joshu: I would think so ...
<ariedler>
joshu: or Time.new(offset: ...)
<alainus>
or should I do array << "item2" if something, for each one of the dynamically added items
rickmasta has quit [Quit: Leaving...]
al3xnull has quit [Remote host closed the connection]
<joshu>
ariedler do I set TIme.zone = 'CEST' and then TIme.zone.now
chrishunt has joined #ruby
<ariedler>
joshu: I gave you something that was rails only my bad :)
ixti has quit [Quit: WeeChat 0.4.0]
<joshu>
ariedler no worries
<callmeivan>
i suppose i do need to specify the path somehow, which is //*[@id="btnReboot"]
<ariedler>
Time.new(offset: ....) will work though given you know the offset of CEST
<bricker>
I am looking at the documentation, but I just can't figure out what the real, practical difference is between JSON.parse and JSON.load . Can someone explain it to me?
vlad_starkov has joined #ruby
<bricker>
If I pass a JSON string into either one, I get the exact same return value.
acrussell has quit [Quit: Leaving.]
jonathanwallace has quit [Ping timeout: 246 seconds]
rickmasta has joined #ruby
lkba has joined #ruby
<ariedler>
bricker: one is part of YAML
emergion has quit [Read error: Connection reset by peer]
xcv has joined #ruby
Skofo has quit [Quit: Leaving]
<ariedler>
bricker: infact one is commonly implemented in terms of the other :)
vlad_starkov has quit [Ping timeout: 245 seconds]
<callmeivan>
hmm, browser.button(:xpath, '//*[@id="btnReboot"]').click does not work