<xxneolithicxx>
shevy: why not make it an initialized parameter or pass it in an options hash, "just in case"
vermiform has quit [Quit: Page closed]
sarmiena_ has joined #ruby
<shevy>
xxneolithicxx nah it don't deserve to become an argument
charliesome has joined #ruby
akaiiro has joined #ruby
tesaf has quit [Quit: Lost terminal]
tristanp has quit [Remote host closed the connection]
tristanp has joined #ruby
jorge has joined #ruby
uberscp has joined #ruby
Ancient has joined #ruby
jorge has joined #ruby
Lightsword has quit [Ping timeout: 240 seconds]
tristanp_ has joined #ruby
jorge has quit [Client Quit]
adamski2600 has quit []
tristanp has quit [Read error: Connection reset by peer]
jorge has joined #ruby
kiyote23 has quit [Remote host closed the connection]
jorge has quit [Client Quit]
triple_b has joined #ruby
<sarmiena_>
not sure where to ask, but i’m using sidekiq to process background jobs, but jobs getting stuck in enqueued (production)
jorge has joined #ruby
tristanp_ has quit [Remote host closed the connection]
<lbrf>
sarmiena_: did you run sidekiq or the jobs are raising errors?
tristanp has joined #ruby
<sarmiena_>
they’re stuck in enqueued and all workers are free. no errors in the logs. then after some random amount of time, it’ll process fine for a bit. then get stuck again
<sarmiena_>
lbrf: ^
<sarmiena_>
also, the command used to start (foreground for testing) “bundle exec sidekiq -C /var/www/web-app/current/config/sidekiq.yml -e production”
<mbff>
if I run "ruby main.rb" with the deploy user everything works
<pontiki>
mbff: i typically use the whenever gem to handle crontab jobs; the thing it does is run your shell as a login shell so the usual things that make rvm work, well, work
<mbff>
I am not running a rails project
<pontiki>
so what?
<pontiki>
i'm trying to tell you HOW IT WORKS
<pontiki>
maybe you'll just have to go look yourself
<mbff>
I looked at the whenever gem and I thought it required rails
<pontiki>
look
<pontiki>
look at how it creates the entry
Phagus has joined #ruby
<pontiki>
you don't have to use the gem
<pontiki>
just emulate how it works
<Phagus>
How do I run a script, then enter it in interactive mode?
<havenwood>
Phagus: huh?
<havenwood>
mbff: no, it doesn't require rails
Calmoto1 has joined #ruby
<Phagus>
Run a script, then enter interactive mode with all of its variables and methods in my interactive mode's namespace
tobago has quit [Remote host closed the connection]
<Phagus>
Python has a feature where you do python -i myscript.py that lets you do that
<xxneolithicxx>
mbff: did you leave a newline at the end of the crontab? cron doesnt run if the last line is empty or not present (depending on how you edited it). is it running at all?
<mbff>
I just added a newline, if that is the issue I am officially stupid.
Takle has quit [Remote host closed the connection]
kirun has quit [Quit: Client exiting]
<mbff>
no dice
jenrzzz has quit [Ping timeout: 264 seconds]
<xxneolithicxx>
check the user mail to see if theres any output
<xxneolithicxx>
/var/spool/mail/<user>
havenwood has quit [Remote host closed the connection]
<xxneolithicxx>
it should automatically set that based on the crontab user
<mbff>
o
jasonwebster has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
<mbff>
cron_check exists
fgo has joined #ruby
<mbff>
cron is working
<xxneolithicxx>
ok so that means whatever you are running is not throwing any errors/output otherwise it would end up in the user mail
boombadaroomba has joined #ruby
ta has quit [Ping timeout: 260 seconds]
TheNet has joined #ruby
<mbff>
I solved the issue.
jasonwebster has joined #ruby
renderful has joined #ruby
<mbff>
I create a file 'foo.json'
<mbff>
but on the server that file is created elsewhere
rylev has joined #ruby
<mbff>
so how do I set the current directory as the one the rb file is in
jasonwebster has quit [Client Quit]
sarmiena_ has joined #ruby
timonv_ has joined #ruby
fgo has quit [Ping timeout: 264 seconds]
mengu has joined #ruby
mengu has joined #ruby
boombadaroomba has quit [Ping timeout: 250 seconds]
dkphenom has joined #ruby
jaequery has joined #ruby
rylev has quit [Remote host closed the connection]
renderful has quit [Ping timeout: 265 seconds]
rylev has joined #ruby
robustus|Off has quit [Ping timeout: 255 seconds]
Xiti` has joined #ruby
banister has joined #ruby
banister has quit [Client Quit]
timonv_ has quit [Ping timeout: 240 seconds]
mengu has quit [Ping timeout: 240 seconds]
fuhgeddaboudit has quit [Ping timeout: 265 seconds]
banister has joined #ruby
robustus has joined #ruby
kiyote23 has quit [Remote host closed the connection]
stormbytes has joined #ruby
Xiti has quit [Ping timeout: 260 seconds]
kiyote23 has joined #ruby
sarmiena_ has quit [Quit: sarmiena_]
CrazyM4n has quit [Quit: Leaving]
gsd has joined #ruby
charliesome has joined #ruby
Xiti` is now known as Xiti
kiyote23 has quit [Remote host closed the connection]
kiyote23 has joined #ruby
charliesome has quit [Client Quit]
<xxneolithicxx>
cd dir && <run command>
sarmiena_ has joined #ruby
tus has joined #ruby
tristanp has joined #ruby
Mothore___ has joined #ruby
ghr has joined #ruby
D9 has joined #ruby
rylev has quit [Remote host closed the connection]
M-Technic has quit [Quit: leaving]
snath has joined #ruby
sarmiena_ has quit [Client Quit]
D9 has quit [Max SendQ exceeded]
sarmiena_ has joined #ruby
<xxneolithicxx>
should be running out of its home dir by default. or change your code to File.join(File.dirname(__FILE__), "foo.json") is probably better
D9 has joined #ruby
rylev has joined #ruby
The_NetZ has joined #ruby
CrazyM4n has joined #ruby
ghr has quit [Ping timeout: 244 seconds]
rylev has quit [Client Quit]
diego_ar has joined #ruby
lnormous has quit [Quit: Leaving]
henesy has quit [Ping timeout: 258 seconds]
krism has quit [Ping timeout: 258 seconds]
sarmiena_ has quit [Ping timeout: 256 seconds]
dblessing has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
diego_ar has quit [Ping timeout: 244 seconds]
Xiti` has joined #ruby
Akagi201 has joined #ruby
CorySimmons has quit [Quit: Bye!]
The_NetZ has quit [Read error: Connection reset by peer]
Rollabunna has joined #ruby
Xiti has quit [Ping timeout: 250 seconds]
fgo has joined #ruby
pwh has joined #ruby
avrc has quit [Quit: this channel is bakas]
avrc has joined #ruby
Akagi201 has quit [Ping timeout: 244 seconds]
avrc has quit [Client Quit]
blizzy has joined #ruby
maestrojed has quit [Quit: Computer has gone to sleep.]
<quazimodo>
long story short, go to the _spec and youll see 1 test. It fails when it runs in rspec. But if i put binding.pry before looper.run! and do all those steps by hand, nothnig fails
dukedave has quit [Ping timeout: 258 seconds]
<quazimodo>
for some reason, when rspec runs normally, my spawned process gets a SIGHUP
<quazimodo>
the streams break
amitchellbullard has quit [Ping timeout: 272 seconds]
troter__ has quit [Ping timeout: 272 seconds]
zrl has quit [Ping timeout: 272 seconds]
culturelabs has quit [Ping timeout: 272 seconds]
ballPointPenguin has quit [Ping timeout: 258 seconds]
ehc has quit [Ping timeout: 258 seconds]
ramblinpeck_ has quit [Ping timeout: 258 seconds]
AdamMeghji has quit [Ping timeout: 272 seconds]
KnownSyntax has quit [Ping timeout: 272 seconds]
PhilK has quit [Ping timeout: 272 seconds]
ckrailo_ has quit [Ping timeout: 272 seconds]
mroth has quit [Ping timeout: 272 seconds]
jrunning_ has quit [Ping timeout: 272 seconds]
bret has quit [Ping timeout: 272 seconds]
happyface has quit [Ping timeout: 272 seconds]
AmirolAhmad has joined #ruby
ohaibbq has quit [Quit: Leaving...]
BraddPitt has quit [Quit: Leaving]
Darryl__ has quit [Quit: Connection closed for inactivity]
mary5030 has joined #ruby
renderful has joined #ruby
Joufflu has quit [Ping timeout: 258 seconds]
St1gma has joined #ruby
Mia has quit [Read error: Connection reset by peer]
Mia has joined #ruby
Mia has quit [Changing host]
Mia has joined #ruby
parabolize has quit [Quit: ERC Version 5.3 (IRC client for Emacs)]
shock_one has joined #ruby
renderful has quit [Ping timeout: 258 seconds]
mary5030 has quit [Remote host closed the connection]
Rahul_Roy_ has joined #ruby
mary5030 has joined #ruby
chridal has left #ruby ["WeeChat 1.0.1"]
<MrSamuel>
quazimodo, i had some weird issues, due to process management, from minitest
<MrSamuel>
be careful with forked/child processes
jenrzzz has quit [Ping timeout: 264 seconds]
toretore has quit [Quit: This computer has gone to sleep]
mary5030 has quit [Ping timeout: 258 seconds]
<quazimodo>
MrSamuel: i can see they are fickle, but I have no idea why
<quazimodo>
MrSamuel: i don't even know how to debug this stuff, but something weird ass is goingo n
machty has quit [Ping timeout: 244 seconds]
benlakey_ has quit [Ping timeout: 265 seconds]
<quazimodo>
yeah it's inconsistent. Sometimes it's fine, other's its totally broken
electrical has quit [Ping timeout: 258 seconds]
jenrzzz has joined #ruby
bluehavana has quit [Ping timeout: 265 seconds]
<MrSamuel>
quazimodo, I have released a gem for managing child processes
Juanchito has quit [Ping timeout: 272 seconds]
jshultz has quit [Ping timeout: 272 seconds]
dnyy has quit [Ping timeout: 272 seconds]
andrewstewart has quit [Ping timeout: 272 seconds]
akitada has quit [Ping timeout: 272 seconds]
shelling_ has quit [Ping timeout: 272 seconds]
ELLIOTTCABLE has quit [Ping timeout: 272 seconds]
juuo has quit []
shock_one has quit [Remote host closed the connection]
<MrSamuel>
also I don't know what you are doing but I'd recommmend using Process#spawn
kireevco has quit [Read error: Connection reset by peer]
<MrSamuel>
ah I see you are using PTY
kireevco1 has joined #ruby
Lightsword has quit [Ping timeout: 252 seconds]
kapowaz_ has quit [Ping timeout: 272 seconds]
bove has quit [Ping timeout: 258 seconds]
<quazimodo>
yep
goshdarnyou has quit [Ping timeout: 244 seconds]
<quazimodo>
i need my process to be attached to a PTY
<MrSamuel>
PTY stuff is a bit weird
<MrSamuel>
because unix
lectrick has quit [Ping timeout: 265 seconds]
<MrSamuel>
um
im0b has quit [Ping timeout: 258 seconds]
yo61 has quit [Ping timeout: 258 seconds]
<MrSamuel>
I wrote some code in python to deal with a child PTY process
<MrSamuel>
virtual TTY
<MrSamuel>
what are you trying to do?
<quazimodo>
i'm 'feature' testing a cli program which lives in an xterm usually
<quazimodo>
so i am writing a rspec-cli test helper library
RoryHughes has joined #ruby
<MrSamuel>
ah okay
<quazimodo>
but yeah, this stuff's really inconsintent
benlakey_ has joined #ruby
tmoore_ is now known as tmoore
<MrSamuel>
my suggestion is to make sure that the PTY is creating it's own session/process group
shelling_ has joined #ruby
lectrick has joined #ruby
akitada has joined #ruby
<MrSamuel>
to make sure that any signals are not going to the child process incorrectly
<quazimodo>
what do you mean
kireevco has joined #ruby
<MrSamuel>
well
andrewstewart has joined #ruby
kireevco1 has quit [Read error: Connection reset by peer]
anaeem1_ has quit [Remote host closed the connection]
<MrSamuel>
it's a long time since I worked on it but basically a process group isolates processes from signals
<MrSamuel>
i guess it might be a bit more complex than that but yeah
StoneCypher has joined #ruby
<MrSamuel>
something like that
<quazimodo>
holy jesus
<quazimodo>
i juts got 1000 pages of output
im0b has joined #ruby
<MrSamuel>
yeah try to use something to limit it to only signals
<MrSamuel>
there is probably some option
bove has joined #ruby
<quazimodo>
yeah i'll look
goshdarnyou has joined #ruby
chinmay_dd has quit [Ping timeout: 250 seconds]
<MrSamuel>
If you close the terminal emulator, the master end of the pty becomes closed; the foreground process group of the slave end receives SIGHUP and likely dies. If you press Ctrl+D at the shell, the slave end of the pty becomes closed, the terminal emulator gets EOF on the master end, and shuts down accordingly.
yo61 has joined #ruby
Sawbones has quit [Remote host closed the connection]
anaeem1 has quit [Remote host closed the connection]
doev has quit [Quit: Verlassend]
jaequery has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
anaeem1 has joined #ruby
ringarin has joined #ruby
anaeem1 has quit [Read error: Connection reset by peer]
anaeem1_ has joined #ruby
lbrf has quit [Ping timeout: 264 seconds]
koderok has joined #ruby
koderok has quit [Remote host closed the connection]
<epitron>
hmmm
Solsist has quit []
<epitron>
i've got an array of tokens, and i want to select everything between a start and an end token
<epitron>
what's the simplest way to accomplish that?
<epitron>
regular expresions would normally be the solution if this was a string
<quazimodo>
i guess fsync is for files, not pipes?
<epitron>
i could write a loop that sets some state variable..
<epitron>
there's gotta be something better
<quazimodo>
yep fsync wont work for pipes
<quazimodo>
i wonder if it works for ptys
<epitron>
lol
<epitron>
the flip flop operator!
<epitron>
THAT'S what it's for
stomar has joined #ruby
dseitz has joined #ruby
dfas has quit []
<quazimodo>
i no
<quazimodo>
whatchu talking bout
boombadaroomba has joined #ruby
<epitron>
the flip flop operator solves my problem
<epitron>
(finding all tokens between start/end tokens in an array)
renderful has joined #ruby
oo_ has joined #ruby
chinmay_dd_ has joined #ruby
tvw has quit []
boombadaroomba has quit [Ping timeout: 264 seconds]
Stichoza has joined #ruby
renderful has quit [Ping timeout: 258 seconds]
oo_ has quit [Ping timeout: 252 seconds]
blizzy has quit [Ping timeout: 255 seconds]
blz37 has quit [Ping timeout: 258 seconds]
Stichoza has quit [Ping timeout: 264 seconds]
bMalum has joined #ruby
fgo has joined #ruby
<shevy>
what the hell is a flip flop operator
anaeem1_ has quit [Remote host closed the connection]
sigurding has joined #ruby
anaeem1_ has joined #ruby
Lightsword has quit [Quit: Lightsword]
jimbach has joined #ruby
Hobogrammer has quit [Ping timeout: 272 seconds]
fgo has quit [Ping timeout: 272 seconds]
Mothore____ has joined #ruby
Hanmac has joined #ruby
St1gma has quit [Ping timeout: 244 seconds]
<epitron>
one of ruby's weirdest features
Rahul_Roy_ has quit [Quit: Connection closed for inactivity]
anaeem1_ has quit [Ping timeout: 258 seconds]
ringarin has quit [Ping timeout: 258 seconds]
akaiiro has quit [Ping timeout: 250 seconds]
jimbach has quit [Ping timeout: 258 seconds]
blz37 has joined #ruby
x1337807x has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
aspiers has joined #ruby
MrSamuel has quit [Ping timeout: 244 seconds]
Mothore____ has quit [Ping timeout: 258 seconds]
robustus has quit [Ping timeout: 250 seconds]
jheg has joined #ruby
Guest17405 has quit [Ping timeout: 264 seconds]
<Hanmac>
epitron: hm what feature did you mean?
robustus has joined #ruby
blz37 has quit [Read error: Connection reset by peer]
blz37 has joined #ruby
MrSamuel has joined #ruby
dseitz has quit [Quit: good night world...]
mityaz has joined #ruby
BraddPitt has joined #ruby
BraddPitt has quit [Client Quit]
fabrice31 has joined #ruby
BraddPitt has joined #ruby
lbrf has joined #ruby
jheg has quit [Quit: jheg]
fabrice31 has quit [Ping timeout: 252 seconds]
aspiers_ has joined #ruby
lbrf has quit [Ping timeout: 250 seconds]
blz37 has quit [Ping timeout: 258 seconds]
sea_local has quit [Remote host closed the connection]
aspiers has quit [Ping timeout: 245 seconds]
jheg has joined #ruby
ptrrr has joined #ruby
tvw has joined #ruby
oleo__ has joined #ruby
oleo is now known as Guest6095
lxsameer has quit [Quit: Leaving]
Soda has joined #ruby
tobacco_joe has joined #ruby
kireevco has quit [Quit: Leaving.]
Guest6095 has quit [Ping timeout: 240 seconds]
timonv_ has joined #ruby
kireevco has joined #ruby
6A4AAOY7C has joined #ruby
ringarin has joined #ruby
LekeFly has joined #ruby
x1337807x has joined #ruby
devdazed has joined #ruby
kireevco has quit [Ping timeout: 252 seconds]
Asher has quit [Read error: No route to host]
Asher has joined #ruby
dukedave has joined #ruby
x1337807x has quit [Ping timeout: 265 seconds]
oo_ has joined #ruby
mroth has joined #ruby
jheg has quit [Quit: jheg]
AndChat| has quit [Ping timeout: 244 seconds]
ckrailo_ has joined #ruby
Stichoza has joined #ruby
TgMts has quit [Quit: No Ping reply in 180 seconds.]
oo_ has quit [Ping timeout: 250 seconds]
LekeFly has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
TgMts has joined #ruby
ikaros has joined #ruby
Stichoza has quit [Ping timeout: 256 seconds]
chu has joined #ruby
fgo has joined #ruby
vinleod has quit [Quit: Computer has gone to sleep.]
jenrzzz has joined #ruby
<Mia>
So here is my twitter api related basic question (I'm pretty sure) http://justpaste.it/ibq4 --- Any help is appreciated.
fgo has quit [Ping timeout: 272 seconds]
jzinedine has joined #ruby
diego_ar has joined #ruby
KnownSyntax has joined #ruby
last_staff has joined #ruby
PhilK has joined #ruby
<claf>
Mia, filter retweets
<claf>
this is not really a ruby q
<claf>
you filter out any retweets other than userone
shredding has quit [Quit: shredding]
dexteryy has joined #ruby
diego_ar has quit [Ping timeout: 272 seconds]
rshetty has quit [Remote host closed the connection]
dexteryy has quit [Remote host closed the connection]
<claf>
Mia: did you google your question?
<Mia>
claf, of course
<claf>
why do you ask then
<Mia>
claf, I know it's passible to manually check if the tweet belongs to or is retweeted by the users in the given list, but I'm expecting something more clever
<Mia>
claf, these are pointless questions. If you see the answer on google feel free to post.
<tobiasvl>
what does this have to do with ruby?
<claf>
Mia: you are also on nodejs asking this, kinda off topic
fgo has joined #ruby
<Mia>
tobiasvl, it doens't - general webdew question some people might be interested in, #twitterapi is dead and stackoverflow hashtag is also very very inactive
<claf>
So you decided to spam inappropriate channels, Mia?
<Mia>
claf, I'm asking the question on multiple channels related to webdev
<claf>
You post a SO thread and *wait*
<Mia>
claf it's not spamming.
<claf>
or *hire* a twitter api dev
<claf>
simple as that
<tobiasvl>
Mia: then seeing as it's off topic, being snarky when someone tells you to google it is probably not a good idea
<Mia>
claf you're being pointless over and over, I'm not wasting more time with this crap.
<claf>
you are, until you get your approach and question right - and your homework, Mi
<claf>
*Mia
<claf>
Mia: now leave programming related channels, unless you have a pastie of code you intend to develop
<tobiasvl>
Mia: you are the one who's wasting our time...
bret has joined #ruby
<Mia>
claf, how is this talk any more related to ruby then my question
<Mia>
tobiasvl, you don't have to asnwer
<Mia>
you're not forced
agjacome has joined #ruby
<claf>
Mia: it is not, so you are now on ignore
happyface has joined #ruby
<tobiasvl>
/ignore Mia
<Mia>
Perfect :3
<tobiasvl>
god
<epitron>
Hanmac: the flip-flop
<apeiros>
wow, I wake up to find kindergarten invaded #ruby :(
6A4AAOY7C has quit [Quit: This computer has gone to sleep]
<shevy>
is that a unicode string?
<mozzarella>
>> "abc def ghi".split
<mozzarella>
shitty robot
kireevco has quit [Ping timeout: 244 seconds]
danijoo has quit [Read error: Connection reset by peer]
danijoo has joined #ruby
<shevy>
hehe
rshetty has joined #ruby
<shevy>
you have weird delimiters there
<shevy>
<shevy>
dunno how you make them
dukedave has joined #ruby
timonv_ has joined #ruby
<shevy>
between "c" and the "d" there should be only a ' ' but on IRC you have something extra between the space and the prior letter, not sure what it is
oleo__ has quit [Quit: Verlassend]
jtheuer has joined #ruby
<mozzarella>
it doesn't split on \w
<mozzarella>
doesn't seem to split on \s either
mengu has quit [Remote host closed the connection]
<mozzarella>
just regular spaces
tobacco_joe has joined #ruby
MasterPiece has joined #ruby
mroth has joined #ruby
mengu has joined #ruby
<shevy>
true
pen has joined #ruby
ragingcake has left #ruby [#ruby]
teddyp1cker has quit [Remote host closed the connection]
Hanmac has quit [Remote host closed the connection]
ckrailo_ has joined #ruby
tvw has quit []
hamakn has quit [Remote host closed the connection]
chu has quit [Quit: ERC Version 5.3 (IRC client for Emacs)]
JohnBat26 has joined #ruby
JohnBat26 has joined #ruby
Calmoto has joined #ruby
x1337807x has joined #ruby
lbrf has joined #ruby
x1337807x has quit [Ping timeout: 258 seconds]
lbrf has quit [Ping timeout: 256 seconds]
yfeldblum has quit [Remote host closed the connection]
teddyp1cker has joined #ruby
sevenseacat has quit [Remote host closed the connection]
uber_ has joined #ruby
quimrstorres has joined #ruby
Guest85414______ has joined #ruby
kapowaz has joined #ruby
ELLIOTTCABLE has joined #ruby
dnyy has joined #ruby
uber has quit [Quit: bye]
uber_ is now known as uber
bluehavana has joined #ruby
KnownSyntax has joined #ruby
chinmay_dd_ has quit [Quit: Leaving]
lectrick has joined #ruby
PhilK has joined #ruby
tlarevo has quit [Ping timeout: 250 seconds]
linocisco has joined #ruby
im0b has joined #ruby
rshetty has quit [Remote host closed the connection]
renderful has joined #ruby
galeido has joined #ruby
mengu has quit [Remote host closed the connection]
neersighted has joined #ruby
banister has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
happyface has joined #ruby
bret has joined #ruby
zemiudo has quit [Quit: Leaving]
<linocisco>
hi
Aswebb_ has quit [Remote host closed the connection]
<linocisco>
i m very new to Ruby and other popular languges. what is the strength of ruby over Perl?
<linocisco>
i m very new to Ruby and other popular languges. what is the strength of ruby over Java?
kiyote23 has joined #ruby
renderful has quit [Ping timeout: 258 seconds]
LudicrousMango has joined #ruby
mengu has joined #ruby
mengu has quit [Changing host]
mengu has joined #ruby
culturelabs has joined #ruby
<mozzarella>
have you tried Google?
amitchellbullard has joined #ruby
shelling_ has joined #ruby
<mozzarella>
ruby is more readable than perl and more concise than java
akitada has joined #ruby
<pontiki>
what an odd pair of questions
iamninja has joined #ruby
<crome>
there were 7 seconds between the quesitons, I'm wondering if he typed in both
<crome>
sirpeng is spamming something in msg
mengu has quit [Remote host closed the connection]
zrl has joined #ruby
jrunning_ has joined #ruby
rshetty has joined #ruby
andrewstewart has joined #ruby
machty has joined #ruby
electrical has joined #ruby
fabrice31 has joined #ruby
spider-mario has quit [Remote host closed the connection]
<shevy>
it bulldozers over everything that is in its path
charliesome has quit [Quit: zzz]
<pontiki>
that is so not what C is
<pontiki>
but never mind
<shevy>
linocisco no, you can not handle pointers in Ruby; you have no control over the RAM unlike in C and C++
digifiv5e is now known as daynaskully
AdamMeghji has joined #ruby
rfv has joined #ruby
arup_r has quit [Quit: Leaving.]
x1337807x has joined #ruby
<efgh_>
linocisco you do not have to handle pointers
postmodern has quit [Quit: Leaving]
<linocisco>
is Ruby compiled language like Java or Interpretted langauge?
<efgh_>
interpreted
dcarmich has joined #ruby
<linocisco>
you all folks in this channel are no doubt with Passion for using Ruby, right? what is the purpose of your choice among others? what is the main strength of Ruby over others?
<pontiki>
why are you asking these questions?
<shevy>
linocisco <shevy> linocisco ruby is elegant and terse
<shevy>
linocisco did you read the old matz interview yet?
<linocisco>
pontiki, short of time to choose one to learn
<mozzarella>
it would be hard to have self-modifying compiled ruby code
<apeiros>
sure. but not impossible.
<pontiki>
the thing you use to process it, obviously
tlarevo has quit [Remote host closed the connection]
<apeiros>
yes. interpreted/compiled is a property of the thing which executes or converts your code
MasterPiece has quit [Quit: Leaving]
hamakn has joined #ruby
oo_ has joined #ruby
ragingcake has joined #ruby
oleo has joined #ruby
<efgh_>
I'd say at least 99,9% of all ruby code is run by an interpreter, not compiled
<j416>
that's an exact number
* j416
shrugs
<apeiros>
depends on where you place the JVM in that binary picture of compiled/interpreted
<linocisco>
apeiros, the difference is time
<apeiros>
but the majority certainly is interpreted. it's still not a property of the language.
<apeiros>
linocisco: that answer doesn't even make sense.
jzinedine has quit [Ping timeout: 264 seconds]
Freelusion has joined #ruby
<linocisco>
all the today's langauge are written in low level languages like C or Assembly
hiyosi has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
<apeiros>
aaand that's nonsense. is there a point you try to make?
oo_ has quit [Ping timeout: 272 seconds]
<apeiros>
(nonsense in that there's a couple of bootstrapped languages - and both C and assembler required bootstrapping themselves)
Galas has quit [Remote host closed the connection]
sinkensabe has quit [Remote host closed the connection]
AlexRussia has joined #ruby
hiyosi has joined #ruby
<shevy>
let's all write in 0 and 1
<apeiros>
my father actually did that (punch cards)
Hanmac has joined #ruby
<shevy>
now that's what I call object oriented programming in reallife!
timonv_ has quit [Remote host closed the connection]
phutchins has joined #ruby
<efgh_>
linocisco: besides execution time there is also to consider development time
jimbach has joined #ruby
yfeldblum has joined #ruby
giuseppesolinas has quit [Quit: This computer has gone to sleep]
timonv^ has joined #ruby
giuseppesolinas has joined #ruby
<shevy>
\o/
<shevy>
linocisco how many hours of your life do you wanna invest into computers
kirun has joined #ruby
danman has joined #ruby
Freelusion has quit [Quit: Freelusion]
<wasamasa>
linocisco: the rust compiler is implemented in rust
yfeldblum has quit [Ping timeout: 244 seconds]
<apeiros>
wow. after ~15y of coding, I'm actually considering introducing a global. $log. The alternative design would be to pass it in everywhere explicitly.
<wasamasa>
linocisco: a fair amount of lisp compilers is implemented of lisp
<wasamasa>
linocisco: people implement lots of browser stuff in JS
<wasamasa>
linocisco: and so on, your comment makes little sense and sounds as if your horizon needs expansion
<shevy>
apeiros do you at least feel dirty when using $log?
<apeiros>
I'm actually not sure, shevy
n1lo has quit [Ping timeout: 260 seconds]
<apeiros>
pondering the ups and downs of using it
giuseppesolinas has quit [Quit: This computer has gone to sleep]
<shevy>
well the biggest pro can also be a con - it will be available everywhere; I think I'd only be worried if someone else also would use the name $log
<apeiros>
it's framework-level. the only levels to introduce globals are IMO app and framework.
Stichoza has quit [Quit: Be back later ...]
<apeiros>
I think the main disadvantage is that anything using $log is coupled to the framework.
danijoo has quit [Read error: No route to host]
danijoo has joined #ruby
<apeiros>
then again, the coupling is weaker than using e.g. Framework::Logger.instance
tristanp has joined #ruby
<apeiros>
and the other question in that regard is how to deal with $stderr & $stdout
TheNet has joined #ruby
x1337807x has joined #ruby
Stichoza has joined #ruby
giuseppesolinas has joined #ruby
blackjid_ has quit [Ping timeout: 258 seconds]
terrellt has quit [Ping timeout: 258 seconds]
x1337807x has quit [Ping timeout: 244 seconds]
timonv^ has quit [Remote host closed the connection]
skarn has quit [Ping timeout: 258 seconds]
byprdct has joined #ruby
davedev24_ has joined #ruby
efghi has joined #ruby
n1lo has joined #ruby
Narzew has quit [Remote host closed the connection]
<Hanmac>
apeiros what about a module attribute?
<apeiros>
Hanmac: where'd be the diff to Framework::Logger.instance?
<Hanmac>
hm not so much very different, but let it be Framework::log that returns the log object for you ... its shorter and also settable with Framework::log=
Stichoza has quit [Quit: Be back later ...]
rshetty has joined #ruby
<apeiros>
well, that's just a different place. the issue with it remains the same.
lbrf has joined #ruby
efgh_ has quit [Quit: Konversation terminated!]
tobacco_joe has quit [Remote host closed the connection]
arup_r has joined #ruby
rshetty has quit [Remote host closed the connection]
tier has quit [Remote host closed the connection]
rkday has joined #ruby
lbrf has quit [Ping timeout: 258 seconds]
doev has joined #ruby
doev has quit [Remote host closed the connection]
byprdct has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
arietis has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
<linocisco>
some syntax of Ruby are like Pascal. most are words rather than symbol
KnownSyntax has quit [Quit: Connection closed for inactivity]
arup_r has quit [Quit: Leaving.]
oo_ has quit [Ping timeout: 245 seconds]
gwn has joined #ruby
arup_r has joined #ruby
fabrice31 has quit [Ping timeout: 250 seconds]
chu has quit [Quit: ERC Version 5.3 (IRC client for Emacs)]
dts|pokeball has quit [Ping timeout: 264 seconds]
shock_one has joined #ruby
gwn has left #ruby [#ruby]
havenwood has joined #ruby
greenbagels has joined #ruby
diegoviola has joined #ruby
<wasamasa>
birds have feathers. they have bones, too
Rollabunna has quit [Remote host closed the connection]
<pontiki>
well said
<efghi>
and both use '+' for addition---they are essentially the same language
<sud0x>
morning all! I have quite a complex question. I'm trying to read contents from a file and place each line into an array but its quite a unique project. Wondering if anyone can take a look and make suggestions please https://gist.github.com/anonymous/cb3eda3869d321cf3dd6
hamakn has quit [Remote host closed the connection]
sinkensabe has joined #ruby
<apeiros>
sud0x: and your question is?
rshetty has joined #ruby
tier has quit [Remote host closed the connection]
tristanp has quit [Remote host closed the connection]
tristanp has joined #ruby
shock_one has quit [Remote host closed the connection]
<linocisco>
Node.js vs Ruby?
<efghi>
sud0x: easiest way to read lines from file into an array is File.readlines
<pontiki>
linocisco: apples and oranges
fuhgeddaboudit has joined #ruby
<apeiros_>
linocisco: you are being annoying.
x1337807x has joined #ruby
it0a has joined #ruby
<sud0x>
apeiros, how would I be able to retrieve the contents before the :
<linocisco>
node.js is alternative choice to Ruby? because power of capability is almost the same?
shock_one has joined #ruby
tristanp has quit [Ping timeout: 258 seconds]
<apeiros_>
linocisco: node.js is a framework. ruby is a language.
<sud0x>
efghi: can't use an array, have to read the lines and divide them accordingly :/
<pontiki>
node.js is a server-side asynchronous javascript processing system
<pontiki>
ruby is a language
<sud0x>
efghi: using another gem to add them into an array since they're going into an xlsx
<apeiros_>
sud0x: split(/:/, 2)
<efghi>
linocisco: there isn't one answer to all problems
doev has quit [Read error: Connection reset by peer]
<sud0x>
apeiros, awesome -- I'll be placing foo into its own variable though. Kinda want to mark the variable and start of the array contents by that colon (variable word prior to colon, array everything following)
<apeiros_>
sud0x: any particular reason you invent your own serialization?
diegovio1 is now known as diegoviola
<apeiros_>
instead of going with something established, like e.g. yaml
x1337807x has quit [Ping timeout: 260 seconds]
SOLDIERz has joined #ruby
hamakn has joined #ruby
<linocisco>
somebody using Ruby on Windows?
philwantsfish has joined #ruby
hamakn has quit [Remote host closed the connection]
<sud0x>
apeiros: I wanted to use a dictionary for each style but they all have the same category so I can't use a key. Sometimes lines are multi-lines so I want to mark the end by a semicolon. I don't want to reinvent the wheel so if there's something for this I am open to it
<sud0x>
not style, category
<apeiros_>
linocisco: yes. somebody certainly is.
<linocisco>
somebody using Ruby on Windows? I can't see the error is "DL is deprecated, please use Fiddle"
<linocisco>
somebody using Ruby on Windows? I can't see what the error is "DL is deprecated, please use Fiddle"
elastik has joined #ruby
<efghi>
linocisco: just ignore it
<linocisco>
efghi, it is a bug whenever "irb" is called or entered?
<apeiros_>
linocisco: meet google.com. it helps with such stuff.
akaiiro has quit [Ping timeout: 250 seconds]
atmosx has joined #ruby
<apeiros_>
sud0x: yaml is part of rubys stdlib. should your ruby not have it, hit your package maintainer with a broom please.
<linocisco>
ok.
rshetty has quit [Remote host closed the connection]
<sud0x>
lol will do thanks man
<linocisco>
is Ruby better with mySQL or mongoDB ?
<apeiros_>
linocisco: nonsensical question again
<apeiros_>
linocisco: there's drivers for both.
shock_one has quit [Remote host closed the connection]
Mothore____ has joined #ruby
pen has quit []
banister has joined #ruby
banister has quit [Max SendQ exceeded]
Sawbones has joined #ruby
paulog__ has quit [Quit: Connection closed for inactivity]
banister has joined #ruby
banister has quit [Max SendQ exceeded]
<linocisco>
on windows, I have installed ruby and accessible on command prompt through "irb" and mongodb 32bit for windows has been installed. what to do next ?
banister has joined #ruby
rshetty has joined #ruby
banister has quit [Max SendQ exceeded]
<linocisco>
how to test ruby to access mongodb? any guide or URL to follow?
banister has joined #ruby
Mothore____ has quit [Ping timeout: 245 seconds]
banister has quit [Max SendQ exceeded]
linojon has quit [Quit: linojon]
banister has joined #ruby
banister has quit [Max SendQ exceeded]
banister has joined #ruby
banister has quit [Max SendQ exceeded]
banister has joined #ruby
banister has quit [Max SendQ exceeded]
shock_one has joined #ruby
diego_ar has joined #ruby
banister has joined #ruby
banister has quit [Max SendQ exceeded]
<efghi>
yes, seach for "mongodb" and "ruby"
TL has joined #ruby
Ludicrou_ has quit [Remote host closed the connection]
banister has joined #ruby
banister has quit [Max SendQ exceeded]
LudicrousMango has joined #ruby
lbrf has joined #ruby
banister has joined #ruby
banister has quit [Max SendQ exceeded]
ta has joined #ruby
jtheuer has quit [Quit: This computer has gone to sleep]
jimbach has quit [Remote host closed the connection]
<apeiros_>
linocisco: we're not here to hold your hands. invest some effort on your own. if you did, show that you did. e.g. by asking "I found <link to tutorial 1> and <link to tutorial 2>. Any recommendations for another tutorial on mongodb with ruby?"
banister has joined #ruby
kyoshero has quit [Quit: Leaving]
ikaros has quit [Quit: Ex-Chat]
banister has quit [Max SendQ exceeded]
diego_ar has quit [Ping timeout: 244 seconds]
banister has joined #ruby
banister has quit [Max SendQ exceeded]
LudicrousMango has quit [Ping timeout: 244 seconds]
lbrf has quit [Ping timeout: 244 seconds]
banister has joined #ruby
banister has quit [Max SendQ exceeded]
banister has joined #ruby
banister has quit [Max SendQ exceeded]
ta has quit [Ping timeout: 244 seconds]
Mothore____ has joined #ruby
banister has joined #ruby
banister has quit [Max SendQ exceeded]
DLSteve has joined #ruby
it0a has quit [Quit: WeeChat 1.0.1]
jimbach has joined #ruby
banister has joined #ruby
banister has quit [Max SendQ exceeded]
banister has joined #ruby
banister has quit [Max SendQ exceeded]
rshetty_ has joined #ruby
rshetty has quit [Ping timeout: 272 seconds]
bMalum_ has quit [Quit: bMalum_]
ikaros has joined #ruby
jimbach has quit [Remote host closed the connection]
centrx has joined #ruby
linocisco has quit [Quit: Leaving]
twistedpixels is now known as zz_twistedpixels
LudicrousMango has joined #ruby
tristanp has joined #ruby
mgberlin has joined #ruby
<efghi>
linocisco: it might help to know that there are several drivers available; I played a little with MongoMapper, but that was a long time ago, so I can't really help further
tjohnson has joined #ruby
<elastik>
Hello everyone!
<elastik>
I am stuck again! lol
<elastik>
I am trying to insert data from array into a table in my database
<apeiros_>
those should go into the gist. you can gist multiple files, best to put backtraces in a separate file in your gist.
<elastik>
hello havenwood!
jheg has joined #ruby
klmlfl has joined #ruby
wsmoak has quit [Ping timeout: 264 seconds]
<havenwood>
elastik: good morning
anaeem1_ has joined #ruby
<elastik>
I am trying to take the data from my array and insert it into my database
<elastik>
Is that stating the problem correctly?
danijoo has quit [Read error: Connection reset by peer]
oo_ has joined #ruby
<apeiros_>
elastik: having read your code, your problem statement would probably be something like: "I use the mysql gem and I don't know how to insert data into the database"
danijoo has joined #ruby
fgo has quit [Ping timeout: 244 seconds]
<apeiros_>
the whole rest of your code is actually pretty irrelevant to the problem you want to ask us about
jimbach has quit [Ping timeout: 258 seconds]
sinkensabe has quit [Remote host closed the connection]
<elastik>
ok apeiros. thank you for the guidance
kiyote23 has quit [Remote host closed the connection]
<elastik>
I do know how to insert into the database with mysql gem, but not using an array
shredding has quit [Quit: shredding]
<apeiros_>
I too would suggest using sequel. with mysql gem, you'd insert data using an INSERT statement with Mysql#query. like you did. just need to properly write your SQL.
tobacco_joe has quit [Remote host closed the connection]
jonr22 has quit []
enebo has quit [Quit: enebo]
danman has quit [Quit: danman]
Jackneill has joined #ruby
Rollabunna has joined #ruby
mengu has quit [Ping timeout: 256 seconds]
ragingcake_ has left #ruby [#ruby]
Rollabunna has quit [Ping timeout: 265 seconds]
danman has joined #ruby
GGMethos has quit [Ping timeout: 264 seconds]
GGMethos has joined #ruby
banister has joined #ruby
banister has quit [Max SendQ exceeded]
Mothore_____ has joined #ruby
banister has joined #ruby
banister has quit [Max SendQ exceeded]
banister has joined #ruby
banister has quit [Max SendQ exceeded]
Takle has quit [Remote host closed the connection]
Spami has joined #ruby
banister has joined #ruby
banister has quit [Max SendQ exceeded]
timonv_ has joined #ruby
banister has joined #ruby
banister has quit [Max SendQ exceeded]
Mothore____ has quit [Ping timeout: 245 seconds]
banister has joined #ruby
banister has quit [Max SendQ exceeded]
banister has joined #ruby
banister has quit [Max SendQ exceeded]
banister has joined #ruby
banister has quit [Max SendQ exceeded]
Takle has joined #ruby
t7y9r has quit [Ping timeout: 258 seconds]
triple_b has joined #ruby
banister has joined #ruby
banister has quit [Max SendQ exceeded]
Xeago has joined #ruby
anaeem1 has quit [Remote host closed the connection]
t3h_j4n170r has quit [Ping timeout: 244 seconds]
banister has joined #ruby
banister has quit [Max SendQ exceeded]
banister has joined #ruby
banister has quit [Max SendQ exceeded]
banister has joined #ruby
banister has quit [Max SendQ exceeded]
banister has joined #ruby
banister has quit [Max SendQ exceeded]
Aswebb__ has quit [Remote host closed the connection]
banister has joined #ruby
banister has quit [Max SendQ exceeded]
Yzguy has joined #ruby
banister has joined #ruby
banister has quit [Max SendQ exceeded]
banister has joined #ruby
<apeiros_>
gah
banister has quit [Max SendQ exceeded]
agrinb has joined #ruby
josephndenton has joined #ruby
timonv_ has quit [Ping timeout: 245 seconds]
<apeiros_>
I hate when I forget the +b
tristanp has quit [Remote host closed the connection]
klmlfl has quit [Remote host closed the connection]
fgo has joined #ruby
klmlfl has joined #ruby
pushpak has quit [Read error: Connection reset by peer]
agrinb has quit [Ping timeout: 258 seconds]
wsmoak has quit [Quit: wsmoak]
sinkensabe has quit [Remote host closed the connection]
<crome>
the b is overrated
wsmoak has joined #ruby
wsmoak has quit [Changing host]
wsmoak has joined #ruby
fuhgeddaboudit has joined #ruby
sinkensabe has joined #ruby
tobacco_joe has joined #ruby
fgo has quit [Ping timeout: 255 seconds]
DaniG2k has joined #ruby
ptrrr has quit [Quit: ptrrr]
rkalfane has quit [Read error: Connection reset by peer]
lbrf has joined #ruby
Yzguy has quit [Quit: I'm sleeping, go away.]
rkalfane has joined #ruby
kirun has joined #ruby
<n3b_>
hello
StoneCypher has joined #ruby
Cyberheb has joined #ruby
diego_ar has joined #ruby
jimbach has joined #ruby
Channel6 has joined #ruby
iamninja has joined #ruby
lbrf has quit [Ping timeout: 258 seconds]
enebo has joined #ruby
Xeago has quit [Remote host closed the connection]
DaniG2k has quit [Quit: leaving]
<n3b_>
I have a short question. I'm a beginner and I'm trying write some code to grab part of an object, convert them to an hash an put them into a mongo database. No problem for the object, the hash, but I was wondering how to organise my code to do it. For the moment I have an initialize, a to_hash, but where I can put the "mongo insert" method into a new one?
triple_b has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
diego_ar has quit [Ping timeout: 245 seconds]
Aswebb_ has joined #ruby
yfeldblum has joined #ruby
lampd1 has joined #ruby
jimbach has quit [Ping timeout: 250 seconds]
moritzschaefer has joined #ruby
Hobogrammer has joined #ruby
Vile` has quit [Ping timeout: 252 seconds]
t3h_j4n170r has joined #ruby
debia has joined #ruby
<debia>
in ruby erb: how to check if a variable is an array?
<debia>
@var.is_array?
tier has joined #ruby
Vile` has joined #ruby
s00pcan has joined #ruby
tier has quit [Remote host closed the connection]
einarj has joined #ruby
TL has quit [Disconnected by services]
<elastik>
Hello again
yfeldblum has quit [Ping timeout: 244 seconds]
<centrx>
debia, @var.is_a?(Array)
TerjeLarsen has joined #ruby
tier has joined #ruby
<elastik>
I need a little help. I'm trying to insert one element of an array at a time into my db.
Takle has quit [Remote host closed the connection]
<centrx>
elastik, Note, both of these are security risks if ad_links contains unescaped user input
<centrx>
elastik, Also you may want to use an ORM
jtheuer has quit [Quit: This computer has gone to sleep]
tier has quit [Remote host closed the connection]
konsolebox has joined #ruby
<elastik>
centrx, thank you for the example. I am going to test it and try to wrap my head around it. For now this is a learning project. My idea is to get the very basics working first then add security etc.
arietis has joined #ruby
<elastik>
I'm going to read up on ORM
<elastik>
Is there a specific you had in mind? like SQLlite?
einarj has quit [Remote host closed the connection]
<centrx>
elastik, Sequel and ActiveRecord are the two big Ruby ORMs now
<centrx>
elastik, SQLite is a lightweight database (like MySQL but lightweight)
<centrx>
(RDBMS)
danman has quit [Quit: danman]
<apeiros_>
I prefer Sequel without its ORM part actually
<st0mar>
apeiros_: ROM is not a replacement for DataMapper, it's a completely different thing
<apeiros_>
st0mar: ok. I was under the impression that it was its successor.
rylev has joined #ruby
blueOxigen has joined #ruby
Rollabunna has quit [Ping timeout: 244 seconds]
codezomb has joined #ruby
<st0mar>
I believe one of (the main?) author of DataMapper now works on ROM
nobitanobi has quit [Remote host closed the connection]
<havenwood>
st0mar: seems like a replacement to me. you're not going to use DataMapper AND ROM.
bluOxigen has quit [Ping timeout: 245 seconds]
Aswebb_ has quit [Remote host closed the connection]
<st0mar>
or DataMapper AND ActiveRecord?
<havenwood>
well the ActiveRecord folk didn't stop working on it and start ROM
anaeem1_ has quit [Remote host closed the connection]
Aswebb_ has joined #ruby
adriancb has joined #ruby
<st0mar>
some ActiveRecord developer could start working on ROM, it's still not a successor
anaeem1_ has joined #ruby
<havenwood>
DataMapper is dead, long live ROM!
<shevy>
long live CDROM!
Azure has joined #ruby
<st0mar>
ROM is still labeled "experimental" by the authors, maybe a little premature to bury DataMapper
* Hanmac
feels so old because he still knows how to use a walkman ;P
kedibasi has left #ruby [#ruby]
shock_one has joined #ruby
adriancb has quit [Ping timeout: 256 seconds]
Soda has joined #ruby
MuffinPimp has joined #ruby
anaeem1_ has quit [Ping timeout: 252 seconds]
gsd has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
diego_ar has joined #ruby
fuhgeddaboudit has quit [Remote host closed the connection]
Xeago has joined #ruby
Xeago has quit [Remote host closed the connection]
tier has joined #ruby
adriancb has joined #ruby
jimbach has joined #ruby
jdj_dk has joined #ruby
Aswebb_ has quit [Remote host closed the connection]
rj46 has joined #ruby
diego_ar has quit [Ping timeout: 260 seconds]
rylev has quit [Remote host closed the connection]
<rj46>
hello, can I ask here about rbenv ?
<centrx>
yes
mary5030 has quit [Remote host closed the connection]
mary5030 has joined #ruby
jimbach has quit [Ping timeout: 272 seconds]
motto has joined #ruby
motto is now known as Guest19872
jaequery has joined #ruby
pwh has quit []
tier has quit [Remote host closed the connection]
tjohnson has quit [Quit: Connection closed for inactivity]
<havenwood>
rj46: there's no rbenv channel
<rj46>
oo great :) So I am not sure whats happening with my rbenv, on my desktop it works like a charm, but on server it has some problem with permission or paths, and I cant figure out whats wrong, $PATHS are the same, ~/.bashrc the same, chmods the same
m8 has quit [Ping timeout: 250 seconds]
<havenwood>
a chruby and rvm channel, but no rbenv
<rj46>
but everytime I tried run rbenv it says: bad interpreter and not permissions
lbrf has joined #ruby
crdpink2 has joined #ruby
mary5030 has quit [Ping timeout: 258 seconds]
crdpink has quit [Ping timeout: 258 seconds]
st0mar has quit [Ping timeout: 250 seconds]
m8tt8 has joined #ruby
klmlfl has joined #ruby
mary5030 has joined #ruby
<rj46>
it drives me crazy bash: /home/user/.rbenv/bin/rbenv: /usr/bin/env: bad interpreter: no permission
mary5030 has quit [Remote host closed the connection]
mengu has joined #ruby
mengu has joined #ruby
mary5030 has joined #ruby
lbrf has quit [Ping timeout: 245 seconds]
Guest19872 has quit [Ping timeout: 258 seconds]
<shevy>
long live compiling from source
jdj_dk has quit [Remote host closed the connection]
<shevy>
rj46 sounds like a simple fix, no? what are the permissions of the binary /usr/bin/env
<shevy>
you could also hardcode the path towards your ruby directly, rather than having to rely on env, though of course this makes it less flexible. always tradeoffs
reinaldob has joined #ruby
danijoo has quit [Read error: Connection reset by peer]
<rj46>
shevy: I thought that at the beginning but it has proper chmods
mollitz has joined #ruby
<shevy>
what exactly are its chmod values?
<rj46>
This errors shows only when I export path to .rbenv
danijoo has joined #ruby
<rj46>
shevy: -rwxr-xr-x
<rj46>
shevy: The same are on my desktop and everything is fine
moritzschaefer has quit [Ping timeout: 265 seconds]
mary5030 has quit [Ping timeout: 258 seconds]
ValicekB has quit []
redjack1964 has joined #ruby
<rj46>
I figured out that on desktop where rbenv works $PATH has one more path, to shims, I added it manually on server
<shevy>
cool I have the same permissions as that
<rj46>
didnt help
<shevy>
and what if you change the first line, the shebang, to your ruby ?
henesy has quit [Remote host closed the connection]
<shevy>
you don't have any working ruby on your system right now?
jimbach has quit [Ping timeout: 258 seconds]
Takle has quit [Remote host closed the connection]
<rj46>
shevy: at this moment yes, but it should not be problem to rbenv
ht__th has quit [Read error: Connection reset by peer]
agrinb has joined #ruby
jimbach has joined #ruby
lemur has quit [Read error: Connection reset by peer]
ragingcake has joined #ruby
lemur has joined #ruby
<shevy>
well ok that explains why the above code can not work
Jackneill has quit [Ping timeout: 245 seconds]
fgo has joined #ruby
agrinb has quit [Ping timeout: 258 seconds]
jimbach has quit [Ping timeout: 245 seconds]
<rj46>
shevy: damn
tristanp has joined #ruby
chipotle_ has joined #ruby
<rj46>
shevy: I've recently change username for one of users on that machine
<rj46>
changed*
mary5030 has joined #ruby
<rj46>
I am not sure if the group is good
<rj46>
ok id better check this ;p
pandaant has quit [Quit: Lost terminal]
st0mar has joined #ruby
fgo has quit [Ping timeout: 258 seconds]
CakeMeat has left #ruby [#ruby]
ragingcake has quit [Quit: ragingcake]
chipotle has quit [Ping timeout: 252 seconds]
decoponio has quit [Quit: Leaving...]
tristanp has quit [Ping timeout: 258 seconds]
<shevy>
so much hassle
<shevy>
cd /tmp; wget ftp://ftp.ruby-lang.org/pub/ruby/2.1/ruby-2.1.5.tar.bz2
<shevy>
tar jxf ruby-2*bz2; cd ruby-2*; ./configure --prefix=/usr; make; make install
<shevy>
\o/
ragingcake_ has joined #ruby
<shevy>
Has anyone used mruby? Is it possible to have a completely static mruby (no dependencies on any .so)?
TheNet has quit [Quit: Leaving...]
Takle has joined #ruby
kobain has joined #ruby
Megtastique has joined #ruby
kobain has quit [Max SendQ exceeded]
_mtr has joined #ruby
livingstn has joined #ruby
livingstn has quit [Max SendQ exceeded]
devdazed has quit [Quit: Computer has gone to sleep.]
livingstn has joined #ruby
livingstn has quit [Max SendQ exceeded]
livingstn has joined #ruby
livingstn has quit [Max SendQ exceeded]
toretore has joined #ruby
DivineEntity has joined #ruby
nfk has quit [Quit: yawn]
<_mtr>
part
livingstn has joined #ruby
livingstn has quit [Max SendQ exceeded]
livingstn has joined #ruby
livingstn has quit [Max SendQ exceeded]
Azure has quit [Ping timeout: 244 seconds]
kiyote23 has joined #ruby
livingstn has joined #ruby
livingstn has quit [Max SendQ exceeded]
livingstn has joined #ruby
livingstn has quit [Max SendQ exceeded]
<havenwood>
shevy: otool -L /usr/local/bin/mruby #=> /usr/local/bin/mruby: /usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 1212.0.0)
livingstn has joined #ruby
livingstn has quit [Max SendQ exceeded]
livingstn has joined #ruby
livingstn has quit [Max SendQ exceeded]
<shevy>
hmm not sure how this works from osx to linux
teddyp1cker has quit [Remote host closed the connection]
_mtr has quit [Ping timeout: 258 seconds]
teddyp1cker has joined #ruby
fabrice31 has joined #ruby
teddyp1cker has quit [Read error: No route to host]
teddyp1cker has joined #ruby
mikesplain has joined #ruby
fandi has quit [Read error: Connection reset by peer]
SCHAAP137 has quit [Quit: Leaving]
Azure has joined #ruby
_mtr has joined #ruby
fabrice31 has quit [Ping timeout: 244 seconds]
spastorino has joined #ruby
mikesplain has quit [Client Quit]
<sud0x>
quick question guys, I have a string being split by comma (.split(',')) and going into an array. I want to split it up into two arrays with a colon :. My string will be something like a, b, c:d,e,f would it be possible to split this into two arrays by the colon delimeter?
mbff has joined #ruby
klmlfl has quit [Remote host closed the connection]
<mbff>
Hello! I have a ruby file that is getting to large to handle. Is there a way to split up my code into different files and call them from a main file without having to change how my code is structured?
<sud0x>
one more question guys, how would I be able to remove the quotes from a string in an array? i.e. i have ["a", "b", "c"] but I want to make it [a,b,c]?
<Radar>
sud0x: .inspect
shock_one has joined #ruby
shock_one has quit [Remote host closed the connection]
<Radar>
Oops, not in recent versions of Ruby :P
<Radar>
sud0x: why do you want that output?
diego_ar has joined #ruby
zemiudo has joined #ruby
tier has joined #ruby
<sud0x>
hmm that doesn't work Radar
<Radar>
'[' + ['a','b','c'].join(',') + ']'
<Radar>
sud0x: yes, that is why I said "oops"
<sud0x>
I have the contents in a file, when I pull them from the file they're getting pulled as a string
<sud0x>
I need to put them into an array
<Radar>
sud0x: what contents?
<Radar>
How are you pulling them?
<Radar>
Why do they need to be an arrayu?
<Radar>
-u
<sud0x>
It has to be an array, I am pulling them from a file using readlines and doing stripping of newlines and all
atomical has quit [Read error: Connection reset by peer]
jheg has quit [Quit: jheg]
* Radar
gives up because sud0x is providing fake values
* Radar
is getting tired of helping people on IRC with fake problems
<shevy>
hahaha
<debia>
so I add some control structures to an erb template
<shevy>
sud0x he says you are a fake!
<debia>
however, this introduces some unintended whitespace/new lines
<debia>
can I avoid this for a line?
<sud0x>
shevy: typical irc behavior
_mtr has joined #ruby
<sud0x>
does anyone care to help?
giuseppesolinas has joined #ruby
<wasamasa>
sud0x: your description sounds like you don't understand what representations are
<Radar>
sud0x: Yes I care to help but only with real problems.
<Radar>
And real code, and real files.
<Radar>
If you give me this fake bullshit then I'm going to be solving a COMPLETELY DIFFERENT problem to the one you're solving.
<wasamasa>
<sud0x> one more question guys, how would I be able to remove the quotes from a string in an array? i.e. i have ["a", "b", "c"] but I want to make it [a,b,c]?
pwh has quit []
atomical has joined #ruby
<wasamasa>
ruby puts quotes around strings to tell you they're strings
<sud0x>
Radar: My file's contents are none of your concern. If you want to help, help -- don't cry like a child.
<Radar>
sud0x: I can't help you if I don't have the real information that I need to help you.
<debia>
shevy: hi
<momomomomo>
sud0x: !fake
<helpa>
sud0x: Please do not use fake values, as they can be confusing or misleading. Sometimes both.
<debia>
I get this: <% if @value and not @value.empty? -%>
<Radar>
sud0x: Saying that I am crying like a child is a personal attack and pretty low imo
<debia>
Detail: undefined method `empty?' for true:TrueClass
<sud0x>
wasamasa: hmm, care to elborate?
yourabi has joined #ruby
<debia>
because value can be a boolean
<wasamasa>
sud0x: no, that's a pretty basic thing to know as a programmer
<debia>
how to use an empty function which does not whine on a boolean?
<debia>
anyone?
<sud0x>
wasamasa: gotcha, thanks
_mtr has quit [Client Quit]
<wasamasa>
sud0x: just because irb displays strings as some glyphs with quotes around them doesn't mean they contain quotes
last_staff has quit [Quit: goin' to be- zzZZzzzz....]
<soahccc>
what about %w[a b c d e] ?
<debia>
anyone? :D
<momomomomo>
debia: !beg
<debia>
empty? which doesn't whine on boolean?
<momomomomo>
I can never remmeber that command
<debia>
!desperated
<debia>
!depressed
<debia>
!sad
<momomomomo>
!rule10
<helpa>
Do not beg / plead with people to help you. This includes asking questions like "Any ideas?" after posting your original question.
<centrx>
debia, ActiveSupport/Rails has #blank? you can copy/use that
<sud0x>
Radar: say what you want. I gave you real code, with sample values. I am not going to write the sentences that I have in my file for you or the www
<helpa>
momomomomo: Nope. No one. Ever. In the history of the world.
<debia>
!helpa
<Radar>
!unworthy
<helpa>
You are not worthy of this bot!
<debia>
centrx: but I can't use native ruby functions?
<shevy>
god guys
<debia>
lol
<shevy>
you are bot milking
ta has quit [Remote host closed the connection]
<debia>
the bot feels purposeful now
<wasamasa>
lol
<soahccc>
debia: look at how blank? is implemented, it's quite simple but useful
_JokerDoom has joined #ruby
<centrx>
debia, Well your design looks odd, may be a better way to do it in native Ruby
Mothore_____ has quit [Quit: Be back later ...]
<centrx>
debia, if @value and not @value.empty? yet "true" is an accepted value, what is your real intention?
JokerDoom has quit [Ping timeout: 265 seconds]
<sud0x>
wasamasa: the values are coming from a file (string). I think I'm understanding their representation -- but thanks. I actually figured it out while trying to explain it
<debia>
centrx: to catch undefined, null
<debia>
right, false wouldn't pass through
<wasamasa>
sud0x: rubberduck debugging ftw :P
<debia>
damn damn
<sud0x>
wasamasa: :P
<centrx>
debia, Then if @value is all you need, @value.empty? is for arrays
<wasamasa>
sud0x: also, there's some stuff in ruby's stdlib (and external libraries) that applies magic
<wasamasa>
sud0x: like, the csv library that sees quoted values and stripes the quotes away automatically
<debia>
centrx: ok, but would @value let a boolean false still pass?