davejlong has quit [Remote host closed the connection]
n008f4g_ has quit [Ping timeout: 246 seconds]
dopie has joined #ruby
havenwood has quit [Ping timeout: 240 seconds]
Spami has quit [Quit: This computer has gone to sleep]
casadei_ has joined #ruby
wallerdev has quit [Ping timeout: 256 seconds]
benlovell has joined #ruby
phutchins has quit [Read error: No route to host]
blaines_ has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
allomov has quit [Ping timeout: 240 seconds]
phutchins has joined #ruby
maletor has quit [Quit: Computer has gone to sleep.]
eGGsha is now known as eGGshke
duncannz has joined #ruby
Stratege has joined #ruby
eGGshke is now known as eGGsha
duderonomy has joined #ruby
casadei_ has quit [Ping timeout: 264 seconds]
benlovell has quit [Ping timeout: 264 seconds]
arturmartins has quit [Quit: Leaving...]
scripore has quit [Quit: Leaving]
jonee has joined #ruby
Obfuscate has quit [Quit: Obfuscate]
bruno- has joined #ruby
ammbot has joined #ruby
athos_diddy has quit []
benlovell has joined #ruby
poguez_ has quit [Quit: Connection closed for inactivity]
jonee has quit [Ping timeout: 265 seconds]
bruno- has quit [Ping timeout: 246 seconds]
quazimodo has quit [Ping timeout: 246 seconds]
quimrstorres has joined #ruby
benlovell has quit [Ping timeout: 264 seconds]
howdoi has joined #ruby
charliesome has quit [Quit: zzz]
jcdesimp has joined #ruby
quimrstorres has quit [Ping timeout: 246 seconds]
benlovell has joined #ruby
robbyoconnor has joined #ruby
tkuchiki has joined #ruby
charliesome has joined #ruby
charliesome has quit [Client Quit]
willywos has joined #ruby
RobertBirnie has joined #ruby
idiocrash has joined #ruby
sarkyniin has quit [Read error: No route to host]
sarkyniin has joined #ruby
benlovell has quit [Ping timeout: 246 seconds]
jonee has joined #ruby
sankaber has joined #ruby
hololeap has joined #ruby
bonhoeffer has joined #ruby
Igorshp has joined #ruby
duncannz has quit [Ping timeout: 240 seconds]
yqt has quit [Ping timeout: 246 seconds]
tkuchiki has quit [Remote host closed the connection]
swgillespie has joined #ruby
bronson has quit [Remote host closed the connection]
kurosawa has joined #ruby
yfeldblum has quit [Remote host closed the connection]
kurosawa has left #ruby [#ruby]
Igorshp has quit [Ping timeout: 264 seconds]
tkuchiki has joined #ruby
havenwood has joined #ruby
polysics has quit [Remote host closed the connection]
zacstewart has quit [Remote host closed the connection]
brianpWins has joined #ruby
charliesome has joined #ruby
xkickflip has quit [Ping timeout: 244 seconds]
TinkerTyper has quit [Ping timeout: 256 seconds]
kurosawa has joined #ruby
<hololeap>
so what is "self"? is it just a pointer?
<hololeap>
in the c sense
Channel6 has joined #ruby
cytoskeletor has joined #ruby
RobertBirnie has quit [Ping timeout: 256 seconds]
kurosawa has left #ruby [#ruby]
tkuchiki has quit [Remote host closed the connection]
Pupeno has joined #ruby
Pupeno_ has quit [Read error: Connection reset by peer]
TinkerTyper has joined #ruby
RobertBirnie has joined #ruby
gamename has joined #ruby
<stbenjam>
hololeap: in ruby, it refers to the current object. i.e. in an instance of a class, it refers to the instance itself
<stbenjam>
hololeap: outside of ruby that's a bit of an existential question. some doubt the self even exists.
cytoskeletor has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
<delsol>
I have a couple stupid questions about active record if anyone has a minute or two.
<hololeap>
stbenjam: lol. i actually just had a "whoa" moment earlier today where i saw the philosophical connection between existentialism and ruby :p
crowell has quit [Remote host closed the connection]
crowell has joined #ruby
brianpWins_ has joined #ruby
crowell has quit [Changing host]
crowell has joined #ruby
<hololeap>
delsol: fire away
fabrice31 has joined #ruby
<delsol>
hololeap: OK, so if you have active record loading a bunch of things….. say, animals.
jonee has quit [Ping timeout: 244 seconds]
brianpWins has quit [Ping timeout: 252 seconds]
brianpWins_ is now known as brianpWins
<delsol>
and we are loading them by groups… so we have a heading of "FISH" then different types of fish, and we might have different info about each type of fish stored in the database
braincrash has quit [Quit: bye bye]
<delsol>
then we load "REPTILES", have the heading, then have info about the different types of reptiles...
willywos has quit [Ping timeout: 246 seconds]
<delsol>
and if instead of just having the options of fish, reptiles, birds etc… we can load an additional layer....
<delsol>
so fish: salt water/freshwater, then the different types, etc....
<delsol>
looking at the mysql query log, it looks like active record is doing stupid crap.
<delsol>
like re-loading all the info about "FISH" every time it loads a fish…. (to determine if its salt or freshwater?)
<delsol>
rather than go… OH, I need to load all the info about all the different categories…. and loading them all once...
<delsol>
it does the query every time it loads a sub-record…. again and again and again....
fabrice31 has quit [Ping timeout: 240 seconds]
<delsol>
and instead of doing a select * from table where id in (4,5,6,7,8,9,10)
<delsol>
it does a select * from table where id = 4; (followed by another query for 5, another for 6, another for 7…. and so on.
jack_rabbit has joined #ruby
<delsol>
is this active record being stupid, or programmer being stupid?
<delsol>
it appears that if you have category.name, it reloads all the info about that category again…..
tkuchiki has joined #ruby
braincrash has joined #ruby
<hololeap>
delsol: i'm pretty sure that's how it has to work. rails doesn't know if the record has changed so it has to query it every time. it's up to the db to do caching and respond quickly
RobertBirnie has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<delsol>
My other question… if I hand write a couple SQL queries to get all the fields I possibly might need to fill in all of the information in the entire form….. and when you edit info in one of the boxes, active record needs the row object to autosave it, or can I build the row object without having active record go grab each individual record…. every single time?
<hololeap>
delsol: activerecord is just an interface between rails and the database
<delsol>
right.
<hololeap>
you can override the method for a field
<hololeap>
then use an instance variable to cache it. something like: def fish_type; @fish_type ||= read_attribute :fish_type; end
<delsol>
I mean, I can write a query that will give me all of the info I need on a given screen about everything I need there… in one or two queries….. (rather than load everything in one giant screen… I can say, have category in a list box, and when I select "FISH" I'll have another query go get me ALL of the info I need about every fish I might possibily need in that instance…. all at once)
<hololeap>
as long as you keep that object alive it will keep the original query
<delsol>
But it needs to re-query for each object?
<hololeap>
delsol: i'm not 100% sure. you should ask in #RubyOnRails
t0rrieri has joined #ruby
<delsol>
Because when you have a screen with a few hundred rows, and 6-8 pieces of info in each row……. it takes 15-30 seconds to populate the screen.
<hololeap>
delsol: somebody else might know a little bit more about the caching behavior of RoR
<delsol>
Not using rails.
<delsol>
just ruby, activerecord and rubyGTK
<hololeap>
still activerecord is a part of rails
montyboy_ is now known as montyboy
<delsol>
K
tmtwd has joined #ruby
<delsol>
I'm just sitting staring at the query log… saying "Only an idiot would load data this way"
konr has quit [Quit: Connection closed for inactivity]
<delsol>
and trying to determine if I and other programmers are the idiots… or if rails is the idiot....
<delsol>
er, activerecord is the idiot.
<hololeap>
delsol: it's all convention over configuration, so its doubtful you're doing anything wrong. you probably just need to configure it... ask in the other channel and hopefully you'll get an answer :D
kodiak_texan has joined #ruby
<delsol>
Even with the database on the same machine… its slow. Like, overclock machine to 4.4ghz to get some of the snappy back slow.
edwinvdgraaf has joined #ruby
tkuchiki has quit [Remote host closed the connection]
<delsol>
I can't imagine how horribly slow it'd be with network latency between DB server and ruby app...
jenrzzz has joined #ruby
prestorium has joined #ruby
jonee has joined #ruby
Yzguy has joined #ruby
edwinvdgraaf has quit [Ping timeout: 252 seconds]
jenrzzz has quit [Ping timeout: 260 seconds]
quimrstorres has joined #ruby
sarkyniin has quit [Remote host closed the connection]
<delsol>
Thanks for your time hololeap. :)
icebourg has joined #ruby
sarkyniin has joined #ruby
j4cknewt has quit [Remote host closed the connection]
benlovell has joined #ruby
jonee has quit [Ping timeout: 252 seconds]
maletor has joined #ruby
djbkd has joined #ruby
quimrstorres has quit [Ping timeout: 264 seconds]
benlovell has quit [Ping timeout: 260 seconds]
matcouto has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
matcouto has joined #ruby
<hololeap>
delsol: NP
gamename has quit [Remote host closed the connection]
benlovell has joined #ruby
bungoman has joined #ruby
s00pcan has quit [Ping timeout: 265 seconds]
Kalov has quit []
s00pcan has joined #ruby
bronson has joined #ruby
AviShastry has joined #ruby
eggoez has quit [Ping timeout: 246 seconds]
benlovell has quit [Ping timeout: 244 seconds]
jonee has joined #ruby
drewvanstone has joined #ruby
sepp2k has quit [Read error: Connection reset by peer]
bonhoeffer has quit [Ping timeout: 244 seconds]
bronson has quit [Ping timeout: 256 seconds]
framling has joined #ruby
KnownSyntax has joined #ruby
polysics has joined #ruby
eggoez has joined #ruby
dgutierrez1287 has joined #ruby
hazelux has joined #ruby
zacstewart has joined #ruby
polysics has quit [Ping timeout: 240 seconds]
sarkyniin has quit [Quit: Quit]
flaf has left #ruby ["WeeChat 1.0.1"]
dgutierrez1287 has quit [Ping timeout: 265 seconds]
framling has quit [Remote host closed the connection]
casadei_ has joined #ruby
Obfuscate has joined #ruby
xkickflip has joined #ruby
Kalov has joined #ruby
gix has quit [Ping timeout: 240 seconds]
eggoez has quit [Ping timeout: 240 seconds]
darkf has joined #ruby
gix has joined #ruby
casadei_ has quit [Ping timeout: 256 seconds]
shinnya has quit [Ping timeout: 240 seconds]
weemsledeux has joined #ruby
eggoez has joined #ruby
baweaver has joined #ruby
Yzguy has quit [Quit: Cya]
tmtwd has quit [Remote host closed the connection]
benlovell has joined #ruby
jaredrhine has quit [Read error: Connection reset by peer]
kfpratt has joined #ruby
benlovell has quit [Ping timeout: 246 seconds]
jonee has quit [Ping timeout: 246 seconds]
atomical has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
jaredrhine has joined #ruby
sevenseacat has joined #ruby
SCHAAP137 has quit [Ping timeout: 264 seconds]
djbkd has quit [Quit: My people need me...]
djbkd has joined #ruby
djbkd has quit [Remote host closed the connection]
djbkd has joined #ruby
djbkd has quit [Remote host closed the connection]
djbkd has joined #ruby
<kodiak_texan>
So say for a problem I need to write a method to return a random element in an array. I obviously am not allowed to use array#sample. I am having a lot of trouble. My return element is always the same. I have tried many variation of using #shuffle and rand but alas I have hit a wall. Any guidance is appreciated.
djbkd has quit [Client Quit]
<havenwood>
kodiak_texan: What do you have so far? Gist it?
Volsus has joined #ruby
Channel6 has quit [Quit: Leaving]
<kodiak_texan>
Okay, any certain rules on code pasting?
<Thomas-0725>
kodiak_texan, is your method supposed to return 1 element, or n elements? If it is supposed to return n elements, do the elements have to be unique, or can they be duplicated?
sankaber has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
jenrzzz has quit [Ping timeout: 256 seconds]
zacstewart has quit [Ping timeout: 265 seconds]
<kodiak_texan>
The method is supposed to return n elements, unique but duplication occuring is fine.
jonee has joined #ruby
j4cknewt has joined #ruby
<Thomas-0725>
kodiak_texan, the obvious issue is that you are just calling rand without a parameter. This will return a float, which when used as an index to an array will always truncate down to 0. You need to call rand with a parameter. The parameter is Rand(UPPER_BOUND) It will always return a number n such that 0 <= n < UPPER_BOUND.
<Thomas-0725>
Your upper bound here would be the size of your array, array.size
drewvanstone has quit [Ping timeout: 264 seconds]
darkf has quit [Ping timeout: 248 seconds]
bungoman has quit [Remote host closed the connection]
Fezzler has joined #ruby
crdpink2 has joined #ruby
crdpink has quit [Ping timeout: 248 seconds]
<Thomas-0725>
To clarify, rand without a parameter returns a float that equals zero or is between zero and one. (0 <= rand < 1)
<hololeap>
kodiak_texan: you need to make sure the gist is public before you paste it or else we won't be able to see it :D
maletor has quit [Quit: Computer has gone to sleep.]
crdpink has joined #ruby
crdpink2 has quit [Ping timeout: 248 seconds]
<toretore>
and copy the url from the browser's address bar
<Thomas-0725>
Close, but you need to push your selected elements onto a new array to return, otherwise you will only return one thing, and it will not be an element of the array. Instead, it will be the result of n.times, which is just n.
<Thomas-0725>
Can anyone provide an example of a recursive method that is best solved by recursion and not by some non recursive variant? Simpler example are better, but any example works
freerobby has quit [Quit: Leaving.]
dfockler has quit [Ping timeout: 265 seconds]
<Thomas-0725>
nevermind. There's basically a book written about that very topic on stack exchange
mleung has joined #ruby
<bougyman>
a lot depends on whether tail-call recursion is optimized in the implementation.
mleung has quit [Client Quit]
howdoi has quit [Quit: Connection closed for inactivity]
wn33dk has joined #ruby
mleung has joined #ruby
arooni-mobile has quit [Ping timeout: 248 seconds]
tjbiddle has quit [Quit: tjbiddle]
Rickmasta has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
bungoman has quit [Remote host closed the connection]
arup_r has joined #ruby
totimkopf has joined #ruby
idiocras_ has joined #ruby
idiocrash has quit [Read error: Connection reset by peer]
tjbiddle has joined #ruby
arup_r has quit [Read error: Connection reset by peer]
quimrstorres has joined #ruby
reset has quit [Quit: Leaving...]
arup_r has joined #ruby
wn33dk has quit [Quit: Leaving]
ryba has quit [Ping timeout: 264 seconds]
idiocrash has joined #ruby
idiocras_ has quit [Read error: Connection reset by peer]
jenrzzz has quit [Ping timeout: 255 seconds]
idiocrash has quit [Read error: Connection reset by peer]
idiocrash has joined #ruby
mleung has quit [Quit: mleung]
quimrstorres has quit [Ping timeout: 240 seconds]
benlieb has quit [Quit: benlieb]
desigx has quit [Ping timeout: 248 seconds]
davedev24 has quit [Remote host closed the connection]
j4cknewt has quit [Remote host closed the connection]
peter_paule has quit [Ping timeout: 264 seconds]
swgillespie has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
tkuchiki has quit [Remote host closed the connection]
tkuchiki has joined #ruby
krz has quit [Read error: Connection reset by peer]
quazimodo has joined #ruby
swgillespie has joined #ruby
zacstewart has joined #ruby
revath has joined #ruby
peter_paule has joined #ruby
HOOL is now known as ZYPP
GeissT_ has joined #ruby
_ht has joined #ruby
domgetter has joined #ruby
willywos has joined #ruby
_blizzy_ has joined #ruby
twintail has quit [Remote host closed the connection]
GeissT has quit [Ping timeout: 246 seconds]
krz has joined #ruby
willywos has quit [Client Quit]
<dubkoidragon>
hey so Ruby seems to preffer hashes or dictionaries instead of arrays or lists when compared to python. Would this be an appropriate assumtion? I mean I know they do the same things but just from the two languages tutorials I've noticed the amount of time spent on each, relatively..
<domgetter>
How do I add a token to a Net::HTTP::Get object?
<[k->
they are not the same thing
<dubkoidragon>
I know that
<dubkoidragon>
very well lol
<dubkoidragon>
and it doesntm atter im just wondering
_djbkd has quit [Remote host closed the connection]
<[k->
they do not do the same thing
<dubkoidragon>
like you mean a python dict doenst do the same things as a ruby hash??
djbkd_ has joined #ruby
lxsameer has joined #ruby
<domgetter>
dubkoidragon: The way you phrased your question makes it look like you claim that arrays and hashes do the same thing.
<dubkoidragon>
oh
<[k->
^
<dubkoidragon>
not whati meant
<dubkoidragon>
ata ll
<domgetter>
did you mean that dicts:hashes::lists:arrays ?
znz_jp has quit [Ping timeout: 248 seconds]
<sevenseacat>
key-value pairs are totally different than a list of things
<dubkoidragon>
i meant like in the ruby tutorial a lot more time is spent on hashes than arrays, and back when i did puthon tutorial more time was spent on lists pver dictionaries
<sevenseacat>
'in the ruby tutorial' which one?
<dubkoidragon>
I've done many for both languages, thats my general view
<[k->
python lists have list comprehension
<sevenseacat>
ah, vague assumptions, my favorite.
<[k->
Ruby arrays do not
tkuchiki has quit [Remote host closed the connection]
<[k->
so the end
<dubkoidragon>
Thanks k, That makes sense
<domgetter>
[k-: of course, lists aren't the only thing that have comprehensions in python
peter_paule has quit [Ping timeout: 246 seconds]
<dubkoidragon>
sevencat, i see how you think that but i document my time spent learning and its a factual trend ive noticed
<sevenseacat>
okay. they're two different data structures that do two different things. use the one thats appropriate for your task. end of story :)
<domgetter>
dubkoidragon: is your methodology reproducable? :P
<dubkoidragon>
what you mean dom
closer has quit [Ping timeout: 272 seconds]
jenrzzz has quit [Ping timeout: 246 seconds]
<[k->
he wants to know how you learn so he can verify it himself
<domgetter>
I was joking about the implied rigor of your documentation regarding your learning process.
<dubkoidragon>
ahh
<dubkoidragon>
i see
relix has joined #ruby
peter_paule has joined #ruby
<dubkoidragon>
my bad. like I just kinda write down all the different lessons and examples I do, and that has been the trend
<[k->
he still wants to verify it too
<dubkoidragon>
was just curious if i was missing somerhing
<domgetter>
nah, Im too lazy
GeissT has joined #ruby
Pupeno has quit [Remote host closed the connection]
<dubkoidragon>
i can send all my study doc. but its not well organized at least not if you arent in my breain lol
znz_jp has joined #ruby
closer has joined #ruby
<domgetter>
Is there a recommended gem I should be using to make http requests? Is HTTParty the go-to?
swgillespie has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<[k->
I'm feeling upset that I can't write one line Haskell :c
GeissT_ has quit [Ping timeout: 255 seconds]
zacstewart has quit [Ping timeout: 244 seconds]
<dubkoidragon>
hey question
<dubkoidragon>
movies = Hash.new
<dubkoidragon>
movies [:pulp fiction] = 10
<sevenseacat>
thats not valid.
<dubkoidragon>
what is the proper way in that notation to add a sybol key
<[k->
because you have a space
<dubkoidragon>
itll work fora string key
<sevenseacat>
you probably want movies[:pulp_fiction]
<dubkoidragon>
oooohhhh
<dubkoidragon>
ok
<sevenseacat>
no spaces.
<dubkoidragon>
oki
tkuchiki has joined #ruby
<dubkoidragon>
perfectly worked now. Thank you
symm- has quit [Ping timeout: 246 seconds]
<[k->
also, we do not leave spaces between the hash and the []
<apeiros>
dubkoidragon: you can have spaces in symbols, but then you have to quote them
revath has quit [Read error: Connection reset by peer]
<ace_me>
you are complicating things... I already installed that gem above
<Nathan_DeHiggers>
they have docs on the ruby gems site
<ace_me>
and it is not working on windows
bronson has quit [Ping timeout: 244 seconds]
<ace_me>
I did installed in the mean time on a ubuntu virtual box
<ace_me>
and it is working\
<ace_me>
so I was looking only for a solution to add maybe some path for the newly installed gem
<Nathan_DeHiggers>
so the only problem you're getting is that it's saying command not found under windows server?
<ace_me>
sure
<Nathan_DeHiggers>
sorry i hope someone else helps you... i have to run to work :(
<Nathan_DeHiggers>
i wish you the best of luck :)
Guest90559 has quit [Quit: Saliendo]
Guest63816 has quit [Quit: Saliendo]
Nathan_DeHiggers has quit [Quit: Page closed]
max_v has joined #ruby
spider-mario has joined #ruby
chinmay_dd has joined #ruby
allomov has joined #ruby
chinmay_dd has quit [Read error: Connection reset by peer]
bertro has joined #ruby
chinmay_dd has joined #ruby
znz_jp has joined #ruby
bruno- has joined #ruby
Igorshp has joined #ruby
fabrice31 has joined #ruby
sinkensabe has quit [Remote host closed the connection]
howdoi has joined #ruby
peter_paule has quit [Ping timeout: 244 seconds]
bruno- has quit [Ping timeout: 244 seconds]
Muhannad has quit [Remote host closed the connection]
Igorshp has quit [Ping timeout: 246 seconds]
fabrice31 has quit [Ping timeout: 246 seconds]
max_v has quit [Quit: Saliendo]
chinmay_dd has quit [Ping timeout: 248 seconds]
yardenbar has joined #ruby
mosez has quit [Ping timeout: 256 seconds]
mosez has joined #ruby
peter_paule has joined #ruby
lkba has joined #ruby
Musashi007 has joined #ruby
last_staff has quit [Read error: Connection reset by peer]
relix has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
RatelDev has quit [Quit: Leaving]
eGGsha has joined #ruby
MagePsycho has joined #ruby
duncannz has quit [Remote host closed the connection]
AlphaAtom has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
nofxx has quit [Ping timeout: 256 seconds]
quimrstorres has joined #ruby
peter_paule has quit [Ping timeout: 252 seconds]
AlphaAtom has joined #ruby
max_v has joined #ruby
AlphaAtom has quit [Client Quit]
znz_jp has quit [Quit: kill -QUIT $$]
quimrstorres has quit [Ping timeout: 256 seconds]
eGGsha is now known as eGGshke
ndrei has quit [Ping timeout: 248 seconds]
revath has joined #ruby
AlphaAtom has joined #ruby
eGGshke is now known as eGGsha
eGGsha has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
znz_jp has joined #ruby
AlphaAtom has quit [Client Quit]
pjsim has joined #ruby
ndrei has joined #ruby
kfpratt has joined #ruby
pjsim has quit [Client Quit]
arup_r has joined #ruby
max_v has quit [Quit: Saliendo]
zz_Outlastsheep is now known as Outlastsheep
kfpratt has quit [Remote host closed the connection]
markholmes has quit [Quit: So it goes.]
max has joined #ruby
max is now known as Guest76444
DEA7TH_ has joined #ruby
tkuchiki has quit [Remote host closed the connection]
Guest76444 has quit [Client Quit]
desigx has joined #ruby
<ljarvis>
moin
vivekananda has quit [Ping timeout: 265 seconds]
<[k->
why did you ban him :o
<[k->
ljarvis: hi
galeido has joined #ruby
<shevy>
>> Date::MONTHNAMES.first
<ruboto>
shevy # => uninitialized constant Date (NameError) ...check link for more (https://eval.in/400871)
<shevy>
hmm ... why do I have a nil as the first month ...
<[k->
shevy!
<shevy>
I am totally confused
<ljarvis>
shevy: for convenience
benlovell has joined #ruby
<ljarvis>
shevy: basically because in English, months actually count from 1 to 12 (unlike day names) so the true numerical representation of January is 1
<[k->
wat.
<shevy>
I see
symm- has joined #ruby
tkuchiki has joined #ruby
tkuchiki has quit [Remote host closed the connection]
<jhass>
so you can do Date::MONTHNAMES[some_date.month]
unzan has joined #ruby
lkba_ has joined #ruby
unzan has quit [Client Quit]
duncannz has joined #ruby
benlovell has quit [Ping timeout: 260 seconds]
phutchins has joined #ruby
m8 has joined #ruby
lkba has quit [Ping timeout: 246 seconds]
DLSteve has joined #ruby
DLSteve has quit [Client Quit]
DLSteve has joined #ruby
mikecmpbll has joined #ruby
revath has quit [Read error: Connection reset by peer]
phutchins has quit [Ping timeout: 240 seconds]
arup_r has quit [Quit: Leaving]
Pupeno has joined #ruby
Pupeno has joined #ruby
jack_rabbit has quit [Ping timeout: 260 seconds]
benlovell has joined #ruby
Soda has joined #ruby
druznek has joined #ruby
plashchynski has joined #ruby
<dubkoidragon>
good night boys and girls, thanks for all the help today
<[k->
offensive!
ayonkhan has quit []
<dubkoidragon>
actually? or joke?
<[k->
not joke
<dubkoidragon>
why was that offensive
<shevy>
you forgot to include cats and robots
<dubkoidragon>
shoot I knew I forgot something
ccooke has quit [Read error: Connection reset by peer]
<shevy>
[k- oh for a moment I thought you were writing real code :)
<shevy>
n3vtelen_ yeah that may be one way, although you could also change if not youtube_video_url.to_s == '' into unless youtube_video_url.to_s.empty?
<[k->
if !*
<shevy>
>> x = ''; puts 'it is nil or empty' if x.nil? || x.empty?
<shevy>
I remember I recieved two complaints about my gems once per email - the first one complained that I have no documentation (he is right!), the other one actually found a real bug so he got a cookie
<apeiros>
makes more sense
<adaedra>
[k-: checks from rubocop all have configuration, you can enable, disable, or change them through a file, if defaults is not to your liking.
<arup_r>
yes.. I am trying to figure out what is the I can call update method by instantiating the right class as per the response code
<centrx>
put the logic in the class
<arup_r>
ok
<arup_r>
you mean case/when logic inside the parent class
<arup_r>
?
quimrstorres has quit [Remote host closed the connection]
iateadonut has joined #ruby
<centrx>
arup_r, yes, ultimately you need that because you're basing the decision off of a string param
<arup_r>
I am bit lost to arrange it so asked to find out the tricks
<centrx>
it seems
<[k->
if I knew vim I would look like a cool elite hacker
_ixti_ has quit [Ping timeout: 240 seconds]
<jhass>
you could build a hash, RESPONSE_CODE_HANDLERS = {"FOO" => Foo, "BAR" => Bar} and then RESPONSE_CODE_HANDLERS[response_code.upcase].new params
<centrx>
yeah hash is good
<arup_r>
humm
<[k->
less painful actually
<[k->
(IMO)
<centrx>
yes but you still need string somewhere, not a duck
<[k->
I was totally thrown off
<arup_r>
centrx, well can't use in my usecase the duck typing it seems.. I thought I could
ndrei has quit [Ping timeout: 244 seconds]
Spami_ has joined #ruby
centrx has quit [Quit: Shutting down, Please wait...]
ndrei has joined #ruby
<arup_r>
ok.. just one question Inheritance and Duck typing are 2 diff techniques.. as I am getting the update method via inheritance so duck typing here not a topic.. mm that's what I feels.
_blizzy_ has quit [Ping timeout: 248 seconds]
exadeci has joined #ruby
<arup_r>
jhass, I like the hash technique so should I add the hash logic as you said inside the Response class in a factory method?
<arup_r>
Is it good idea ?
<arup_r>
Response.creat_response response_code like that?
whiteline has quit [Remote host closed the connection]
t0rn has joined #ruby
<t0rn>
hi! looking for an entry-level RoR job in the New York area
quimrstorres has joined #ruby
rubie has joined #ruby
Kalov has quit []
<havenwood>
t0rn: You might give #RubyOnRails a try if you're looking for Rails.
shoutsid06 has joined #ruby
quimrstorres has quit [Remote host closed the connection]
phutchins has joined #ruby
shoutsid06 has quit [Read error: Connection reset by peer]
psy_ has joined #ruby
<t0rn>
will do, thanks
psy_ has quit [Max SendQ exceeded]
shoutsid06 has joined #ruby
psy_ has joined #ruby
t0rn has left #ruby [#ruby]
ht__ has quit [Quit: Konversation terminated!]
Feyn has quit [Quit: Leaving]
lxsameer has joined #ruby
CalvinnHobbes has quit [Ping timeout: 250 seconds]
quimrstorres has joined #ruby
prestorium has joined #ruby
ni291187 has joined #ruby
quimrstorres has quit [Remote host closed the connection]
ni291187 has quit [Remote host closed the connection]
tmtwd has joined #ruby
endash has quit [Quit: endash]
yilmazalican has joined #ruby
<yilmazalican>
hello
<yilmazalican>
whats up guys
<havenwood>
yilmazalican: hi
<yilmazalican>
havenwood how u doing man
sankaber has joined #ruby
sinkensabe has joined #ruby
yilmazalican has quit [Remote host closed the connection]
<havenwood>
Coffeetime!
ndrei has quit [Ping timeout: 264 seconds]
DEA7TH_ has joined #ruby
araujo has quit [Quit: Leaving]
ndrei has joined #ruby
symm- has joined #ruby
quimrstorres has joined #ruby
shoutsid06 has quit []
quimrstorres has quit [Remote host closed the connection]
quimrstorres has joined #ruby
jpfuentes2 has joined #ruby
quimrstorres has quit [Remote host closed the connection]
sinkensabe has quit [Remote host closed the connection]
<[k->
ghc errors need much more work :/
hazelux has joined #ruby
dubkoidragon has joined #ruby
tmtwd has quit [Remote host closed the connection]
lordkryss has quit [Quit: Connection closed for inactivity]
DoubleMalt has joined #ruby
quimrstorres has joined #ruby
geefolk has joined #ruby
geefolk has quit [Max SendQ exceeded]
zz_barkerd427 is now known as barkerd427
hazelux has quit [Ping timeout: 244 seconds]
geefolk has joined #ruby
geefolk has quit [Max SendQ exceeded]
endash has joined #ruby
gamename has joined #ruby
quimrstorres has quit [Remote host closed the connection]
geefolk has joined #ruby
araujo has joined #ruby
araujo has joined #ruby
araujo has quit [Max SendQ exceeded]
geefolk has quit [Max SendQ exceeded]
tchebb has quit [Read error: Connection reset by peer]
tchebb has joined #ruby
yqt has joined #ruby
whiteline has joined #ruby
DEA7TH_ has quit [Quit: DEA7TH_]
newbie has joined #ruby
newbie is now known as Guest85195
paulcsmith has joined #ruby
paulcsmith has quit [Client Quit]
araujo has joined #ruby
barkerd427 is now known as zz_barkerd427
yqt has quit [Ping timeout: 244 seconds]
desigx has joined #ruby
geefolk has joined #ruby
yqt has joined #ruby
Guest85195 has quit [Ping timeout: 264 seconds]
stantonnet has joined #ruby
timonv has joined #ruby
FernandoBasso has quit [Ping timeout: 256 seconds]
dimasg has joined #ruby
tkuchiki has quit [Remote host closed the connection]
zz_barkerd427 is now known as barkerd427
Casty has joined #ruby
iateadonut has quit [Quit: Leaving.]
bruno- has quit [Ping timeout: 240 seconds]
jbw has joined #ruby
j4cknewt has joined #ruby
weemsledeux has joined #ruby
tkuchiki has joined #ruby
j4cknewt has quit [Remote host closed the connection]
<shevy>
[k- are you getting unhappy with haskell and will you return to ruby?
lorikeet has joined #ruby
<[k->
no
<JimmytheHat>
is there a way to dump all information a ruby object to a file? All information, all of its methods, its object ID, its value just everything. Basically | a === b #=> true | but if I use b over a the method fails, even though === returns true xD. I know some of you will kindly look at my code but I'd rather if someone would tell me how to debug this instead. I mean if === #=> true there must be some other difference, right?
<shevy>
JimmytheHat Marshall should work
<shevy>
Marshal.dump(object)
<JimmytheHat>
shevy thanks!
<[k->
object.inspect?
<shevy>
there may be a few things it can not store, I think singletons or something like that. I forgot what it was
<JimmytheHat>
[k- I am indeed confused :P what does === mean? and how do I do a strict equals AND find the difference? Because if the difference is object_id I don't care about that because they definitely will have differening object ids. I want all differences apart from object id.
<JimmytheHat>
shevy I'll try YAML, you can dump with it ;)
<jhass>
yes, if I create the version.rb i run into missing gw-mq (not on rubygems.org?)
<cmouse>
jhass: yes, a private gem
<cmouse>
sorry about that
<jhass>
so maybe your command simply has no output?
jpfuentes2 has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
benlovell has joined #ruby
<cmouse>
jhass: could be
sinkensabe has joined #ruby
<[k->
Mon_Ouie I think Ox0dea investigated this
<Mon_Ouie>
Investigated what?
<cmouse>
jhass: ohwell, thanks
<cmouse>
i go bang by head further
rubie has quit [Remote host closed the connection]
<[k->
duping of NilClass I think
dubkoidragon has quit [Ping timeout: 260 seconds]
<Mon_Ouie>
You can't do it because 1) it's hardcoded to not let
<Mon_Ouie>
to net let you do that*
<Mon_Ouie>
And also partly because nil, false and true have fixed object ids
zz_barkerd427 is now known as barkerd427
<Mon_Ouie>
And if you removed the code that stops you from creating other instances of FalseClass, if FalseClass.new then … end would still run
<cmouse>
*sigh*
dimasg has joined #ruby
<cmouse>
sorry for the noise, it was my fault completely.
<[k->
100% what I said
benlovell has quit [Ping timeout: 260 seconds]
fabrice31 has joined #ruby
t0rrieri has joined #ruby
yeticry has quit [Quit: leaving]
therealfibonacci has joined #ruby
<[k->
I always feel that somehow people don't really listen to my suggestions
lokulin has quit [Ping timeout: 256 seconds]
<[k->
is it because my nick is stupid?
casadei_ has joined #ruby
last_staff has quit [Ping timeout: 240 seconds]
gheegh has joined #ruby
jud^ has joined #ruby
<cmouse>
[k-: no.
<cmouse>
why are you guys so aggressive btw?
hazelux has joined #ruby
jud^ has quit [Read error: Connection reset by peer]
<[k->
I think it is my nature :o
<cmouse>
i see.
<cmouse>
well, thank you for your help anyways
<[k->
jhass is probably worn out :s
fabrice31 has quit [Ping timeout: 252 seconds]
joneshf-laptop has quit [Ping timeout: 248 seconds]
cmouse has left #ruby [#ruby]
veduardo has joined #ruby
<shevy>
he is getting older and older
<jhass>
I simply have no reason to be easy if the other party doesn't make it easy to help them
<shevy>
ohhh cmouse is from finland
casadei_ has quit [Ping timeout: 250 seconds]
radialneon has quit [Remote host closed the connection]
<[k->
not everyone comes equipped with a know-how, ya'know
hazelux has quit [Ping timeout: 240 seconds]
miwood has joined #ruby
lokulin has joined #ruby
DLSteve has joined #ruby
miwood has quit [Remote host closed the connection]
<jhass>
everyone can make an effort to share as much as possible about their problem. They only shared as little as possible
dimasg has quit [Ping timeout: 264 seconds]
<[k->
that's human nature :s
veduardo has quit [Quit: WeeChat 0.4.2]
statu has joined #ruby
veduardo has joined #ruby
<statu>
hi!
<jhass>
hi
djbkd_ has joined #ruby
jamesaxl has joined #ruby
<[k->
an investment from jhass, how rare :3
<havenwood>
[k-: huh?
<havenwood>
statu: g'mornin
<[k->
ask jhass :3
revath has joined #ruby
<statu>
I am developing my first Ruby library. I want to validate an email and I thought that it should exist a gem that already does that. The problem is that the gem that I have found (https://rubygems.org/gems/email_validation) is related with ActiveModel::EachValidator, and I don't know if that class belongs to the Ruby library or to the Ruby On Rails one.
<jhass>
that's intended for rails, yes
t0rrieri has quit [Quit: Be back later ...]
iooner has quit [Ping timeout: 244 seconds]
<statu>
jhass: ok, thanks!
<jhass>
you probably should search further or just give up on proper email validation and take everything that contains an @ :P
<statu>
jhass: jaja I will search further :)
iooner has joined #ruby
<jhass>
I'm actually fairly serious about it
<statu>
I am searching in https://rubygems.org/, is that the correct place, isn't it?
<havenwood>
statu: you're welcome! let us know about your gem when you ship it. :)
miwood has joined #ruby
ndrei has quit [Ping timeout: 240 seconds]
cajone has left #ruby [#ruby]
mary5030 has quit [Remote host closed the connection]
<havenwood>
statu: ah, I guess you said library and I assumed gem. either way, happy coding!
<statu>
havenwood: thanks!
mary5030 has joined #ruby
atomical has joined #ruby
chinmay_dd has joined #ruby
gix has quit [Ping timeout: 244 seconds]
ZYPP is now known as hool
suffice has quit [Ping timeout: 244 seconds]
whiteline has quit [Ping timeout: 246 seconds]
suffice has joined #ruby
brixen has joined #ruby
mary5030 has quit [Ping timeout: 248 seconds]
<JimmytheHat>
in Ruby can I do |attr_accessor :array, []| ? I want to initialize an attribute with a value. Is there a gem that will allow me to do this?
<JimmytheHat>
jhass I can then call aninstance.array ?
<jhass>
with an attr_reader :array or attr_accessor :array, sure
rubie has joined #ruby
<JimmytheHat>
jhass ah I see.. thought it would be cool to set attr_accessor with an initial variable in one. thanks, i'll stick with initialize then :)
AviShastry has joined #ruby
jaygen_ has quit [Ping timeout: 264 seconds]
t0rrieri has joined #ruby
AviShastry has left #ruby [#ruby]
OrbitalK_ has joined #ruby
bnizzle has joined #ruby
dopie has joined #ruby
OrbitalKitten has quit [Read error: Connection reset by peer]
bnizzle1 has quit [Ping timeout: 248 seconds]
therealfibonacci has quit [Quit: Leaving.]
whiteline has joined #ruby
Pupeno has quit [Remote host closed the connection]
bnizzle has quit [Ping timeout: 260 seconds]
whiteline has quit [Max SendQ exceeded]
chinmay_dd has quit [Quit: Leaving]
bnizzle has joined #ruby
whiteline has joined #ruby
joneshf-laptop has joined #ruby
whiteline has quit [Max SendQ exceeded]
<lorikeet>
anyone have any starting points for ruby? i'm sort of completely knew to code, with the exception of tutoring logic and taking one C class
<jhass>
Chris Pine's Learn to program is generally recommended
<lorikeet>
i couldn't find any decent podcasts which would help my immersion
<jhass>
I don't like LRTHW's code style
<lorikeet>
thanks for the link!
stantonnet has quit [Ping timeout: 244 seconds]
flori has quit [Ping timeout: 244 seconds]
flori has joined #ruby
Averna has joined #ruby
whiteline has joined #ruby
bruno- has quit [Ping timeout: 246 seconds]
Violentr has quit [Ping timeout: 244 seconds]
krz has joined #ruby
htmldrum has joined #ruby
dfockler has joined #ruby
ndrei has joined #ruby
jhack32 has joined #ruby
FernandoBasso has quit [Quit: May the force be with you.]
desigx has joined #ruby
dimasg has joined #ruby
dfockler has quit [Ping timeout: 256 seconds]
htmldrum has quit [Ping timeout: 255 seconds]
charliesome has joined #ruby
htmldrum has joined #ruby
Unicorn_ has joined #ruby
hfp_work has quit [Ping timeout: 244 seconds]
Unicorn_ is now known as Unicorn|
<Unicorn|>
Can I ask for help with ruby>
<Unicorn|>
*?
hfp has quit [Ping timeout: 264 seconds]
dopie has quit [Quit: This computer has gone to sleep]
Channel6 has joined #ruby
<jhass>
?ask Unicorn|
<ruboto>
Unicorn|, Don't ask to ask. Just ask your question, and if anybody can help, they will likely try to do so.
<Unicorn|>
yay!
al2o3-cr has quit [Quit: WeeChat 1.2]
<Unicorn|>
I'm a total beginner, but, How can I store the number generated by rand(50) to a variable?
<jhass>
foo = rand(50)
<shevy>
var = rand(50)
<jhass>
called assignment
<Unicorn|>
ah, thanks.
<shevy>
\o/
al2o3-cr has joined #ruby
<shevy>
Chris Pine's tutorial is nice, I'd wish we could extend and update it but it's quite a lot of work
benlovell has joined #ruby
NeverDie has quit [Quit: I'm off to sleep. ZZZzzz…]
dimasg has quit [Ping timeout: 240 seconds]
woodruffw has quit [Remote host closed the connection]
Agoldfish has joined #ruby
woodruffw has joined #ruby
desigx has quit [Ping timeout: 248 seconds]
blue_deref has joined #ruby
<krz>
foo_bar = 'a'; whats another way of doing eval('foo_bar')
<jhass>
krz: you most likely want a hash
Averna has left #ruby [#ruby]
Averna has joined #ruby
jeramyRR has joined #ruby
<krz>
jhass: im trying to excute the 'foo_bar' string
<krz>
so it returns 'a'
<shevy>
krz I think there is no easy way to generate local variables. if it would be an @instance_variable then it would be simple, you have object.instance_variable_set(:@a, 'dog') # => 'dog'
<jhass>
and I'm saying that's a really bad idea and a sign that you use the wrong datastructure
benlovell has quit [Ping timeout: 246 seconds]
symm- has quit [Ping timeout: 240 seconds]
yeticry has joined #ruby
acke has joined #ruby
<krz>
kk
_kfpratt has joined #ruby
kfpratt has quit [Read error: No route to host]
endash has quit [Quit: endash]
sinkensabe has quit [Remote host closed the connection]
htmldrum has quit [Ping timeout: 265 seconds]
nfk has quit [Remote host closed the connection]
noethics has joined #ruby
mary5030 has joined #ruby
htmldrum has joined #ruby
nfk has joined #ruby
penzur has joined #ruby
mary5030 has quit [Remote host closed the connection]
mary5030 has joined #ruby
davedev24 has quit [Remote host closed the connection]
jhack32 has quit [Remote host closed the connection]
lkba has joined #ruby
_kfpratt has quit [Remote host closed the connection]
davedev24 has joined #ruby
dopie has joined #ruby
mary5030 has quit [Ping timeout: 246 seconds]
OrbitalK_ has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<krz>
depending on the value of the argument action_name. execute the right method
<krz>
in this case index_filters
relix has joined #ruby
bronson has joined #ruby
maletor has quit [Quit: Computer has gone to sleep.]
<krz>
jhass: any alternative approach to executing that logic?
<jhass>
public_send
<jhass>
but doing that from user input is still dangerous
hj2007 has quit [Quit: This computer has gone to sleep]
<jhass>
I'd at least also do some sanity check prior, like filter_method = "#{action_name}_filters"; raise ... unless methods(false).grep(/_filters$/).include? filter_method; public_send(filter_method)
<jhass>
something in that way
workmad3 has joined #ruby
hj2007 has joined #ruby
tno has joined #ruby
dagda1 has quit [Ping timeout: 244 seconds]
dagda1 has joined #ruby
<krz>
jhass: you mean something like public_send("#{action_name}_filters")
<jhass>
...
<jhass>
I just wrote what I mean exactly?!
<krz>
oh whops
<krz>
sorry misread
nfk has quit [Remote host closed the connection]
sphex_ has quit [Ping timeout: 264 seconds]
chinmay_dd has quit [Quit: Leaving]
jhack32 has joined #ruby
maletor has joined #ruby
vdamewood has joined #ruby
<krz>
thanks jhass
ndrei has quit [Ping timeout: 246 seconds]
workmad3 has quit [Ping timeout: 248 seconds]
hfp has joined #ruby
ndrei has joined #ruby
hfp_work has joined #ruby
peter_paule has joined #ruby
workmad3 has joined #ruby
sphex has joined #ruby
nfk has joined #ruby
hj2007 has quit [Quit: This computer has gone to sleep]
Averna has quit [Ping timeout: 264 seconds]
hj2007 has joined #ruby
geefolk has quit [Ping timeout: 248 seconds]
hj2007 has quit [Client Quit]
OrbitalKitten has joined #ruby
Channel6 has quit [Quit: Leaving]
sinkensabe has joined #ruby
Averna has joined #ruby
drewvanstone has joined #ruby
peter_paule has quit [Ping timeout: 252 seconds]
casadei_ has joined #ruby
OrbitalKitten has quit [Read error: Connection reset by peer]
relix has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
OrbitalKitten has joined #ruby
m8 has quit [Quit: Sto andando via]
jeramyRR has quit [Quit: Peace out!]
zr2d2 has quit [Ping timeout: 248 seconds]
hj2007 has joined #ruby
noname has quit [Quit: WeeChat 1.0.1]
idiocrash has quit [Remote host closed the connection]
dellavg has quit [Quit: Ex-Chat]
casadei_ has quit [Ping timeout: 244 seconds]
hj2007 has quit [Client Quit]
workmad3 has quit [Ping timeout: 246 seconds]
victortyau has quit [Quit: Leaving]
OrbitalKitten has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
eggoez has quit [Ping timeout: 248 seconds]
devdazed has joined #ruby
Channel6 has joined #ruby
hashrocket has quit [Quit: Connection closed for inactivity]
fabrice31 has joined #ruby
gambl0re has quit [Ping timeout: 260 seconds]
devdazed has quit [Client Quit]
eggoez has joined #ruby
zr2d2 has joined #ruby
fabrice31 has quit [Ping timeout: 256 seconds]
kawaii-imouto has quit [Quit: reboot]
dimasg has joined #ruby
weemsledeux has joined #ruby
Agoldfish has quit [Quit: G'Bye]
weemsledeux has quit [Max SendQ exceeded]
hashrocket has joined #ruby
dimasg has quit [Ping timeout: 246 seconds]
tkuchiki has quit [Remote host closed the connection]
tkuchiki has joined #ruby
hj2007 has joined #ruby
JimmytheHat has quit [Ping timeout: 260 seconds]
yqt has joined #ruby
spider-mario has quit [Ping timeout: 265 seconds]
tkuchiki has quit [Ping timeout: 248 seconds]
hj2007 has quit [Ping timeout: 240 seconds]
maletor has quit [Ping timeout: 264 seconds]
pyon has joined #ruby
toretore has joined #ruby
mleung has joined #ruby
Averna has left #ruby [#ruby]
mikeric has joined #ruby
benlovell has joined #ruby
TheHodge has joined #ruby
mleung has quit [Quit: mleung]
yqt has quit [Ping timeout: 248 seconds]
ndrei has quit [Remote host closed the connection]
DoubleMalt has quit [Remote host closed the connection]
benlovell has quit [Ping timeout: 256 seconds]
FenrirReturns has joined #ruby
fantazo has quit [Quit: Verlassend]
ndrei has joined #ruby
konsolebox has joined #ruby
Arpho has joined #ruby
Channel6 has quit [Quit: Leaving]
crdpink2 has joined #ruby
crdpink has quit [Ping timeout: 248 seconds]
<shevy>
it's so hot
chamila has joined #ruby
dopie has quit [Quit: This computer has gone to sleep]
mikeric has quit []
<chamila>
Hi all, what happens in this line in a ruby C extension? "VALUE cls = rb_cObject"?
spider-mario has joined #ruby
workmad3 has joined #ruby
<shevy>
I assume this creates a new object instance?
<shevy>
hmm
<shevy>
my examples have foo = rb_define_class("NameOfClassHere", rb_cObject);
<chamila>
so equals to "cls = new Object()" in java?
<Ox0dea>
chamila: `cls = rb_cObject` does not create a new object.
<jhass>
chamila: Object is an object too in Ruby, an instance of class. My guess is that it assigns that object as the value for cls
<Ox0dea>
Well, no, I suppose you'd want a second reference if you were doing traversal or something.
mike___1234 has quit [Ping timeout: 256 seconds]
hfp has quit [Ping timeout: 244 seconds]
<chamila>
0x0dea: sorry I don't get you
hfp_work has quit [Ping timeout: 240 seconds]
<chamila>
can u explain little bit more
hfp has joined #ruby
weemsledeux has joined #ruby
hfp_work has joined #ruby
sankaber has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
zacstewart has joined #ruby
yuuvee has joined #ruby
allcentury has joined #ruby
<Ox0dea>
Oj needs to determine if some string ("Foo::Bar::Baz", for instance) represents an actual class. It does that by starting at Object and using #const_get on the '::'-delimited pieces of the string until it fails or reaches the end.
Igorshp has joined #ruby
<Ox0dea>
chamila: `clas = rb_cObject` is the "starting point", the top of the tree from which to being searching.
<Ox0dea>
But yes, "new-school" RS is also still reasonably active.
<zacts>
did they opensource the old runescape engine?
wookiehangover has joined #ruby
<Ox0dea>
No idea.
<Ox0dea>
shevy: Why do you add non-existent homepages to all of your gems? :/
<zacts>
anyway, /me tries to mine rubies on runescape
<zacts>
but yeah... /me idles now
veduardo has quit [Ping timeout: 256 seconds]
benlovell has joined #ruby
martinbjeldbak has joined #ruby
Leef_ has joined #ruby
Leef_ has quit [Remote host closed the connection]
Pupeno has quit [Remote host closed the connection]
davedev24 has quit [Ping timeout: 240 seconds]
malconis has joined #ruby
davedev24 has joined #ruby
benlovell has quit [Ping timeout: 252 seconds]
GnuYawk has quit [Ping timeout: 246 seconds]
desigx has quit [Ping timeout: 248 seconds]
orbitalo has quit [Remote host closed the connection]
Rickmasta has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
towski_ has quit [Remote host closed the connection]
symm- has quit [Ping timeout: 246 seconds]
orbitalo has joined #ruby
OrbitalKitten has quit [Read error: Connection reset by peer]
OrbitalKitten has joined #ruby
user1138 has joined #ruby
yfeldblum has joined #ruby
veduardo has joined #ruby
peter_paule has joined #ruby
<user1138>
What is the best resource to begin learning RoR with no prior programming knowledge?
OrbitalKitten has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
MagePsycho has joined #ruby
GnuYawk has joined #ruby
<Ox0dea>
user1138: That's probably not a good idea.
hanmac has quit [Ping timeout: 246 seconds]
<user1138>
RoR was suppose to be the easiest programming language to learn back in 2011
zacstewart has quit [Remote host closed the connection]
<Ox0dea>
user1138: RoR is not a programming language.
casadei_ has joined #ruby
<user1138>
an application frame work?
<Ox0dea>
A Web application framework, yes.
<shevy>
Ox0dea ah no, these are skeletons, they'll be re-added the moment I will finish on my script to automatically create them if they are not yet existing
OrbitalKitten has joined #ruby
workmad3 has quit [Ping timeout: 256 seconds]
phutchins has quit [Ping timeout: 264 seconds]
casadei_ has quit [Ping timeout: 250 seconds]
Aswebb_ has joined #ruby
veduardo has quit [Ping timeout: 260 seconds]
<Ox0dea>
user1138: You'll want to at least vaguely familiarize yourself with programming before jumping into creating a Web app, lest you find yourself copy-pasting like a zombie and not really learning anything.
<Ox0dea>
shevy: You're creating a repository generator?
<shevy>
Ox0dea well, mostly they can happen in a git repo, and then remain on github. but somehow it was of very low priority to me so far... I don't even write a lot of documentation at all. :\ :/ sooner or later things will become better, step by step
<Zinja>
user1138: RoR in amazing but it have an incredibly steep learning curve in the beginning since most people are not used to the MVC system. I would not recommend it for someone who doesn't already have a firm understanding of Ruby.
Kalov has quit [Ping timeout: 244 seconds]
<user1138>
So RoR is a web application framework and Ruby is the programming language?
<jhack32>
user1138: check out theodinproject
gizmore has joined #ruby
gizmore has quit [Client Quit]
SparkySparkyBoom has joined #ruby
jenrzzz has quit [Ping timeout: 240 seconds]
Aswebb_ has quit [Ping timeout: 255 seconds]
Jackneill has quit [Remote host closed the connection]
SparkySparkyBoom has left #ruby ["WeeChat 1.2-dev"]
jenrzzz has joined #ruby
<Zinja>
user1138: Yes. Learn Ruby first, it's very difficult to learn Ruby and Rails at the same time.
swgillespie has joined #ruby
hanmac has joined #ruby
Alina-malina has quit [Ping timeout: 256 seconds]
dseitz has joined #ruby
gizmore has joined #ruby
MagePsycho has quit [Ping timeout: 240 seconds]
sarkyniin has joined #ruby
psy_ has quit [Read error: Connection reset by peer]
_solomon has joined #ruby
gambl0re has quit [Ping timeout: 256 seconds]
NeverDie has joined #ruby
swgillespie has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
_solomon has quit [Client Quit]
yfeldblu_ has joined #ruby
psy_ has joined #ruby
havenwood has joined #ruby
gizmore has quit [Client Quit]
psy_ has quit [Max SendQ exceeded]
swgillespie has joined #ruby
Pupeno has joined #ruby
psy_ has joined #ruby
veduardo has joined #ruby
yfeldblum has quit [Ping timeout: 256 seconds]
blue_deref has quit [Quit: bbn]
ZYPP is now known as hool
drewvanstone has joined #ruby
Agoldfish has joined #ruby
framling has joined #ruby
<shevy>
\o/
ruurd has joined #ruby
htmldrum has joined #ruby
veduardo has quit [Ping timeout: 248 seconds]
Pupeno has quit [Remote host closed the connection]
tubuliferous_ has quit [Ping timeout: 256 seconds]
sinkensabe has joined #ruby
htmldrum has quit [Ping timeout: 250 seconds]
htmldrum has joined #ruby
bruno- has quit [Ping timeout: 246 seconds]
fabrice31 has joined #ruby
El3ktra has quit [Ping timeout: 265 seconds]
OrbitalKitten has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
OrbitalKitten has joined #ruby
xkickflip has quit [Ping timeout: 260 seconds]
desigx has joined #ruby
xkickflip_ has joined #ruby
peter_paule has quit [Ping timeout: 248 seconds]
htmldrum has quit [Ping timeout: 264 seconds]
fabrice31 has quit [Ping timeout: 244 seconds]
El3ktra has joined #ruby
El3ktra has joined #ruby
ruurd has quit [Read error: Connection reset by peer]
s00pcan has quit [Ping timeout: 246 seconds]
rubie has quit [Read error: Connection reset by peer]
rubie has joined #ruby
j4cknewt has joined #ruby
hool is now known as ZYPP
s00pcan has joined #ruby
njection has joined #ruby
veduardo has joined #ruby
arup_r has quit [Quit: Leaving]
radialneon has joined #ruby
dfockler has joined #ruby
miwood has joined #ruby
galeido has quit [Read error: Connection reset by peer]
mrbeardy has joined #ruby
max has joined #ruby
max is now known as Guest78047
vickleton has joined #ruby
dfockler has quit [Ping timeout: 265 seconds]
veduardo has quit [Ping timeout: 246 seconds]
<pontiki>
hihi o/
SCHAAP137 has quit [Remote host closed the connection]
dotix has quit [Quit: Leaving]
jhack32 has quit [Ping timeout: 256 seconds]
tomdp has quit [Ping timeout: 256 seconds]
myam has joined #ruby
aryaching has quit [Ping timeout: 250 seconds]
jackjackdripper has joined #ruby
jackjackdripper has quit [Client Quit]
tekk has joined #ruby
zacstewart has joined #ruby
myam has quit [Quit: Leaving...]
endash has quit [Quit: endash]
rubie has quit [Remote host closed the connection]
<shevy>
it's a pontiki on a caturday! \o/
s00pcan has quit [Ping timeout: 240 seconds]
jamesaxl|2 has joined #ruby
galeido has joined #ruby
s00pcan has joined #ruby
sinkensabe has quit [Remote host closed the connection]
jamesaxl has quit [Ping timeout: 246 seconds]
myam has joined #ruby
myam has quit []
OrbitalKitten has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
techietrash has quit [Quit: Bye! <(^_^<)]
centrx has joined #ruby
pengin has joined #ruby
LiquidInsect has quit [Remote host closed the connection]
<shevy>
ready to code a new ruby project
krz has quit [Quit: WeeChat 1.0.1]
maletor has joined #ruby
EllisTAA has quit [Quit: EllisTAA]
OrbitalKitten has joined #ruby
LiquidInsect has joined #ruby
user1138 has quit [Ping timeout: 246 seconds]
dh64 has quit [Ping timeout: 264 seconds]
nofxx has quit [Ping timeout: 244 seconds]
torpig has quit [Read error: Connection reset by peer]
EllisTAA has joined #ruby
Guest78047 has quit [Ping timeout: 244 seconds]
nofxx has joined #ruby
nofxx has quit [Changing host]
nofxx has joined #ruby
ruurd has joined #ruby
decoponio has quit [Read error: Connection reset by peer]
decoponio has joined #ruby
<pontiki>
i'm trying to get docker working with a project
EllisTAA has quit [Client Quit]
stantonnet has joined #ruby
pengin has quit [Remote host closed the connection]
Ilyas has quit [Read error: Connection reset by peer]
user1138 has joined #ruby
_ht has quit [Quit: Konversation terminated!]
mikecmpbll has quit [Quit: ciao.]
JoshL has joined #ruby
xkickflip_ has quit [Quit: xkickflip_]
spider-mario has quit [Remote host closed the connection]
noethics has joined #ruby
user1138 has quit [Max SendQ exceeded]
thang has quit [Ping timeout: 256 seconds]
ss_much has quit [Quit: Erm. Temp?]
user1138 has joined #ruby
ryba has joined #ruby
<Ox0dea>
shevy: GIMP with a TUI.
Muhannad has joined #ruby
drewvanstone has quit [Ping timeout: 248 seconds]
user1138 has quit [Max SendQ exceeded]
<shevy>
a TUI?
<Ox0dea>
Terminal user interface.
chouhoulis has quit [Remote host closed the connection]
user1138 has joined #ruby
<Ox0dea>
Modern terminal emulators let you specify 24-bit colors, but most are still limited to 256-color palettes.
<Ox0dea>
Still, that seems like plenty of breathing room.
<ruurd>
text ui
<Ox0dea>
No, terminal.
<ruurd>
text
<Ox0dea>
You can do much more with a terminal than just display text.
<ruurd>
with them newfangled graphical terminals?
sharpmachine has joined #ruby
EllisTAA has joined #ruby
<Ox0dea>
Well, sure, but that's not what I had in mind.
<Ox0dea>
Modern terminals can respond to mouse movement, clicks, drags.
<ruurd>
heretic
allomov has quit [Remote host closed the connection]
<Ox0dea>
"Modern" here refers to the likes of xterm and rxvt, for what that's worth.
<ElSif>
i am embrace heresy, middle clicking a path in iterm2 and having it open directly in sublime text is cool
CloCkWeRX has joined #ruby
stantonnet has quit [Ping timeout: 265 seconds]
sarkyniin has quit [Ping timeout: 246 seconds]
<ElSif>
well, if you use the 'mighty mouse' thing i thin its command click...
thang has joined #ruby
sivoais has quit [Ping timeout: 244 seconds]
zacstewart has quit [Remote host closed the connection]
miwood has quit [Remote host closed the connection]
framling has quit [Read error: Connection reset by peer]
miwood has joined #ruby
pdxvegan has joined #ruby
Pupeno has joined #ruby
Pupeno has quit [Remote host closed the connection]
tubuliferous_ has joined #ruby
miwood_ has joined #ruby
DLSteve has quit [Quit: Leaving]
bronson has joined #ruby
miwood has quit [Ping timeout: 246 seconds]
j4cknewt has quit [Remote host closed the connection]
duncannz has joined #ruby
Kalov has joined #ruby
OrbitalKitten has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
tubuliferous_ has quit [Ping timeout: 248 seconds]
<shevy>
hmm
<shevy>
I want to do that too on linux!
bronson has quit [Ping timeout: 250 seconds]
sivoais has joined #ruby
stantonnet has joined #ruby
Aswebb_ has joined #ruby
endash has joined #ruby
torpig has joined #ruby
<ruurd>
Or use popclip to do all manner of funky stuff...
sharpmachine has quit [Remote host closed the connection]
Pupeno has joined #ruby
Pupeno has quit [Changing host]
Pupeno has joined #ruby
sharpmachine has joined #ruby
_ixti_ has quit [Ping timeout: 264 seconds]
Aswebb_ has quit [Ping timeout: 240 seconds]
sarkyniin has joined #ruby
kjones_ has joined #ruby
miwood_ has quit [Remote host closed the connection]
Pupeno has quit [Remote host closed the connection]
Pupeno has joined #ruby
joneshf-laptop has quit [Remote host closed the connection]
joneshf-laptop has joined #ruby
EllisTAA has quit [Quit: EllisTAA]
codecop has quit [Remote host closed the connection]
rubie has joined #ruby
Pupeno has quit [Ping timeout: 256 seconds]
_ixti_ has joined #ruby
sharpmachine has quit [Remote host closed the connection]
sinkensabe has joined #ruby
sharpmachine has joined #ruby
EllisTAA has joined #ruby
Schalla has joined #ruby
Unicorn| has joined #ruby
<Schalla>
Good evening. I got a question which came up while working with rails and some other libs, but I was uncertain what its called. I often see that Ruby methods are suffixed by "?" or "!", why so? Does it have a special meaning and naming that I can read up on it?
dagda1 has joined #ruby
EllisTAA has quit [Client Quit]
<Ox0dea>
Schalla: ? methods are called "query methods" and should, by widespread convention, always explicitly return either true or false.
<Ox0dea>
! methods simply mean "be careful with this", but that often translates to "this method mutates the receiver".
sinkensabe has quit [Ping timeout: 246 seconds]
<Schalla>
Ox0dea, Ah, thanks for the explanation! Makes sense. :)
<Unicorn|>
Hi everyone! How can I let the use input a number in to a variable? It seems like gets.chomp lets the user input a string, but for a variable, how would I do that?