gusrub has quit [Read error: Connection reset by peer]
Salve has joined #ruby
Derperperd has quit [Quit: Derperperd]
RonRichie has joined #ruby
<RonRichie>
hey there! :) I've a question about Ruby, does Ruby by any chances offer capability such as listening to the browser actions? for instance... I want to setup an even listener(or something similar, whatever it is in Ruby) then whenever a new tab is opened in a browser I want the browser to perform this specific action, is this something that seems Ruby can do? thanks
Salve has quit [Ping timeout: 256 seconds]
cosmicera has joined #ruby
hahuang61 has joined #ruby
RonRichie is now known as WalterKing001
<WalterKing001>
anyone pls?
hightower2 has quit [Remote host closed the connection]
hahuang61 has quit [Ping timeout: 256 seconds]
<cosmicera>
I have a question about ruby as a main scripting language in Linux. I know that python 2.X is available in most distros by default, but my preference has become ruby. What are the best methods to ensure that I will be able to program in my language of choice?
<cosmicera>
I really haven't been able to find an answer to the question and I really don't know where to ask it.
<cosmicera>
So I came here.
hahuang61 has joined #ruby
<elomatreb>
cosmicera: If you want to use Ruby, you're probably going to have to get used to having to install it
<elomatreb>
I don't know any Linux distro that ships with it by default. OS X has a really old version, but that's it
<cosmicera>
I understand that. But is that an acceptable compromise?
<cosmicera>
The best thing to do is install the ruby installer?
<elomatreb>
Of course, if you like Ruby
<cosmicera>
And then go from there?
hightower2 has joined #ruby
<elomatreb>
On Linux, it depends on the distro. Debian-likes usually provide relatively old versions, so it can use very benefical to use dedicated tools for installing Ruby
<cosmicera>
Got it.
<elomatreb>
On the other hand, for example on Archlinux, you can generally use the regular ruby package
<havenwood>
elomatreb: latest OS X ships with 2.0.0
<havenwood>
cosmicera: Arch and Fedora have particularly nice Ruby packages, among other distros.
<cosmicera>
Hmm. I think I got it. So part of setting up a distro would be install tmux install ruby.
<havenwood>
cosmicera: ruby-install is nice to make things quick and light
Aquazi_ has quit [Read error: Connection reset by peer]
<havenwood>
cosmicera: `ruby-install --latest --system ruby` to install to /usr/local/ when you don't need a Ruby version switcher
railssmith has joined #ruby
<havenwood>
chruby is being adopted by a growing list of package managers for when you need to switch Rubies
<havenwood>
or yeah, rvm
optiz0r has quit [Ping timeout: 256 seconds]
<cosmicera>
havenwood: Sounds good. Thanks a lot for your help.
<pokalyis>
I've a ruby script in my $PATH named git-X. I'm getting "No manual entry for X", when trying to do "git X --help". "git-X --help" works. Any idea what the problem might be?
ixti has quit [Quit: WeeChat 1.6]
saneax is now known as saneax-_-|AFK
<pontiki>
the first looks like git is looking for it
<havenwood>
pokalyis: It'd be a good idea to use lowercase for you command name. Is the file executable? Is its shebang correct?
<pokalyis>
havenwood X was just an example. It's called something else
chouhoulis has joined #ruby
<havenwood>
pokalyis: looks like it's saying there's no manpage for it? dunno why
<pokalyis>
havenwood Yes, I can access the file using git-X
<pontiki>
git's subcommands are written as git-subcommand
<pokalyis>
pontiki Yes?
<pontiki>
so git doesn't know where to find you script's man page
<pokalyis>
pontiki I worked before and I've never had any man pages, which is strange. --help has always being passed directly to the script, but doesn't work for some reason
<pontiki>
as `git X` ?
<pokalyis>
pontiki Yes. 'git X --help'
<pokalyis>
It has been working since 2012
chouhoulis has quit [Ping timeout: 265 seconds]
<pontiki>
when's the last time it worked?
<pokalyis>
Some users said `git X --help` didn't work as of 2014, but I couldn't reproduce it until today
<pontiki>
so what's changed?
<pokalyis>
pontiki Last time I ran the script it was under a different user in OS X – so some bash/zsh config
<pontiki>
probably not a ruby issue?
<pokalyis>
It should be the same dot file repo tho
<doxterpepper>
Alright, I'm at a loss. There is some way to invoke and start a cucumber test from within ruby right? I've seen it done before but I don't know where, or I'm just crazy, probably the latter.
sylario has quit [Quit: Connection closed for inactivity]
Rodya_ has joined #ruby
DLSteve has quit [Quit: All rise, the honorable DLSteve has left the channel.]
<pokalyis>
pontiki Tried different versions back in 2015. Couldn't reproduce it
<pontiki>
doxterpepper: a step or a scenario?
<pontiki>
pokalyis: did your ruby change?
flashpoint9 has joined #ruby
<pokalyis>
pontiki No, same version. Tried a few more as well
<doxterpepper>
pontiki: I'm trying to do the same thing as running cucumber from the command line but from within ruby. Like create a cucumber object with the options that would be from the command line and then invoke some run method on that object. I think I've seen it done before but I just dont' remember how
<pontiki>
so still probably not ruby, pokalyis
roamingdog has quit [Remote host closed the connection]
xall has quit [Ping timeout: 252 seconds]
<pokalyis>
pontiki Nope. The --help param doesn't reach the script. Git is catching it before
solocshaw has joined #ruby
<pontiki>
doxterpepper: i'm sure there's a way; i haven't done that :/
<doxterpepper>
There seems to be no documentation on doing that
Rodya_ has quit [Remote host closed the connection]
Rodya_ has joined #ruby
solocshaw has quit [Ping timeout: 245 seconds]
ichkv has joined #ruby
koooge_ has joined #ruby
roamingdog has joined #ruby
Rodya_ has quit [Ping timeout: 245 seconds]
raeoks has joined #ruby
SteenJobs has quit [Quit: SteenJobs]
roamingdog has quit [Remote host closed the connection]
jhack has quit []
Dobler has joined #ruby
roflmyeggo has joined #ruby
harai has quit [Ping timeout: 250 seconds]
bmurt has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
roamingdog has joined #ruby
optiz0r has joined #ruby
dmtd has quit [Quit: Connection closed for inactivity]
sneakerhax has quit [Read error: Connection reset by peer]
modlin has quit [Ping timeout: 256 seconds]
raeoks has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
bmurt has joined #ruby
arescorpio has quit [Quit: Leaving.]
nuclearsandwich has quit [Read error: Connection reset by peer]
nuclearsandwich has joined #ruby
Felipe__ has joined #ruby
Dobler has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
jeyraof has joined #ruby
Felipe__ has quit [Client Quit]
nettoweb has joined #ruby
porfa has quit [Quit: porfa]
Jameser has joined #ruby
brendan- has quit [Quit: My iMac has gone to sleep. ZZZzzz…]
braincrash has quit [Quit: bye bye]
arashb has joined #ruby
nettoweb has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
y2mq37 has quit [Read error: Connection reset by peer]
braincrash has joined #ruby
AndrewIsHere has joined #ruby
ur5us has quit [Remote host closed the connection]
Felipe__ has joined #ruby
y2mq37 has joined #ruby
ur5us has joined #ruby
sneakerhax has joined #ruby
Channel6 has joined #ruby
arashb has quit [Ping timeout: 256 seconds]
sleepee has quit [Ping timeout: 256 seconds]
ur5us has quit [Ping timeout: 250 seconds]
bturker has joined #ruby
flashpoint9 has joined #ruby
gix has quit [Ping timeout: 250 seconds]
dviola has quit [Quit: WeeChat 1.6]
gix has joined #ruby
bturker has quit [Ping timeout: 256 seconds]
bmurt has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
harfangk has joined #ruby
flashpoint9 has quit [Ping timeout: 245 seconds]
l4v2 has quit [Quit: l4v2]
shayan_ has quit [Quit: shayan_]
nuclearsandwich has quit [Read error: Connection reset by peer]
roamingdog has quit [Remote host closed the connection]
nuclearsandwich has joined #ruby
brendan- has joined #ruby
roflmyeggo has quit [Ping timeout: 252 seconds]
<WalterKing001>
hey there! :) I've a question about Ruby, does Ruby by any chances offer capability such as listening to the browser actions? for instance... I want to setup an even listener(or something similar, whatever it is in Ruby) then whenever a new tab is opened in a browser I want the browser to perform this specific action, is this something that seems Ruby can do? thanks
<elomatreb>
WalterKing001: You'll probably need a browser extension for that
roflmyeggo has joined #ruby
<WalterKing001>
elomatreb that would do it, just not suitable in our case, Google doesn't like our app and it think it violates their store privacy etc etc... it is pretty much going to operate as an extension but it can not be one, it should be native-level executable file or local server
TomyLobo has quit [Ping timeout: 260 seconds]
AndrewIsHere has quit [Remote host closed the connection]
bmurt has joined #ruby
<elomatreb>
WalterKing001: You can write browser extension without uploading them to the store. But If Google doesn't like them, there is probably a reason
hrodrig has joined #ruby
<hrodrig>
hola
<hrodrig>
alguien conoce de mongoid?
<WalterKing001>
elomatreb tried that as well, google automatically disables any extension that doesn't exist in in extension store, so even if you write your own one you can't have it up and running in your own browser, once you close the browser Chrome automatically disables it in an attempt to protect a user etc etc... well, they do have a reason but that doesn't also mean they're right, it's just what they are offering and it doesn't work with
<WalterKing001>
us, having a reason doesn't say much, but do you think Ruby can help us in this situation in any way ?
roflmyeggo has quit [Remote host closed the connection]
Felipe__ has quit [Quit: Leaving]
roflmyeggo has joined #ruby
tdy1 has joined #ruby
<elomatreb>
WalterKing001: I don't think so. Modern browsers are designed to resist other programs meddling with them as much as possible
<hrodrig>
mongoid?
<elomatreb>
hrodrig: It may help if you ask in English
<hrodrig>
hi... I need to parse external json file and insert values in mongoid.yml
<WalterKing001>
elomatreb gotcha gotcha, I know it's totally doable in C/C++ but one should know it very well to be able to pull something like that, so that's just out of my range as well, anyways, thanks for the heads up and thanks for answering my questions :)
<hrodrig>
but these values not are being parsed...
<hrodrig>
some like this: database: <%= MONGOID_JSON["database"] %>
<hrodrig>
I'm making the same with database.yml and these inserted values are being parsed...
<hrodrig>
I think that it's something with mongoid and the way to load yaml files...
tyang has quit [Read error: Connection reset by peer]
brendan- has quit [Quit: My iMac has gone to sleep. ZZZzzz…]
<hrodrig>
in google nothing about this fact.... :(
harushimo has quit [Quit: This computer has gone to sleep]
aaaaa has joined #ruby
Channel6 has quit [Quit: Leaving]
harushimo has joined #ruby
<aaaaa>
Does Ruby support string formatters?
<adam12>
aaaaa: like sprintf in C?
<gizmore>
Ruby has own neat syntaxes iirc
Dohplay has quit [Read error: Connection reset by peer]
<aaaaa>
%s
<gizmore>
"#{rubycodehere}" is my fav
<bougyman>
format()
harushimo has quit [Quit: This computer has gone to sleep]
insanedreamer has quit [Quit: insanedreamer]
xall has joined #ruby
<elomatreb>
There is also ERB in the standard library, which is basically a full templating engine. Useful when sprintf and string interpolation become unwieldy
jaiks1 has quit [Ping timeout: 258 seconds]
ichkv has quit [Ping timeout: 265 seconds]
roflmyeggo has quit [Ping timeout: 260 seconds]
agent_white has quit [Read error: Connection reset by peer]
roflmyeggo has joined #ruby
hakunin_ has joined #ruby
hakunin has quit [Read error: Connection reset by peer]
davidt_ has joined #ruby
hakunin_ has quit [Read error: Connection reset by peer]
hakunin has joined #ruby
davidt has quit [Ping timeout: 245 seconds]
agent_white has joined #ruby
boombox_ has quit [Remote host closed the connection]
bturker has joined #ruby
boombox_ has joined #ruby
futilegames has joined #ruby
roflmyeggo has quit [Ping timeout: 252 seconds]
jaiks1 has joined #ruby
futilegames has left #ruby [#ruby]
flashpoint9 has joined #ruby
boombox_ has quit [Remote host closed the connection]
roflmyeggo has joined #ruby
ElCapitanMarklar has joined #ruby
bturker has quit [Ping timeout: 256 seconds]
fullofcaffeine has quit [Remote host closed the connection]
flashpoint9 has quit [Ping timeout: 256 seconds]
fullofcaffeine has joined #ruby
fullofcaffeine has quit [Read error: Connection reset by peer]
fullofcaffeine has joined #ruby
gusrub has joined #ruby
conta has joined #ruby
fullofcaffeine has quit [Read error: Connection reset by peer]
exchgr has quit [Ping timeout: 250 seconds]
futilegames has joined #ruby
be_______ has joined #ruby
ben_____ has quit [Ping timeout: 256 seconds]
conta has quit [Ping timeout: 260 seconds]
anisha has joined #ruby
futilegames_ has joined #ruby
hays has quit [Read error: Connection reset by peer]
<Papierkorb>
arne: The underlying C function is popen(), whose docs if interested you can read through: man popen
<optiz0r>
having php without apache probably isn't possible for us to provide. Just because apache's installed, doesn't mean you have to run the service, it's just a bit of extra disk utilisation (and disk is cheap)
zzzdemo has joined #ruby
<optiz0r>
damn touchpadfail, sorry
<arne>
iehh php
claudiuinberlin has quit [Ping timeout: 260 seconds]
<Papierkorb>
Apache? PHP? I'm sorry you have to go through that
chouhoulis has joined #ruby
<optiz0r>
fortunately not actually me, someone was asking about OS packages and i was just answering from the package management perspective :)
theRoUS has quit [Remote host closed the connection]
<KiderSpiel>
Maybe someone here is knowledgeable of this, having troublewith paged results
rajdesai has joined #ruby
senayar has quit []
flashpoi_ has quit [Remote host closed the connection]
nettoweb has quit [Ping timeout: 250 seconds]
nowhere_man has quit [Ping timeout: 260 seconds]
bkxd has joined #ruby
Burgestrand has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
anjana has quit [Remote host closed the connection]
bluOxigen has quit [Read error: Connection reset by peer]
meaggan[m] has joined #ruby
nettoweb has joined #ruby
ziarkaen has quit [Ping timeout: 256 seconds]
sepp2k has joined #ruby
bluOxigen has joined #ruby
tvw has quit []
harushimo has joined #ruby
Bloomer has joined #ruby
johnmilton has quit [Remote host closed the connection]
Bloomer has quit [Ping timeout: 260 seconds]
ldnunes has quit [Quit: Leaving]
AlexRussia has joined #ruby
<arne>
Papierkorb: thank you
ace05_ has joined #ruby
ace05 has quit [Read error: Connection reset by peer]
ldnunes has joined #ruby
rue has joined #ruby
lenwood has quit [Ping timeout: 252 seconds]
bkxd has quit [Ping timeout: 260 seconds]
harushimo has quit [Quit: Leaving]
chouhoulis has quit [Remote host closed the connection]
SesMan has joined #ruby
pandaant has quit [Remote host closed the connection]
neminis has joined #ruby
<neminis>
hi! is there in ruby an array method which returns the object validating a condition?
gnufied has quit [Quit: Leaving]
<neminis>
because any? returns a boolean according to the given block but how to get the actual object?
Burgestrand has joined #ruby
<neminis>
'select' seems right
<rue>
Mheh, I am restored to my glory
Silthias1 has quit [Quit: Leaving.]
<dminuoso_>
neminis: select indeed.
brendan- has joined #ruby
Silthias has joined #ruby
<dminuoso_>
neminis: Note that this is from Enumerable in general. Look at it, and learn it - you will use many of those frequently
mim1k|wo1k has joined #ruby
porfa has quit [Quit: porfa]
anisha has quit [Quit: This computer has gone to sleep]
<neminis>
dminuoso_: yes, thanks !
mim1k|work has quit [Ping timeout: 260 seconds]
Bloomer has joined #ruby
Bloomer has quit [Remote host closed the connection]
nadir has joined #ruby
<hanmac>
neminis: check also #find if you only want one element
tyang has joined #ruby
synthroid has joined #ruby
Jameser has joined #ruby
johnmilton has joined #ruby
<neminis>
hanmac: okay, is it more efficient? in that case, it will always be one element anyway
anjana has joined #ruby
<hanmac>
if you know you only want one element, use find because it doesnt check the other elements if it find one
<neminis>
yes it is better
synthroi_ has joined #ruby
prawnzy has joined #ruby
synthroi_ has quit [Remote host closed the connection]
blaxter has joined #ruby
shayan_ has joined #ruby
tjbiddle has quit [Quit: tjbiddle]
synthroid has quit [Ping timeout: 245 seconds]
Jameser has quit [Max SendQ exceeded]
prawnzy has quit [Ping timeout: 250 seconds]
Jameser has joined #ruby
shayan_ has quit [Ping timeout: 265 seconds]
ldnunes has quit [Quit: Leaving]
ftj has joined #ruby
tjbiddle has joined #ruby
meinside has quit [Quit: Connection closed for inactivity]
<jokke>
hey
ftj has quit [Read error: Connection reset by peer]
al2o3-cr has quit [Ping timeout: 260 seconds]
<jokke>
is there a way to do something like this: 5.times.reduce(something, :method_on_something) without reduce passing the items from the collection it's reducing to the method?
rodfersou is now known as rodfersou|afk
wugy has quit []
<dminuoso_>
jokke: What is that supposed to do?
gnufied has joined #ruby
<jokke>
well _that_ isn't a very good example i understand
<dminuoso_>
I mean you could do 5.times.reduce(&:+) if thats what you mean
gnufied__ has joined #ruby
<jokke>
no
<jokke>
ok here:
<jokke>
5.times.reduce(Time.now, :prev_day)
<jokke>
(i understand this works with - 1.day)
<dminuoso_>
And what is that supposed to do?
<jokke>
uh 5.days
<jokke>
it's supposed to give me the time 5 days ago
chouhoulis has joined #ruby
claudiuinberlin has joined #ruby
<dminuoso_>
?xy
<ruby[bot]>
it seems like you are asking for a specific solution to a problem, instead of asking about your problem. This often leads to bad solutions and increases frustration for you and those trying to help you. More: http://meta.stackexchange.com/a/66378
<jokke>
ok this is still not a good enough example
<jokke>
5.times.reduce(Time.now, :prev_month)
<jokke>
tere
gnufied__ has quit [Client Quit]
<jokke>
there
<dminuoso_>
jokke: Don't give us an example, give us what problem you are trying to solve.
<jokke>
it takes time to explain
<jokke>
well ok i'll try
<dminuoso_>
Then take your time, prepare a good gist.
<jokke>
i need to "snap" time objects to certain boundaries
<jokke>
for example to a "5 days" boundary
danguita has quit [Quit: Ciao! (WeeChat 0.4.2)]
<jokke>
or 2 months
<jokke>
or what ever
<jokke>
because humans have an annoying time system i can't just go and kind of "modulo" my way through
Jameser has quit [Max SendQ exceeded]
<jokke>
this mainly applies for months
<dminuoso_>
jokke: What kind of boundaries were you thinking off?
<dminuoso_>
Annual quarters?
<jokke>
_any_
<jokke>
literally any boundaries
<jokke>
17 seconds
<jokke>
5 days
<jokke>
1 week
<jokke>
what ever
<dminuoso_>
jokke: The problem is that leap seconds and leap years screw up any generalized solution.
<jokke>
yes
ichkv has joined #ruby
<Burgestrand>
What's the use-case?
<jokke>
that's why i need to use #prev_X from active_support
<dminuoso_>
It's easy to cook up a solution if you are willing to ignore leap seconds and leap years.
<jokke>
Burgestrand: aggregation boundaries for time series data
<jokke>
dminuoso_: i'm not willing
<Burgestrand>
jokke So you have e.g. 2 months of data at a resolution of seconds, and you want to group it into X buckets where each bucket is Y long, where Y is e.g. 17 seconds, 2 weeks, 1 month?
<jokke>
but it's basically irrelevant, i have a working solution, but it's not pretty
Jameser has joined #ruby
<jokke>
Burgestrand: not quite
<jokke>
Y isn't always the same
synthroid has joined #ruby
chouhoulis has quit [Remote host closed the connection]
<dminuoso_>
jokke: Show us your solution then.
last_staff has quit [Quit: poof]
<dminuoso_>
jokke: Though actually, no you can do this simply. Use unix time.
<dminuoso_>
Then it's just a mathematical problem.
<dminuoso_>
It includes leap seconds and leap years.
<dminuoso_>
Then it's just timestamp % boundary
brendan- has quit [Quit: My iMac has gone to sleep. ZZZzzz…]
ziarkaen has joined #ruby
<dminuoso_>
Though it won't work in terms of "let a specific _day_ be a boundary"
<dminuoso_>
jokke: Then replace the first using unix timestamps.
<jokke>
yeah
slima has joined #ruby
<jokke>
i'm just not too happy about the reduce blocks
<jokke>
i'm aware btw. that using these doesn't necessarily result in equally spaced aggregates
ziarkaen has quit [Ping timeout: 252 seconds]
<jokke>
so something like snap_months(Time.now, 5) isn't smart
<dminuoso_>
jokke: a = stuff; 5.times { a = a.prev_day }
<jokke>
but snap_months(Time.now, 4) would be ok
<dminuoso_>
jokke: You know..
<jokke>
yeah
<dminuoso_>
No reason to try to be smart with reduce.
<jokke>
but then i need to add the line "a"
<jokke>
:)
<dminuoso_>
So what?
<jokke>
yeaaah yeah
<jokke>
you're right of course
<dminuoso_>
Trying to jam everything into one line adds complexity, possibly performance overhead and reduces readability.
<slima>
Hi, I have a problem with UTF-8 and mysql, can you see my code and hint me? http://pastebin.com/SVbYnKNK it is write file, but content is ??# (this is my first ever script in ruby 1.9.3)
<ruby[bot]>
slima: we in #ruby do not like pastebin.com, it loads slowly for most, has ads which are distracting and has terrible formatting. Please use https://gist.github.com
<dminuoso_>
All for what, the excitement of having written a one liner?
Salve has quit [Read error: Connection reset by peer]
ichkv has quit [Read error: Connection reset by peer]
<dminuoso_>
jokke: A good rule of thumb is to let have every line of code only do one semantic piece of action. If you then name your variables sensibly, it allows anyone or you in a year from now to look at the code and immediately understand whats going on.
GodFather_ has joined #ruby
pawnbox has quit [Remote host closed the connection]
<jokke>
yes
brendan- has quit [Quit: My iMac has gone to sleep. ZZZzzz…]
pawnbox has joined #ruby
camilasan has quit [Remote host closed the connection]
anjana has quit [Remote host closed the connection]
disconnekted has joined #ruby
camilasan has joined #ruby
ldnunes has joined #ruby
Tristan-Speccy has joined #ruby
Tristan-Speccy is now known as Guest42047
hinbody has joined #ruby
phoo1234567 has joined #ruby
vuoto has joined #ruby
yosafbridge has quit [Remote host closed the connection]
<jokke>
it won't work with leap seconds though, right?
vuoto has joined #ruby
pawnbox has quit [Remote host closed the connection]
pawnbox has joined #ruby
vuoto has quit [Remote host closed the connection]
phoo1234567 has quit [Read error: Connection reset by peer]
quiqua has joined #ruby
ichkv has joined #ruby
vuoto has joined #ruby
phoo1234567 has joined #ruby
vuoto has quit [Remote host closed the connection]
bihi has quit [Ping timeout: 250 seconds]
vuoto has joined #ruby
rippa has joined #ruby
waxxy has joined #ruby
sdwrage has joined #ruby
sdwrage has quit [Client Quit]
ichkv has quit [Read error: Connection reset by peer]
ramortegui has joined #ruby
merlin2049er has left #ruby [#ruby]
frozengeek has quit [Quit: frozengeek]
bihi has joined #ruby
frozengeek has joined #ruby
charliesome has joined #ruby
ziarkaen has joined #ruby
jphase has joined #ruby
rajdesai has quit [Remote host closed the connection]
rajdesai has joined #ruby
<jokke>
ohhh it's way easier
jphase_ has joined #ruby
roflmyeggo has joined #ruby
solocshaw has quit [Ping timeout: 245 seconds]
ledestin has quit [Ping timeout: 265 seconds]
jgpawletko has joined #ruby
pawnbox has quit [Remote host closed the connection]
jphase has quit [Ping timeout: 245 seconds]
pawnbox has joined #ruby
rajdesai has quit [Ping timeout: 252 seconds]
jphase_ has quit [Ping timeout: 245 seconds]
bmurt has joined #ruby
sptgugja has joined #ruby
<sts>
hello folks. has anyone ever used state_machines? I got issues when I try to transition more than once within a event. It just runs the first transition call, then nothing.
yosafbridge has joined #ruby
porfa has joined #ruby
Hyuk has quit [Quit: My MacBook Air has gone to sleep. ZZZzzz…]
senayar has joined #ruby
senayar has joined #ruby
senayar has quit [Changing host]
brendan- has joined #ruby
anjana has joined #ruby
nowhere_man has joined #ruby
flashpoint9 has joined #ruby
charliesome has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
Blueby has joined #ruby
GodFather_ has quit [Ping timeout: 244 seconds]
<hanmac>
jokke: hm you can checkout DateTime.new too
<hanmac>
hmm i think i found a bug in Time/DateTime ... Time.now.dst? returns true, but "Time.now.to_datetime.to_time.dst? # => false"
ichkv has joined #ruby
Hyuk has joined #ruby
shayan_ has joined #ruby
tvw has joined #ruby
slima has left #ruby [#ruby]
brendan- has quit [Quit: My iMac has gone to sleep. ZZZzzz…]
malconis_ has joined #ruby
DLSteve has joined #ruby
Kendos-Kenlen has joined #ruby
<Kendos-Kenlen>
Hi :)
matp_ has joined #ruby
pawnbox has quit [Remote host closed the connection]
charliesome has joined #ruby
pawnbox has joined #ruby
saslam has joined #ruby
shinnya has joined #ruby
<Kendos-Kenlen>
I'm trying to write a regexp to match the following line : "tty: tty.o fc.o". I would like to get the "tty" word, plus each words after. I currently have this regexp : "/([\w.]+): *(([\w.]+) ?)*/".
matp__ has joined #ruby
<Kendos-Kenlen>
It gets the first word, "tty", but only return the last word for the second art ("fc.o"), but not the "tty.o" word.
tuxaddicted has quit [Quit: leaving]
matp has quit [Ping timeout: 260 seconds]
jphase has joined #ruby
Hyuk has quit [Ping timeout: 252 seconds]
agent_white has quit [Ping timeout: 256 seconds]
<ljarvis>
Kendos-Kenlen: can't you test for "tty" in your regex?
<ljarvis>
or can that be anything?
<Kendos-Kenlen>
ljarvis: nop, because it can be anything
matp_ has quit [Ping timeout: 260 seconds]
<Kendos-Kenlen>
Here, it's just an example :)
<ljarvis>
Kendos-Kenlen: so you want "tty: tty.o"?
uranellus has quit [Quit: ZNC 1.6.1 - http://znc.in]
<ljarvis>
or..
<ljarvis>
im confused
jgpawletko has quit [Quit: jgpawletko]
<Kendos-Kenlen>
ljarvis: i want to get the 3 words, "tty", "tty.o" and "fc.o"
nowhere_man has quit [Ping timeout: 245 seconds]
<ljarvis>
so you only want to remove : ?
<Kendos-Kenlen>
But my regex only return "tty" and "fc.o"