#ruby - 29 December 2018
« Back 1 day Forward 1 day »
[00:36:50] cthu|: I forgot that It sees only immediate context. And I forgot that I actually don't call it directly but rather a proxy method that does some sugar :)
[01:34:24] havenwood: cthu|: you can have a single regexp with different delimiters in different parts
[01:34:48] havenwood: cthu|: (except `o`, for compiling the Regexp once, which is the whole thing or nothign)
[01:36:48] havenwood: an instrument for measuring the proportion of oxygenated hemoglobin in the blood.
[01:40:35] havenwood: adding the `o` delimiter would be a good regexp cop when just constants are interpolated into a regexp
[06:07:24] garyserj: I am having difficulty programmatically sending the ENTER key. I am using IRB (ruby interactive). If I do driver.find_element(:name, "q").send_keys("aaa\n"); it sends the aaa but not the ENTER. If I do driver.action.send_keys("\n").perform. That doesn’t do it either. And if I do \u0006 and \u0007 instead of \n, it still doesn’t work. i’ve also tried b=driver.find_element(:tag_name, "body”); b.send_key “\n”; b.send_keys
[06:07:56] garyserj: (using Selenium and the firefox browser. sendkeys to the searchbox on google.com.
[06:29:11] Uptime: is there a way to tell if a file is requirable besides just doing a require + rescue
[08:40:04] nanothief: Is there a shortcut in pry (or irb) to reload the last loaded file? E.g. if I start pry then `load "my_file.rb"`. After editing the file I want to reload it without having to type out that load statement again
[09:03:37] nanothief: Never mind, solved this myself by writing a custom pry command: https://pastebin.com/HAwYeHfV
[09:03:38] ruby[bot]: nanothief: 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
[09:24:03] daqing: hello everyone, I'm using rbenv with systemd. when my service starts, rbenv reports error with "rbenv: version '2.6.0' not found"
[21:52:31] hays: i have an object that creates some stuff at the system level that i'd like to ensure gets cleaned up
[21:56:49] hays: i guess i could have the user deal with it by having a method they call in an ensure block or something..
[22:03:17] phaul: ensure is better, with ensure it will run even if one jumps out somehow, throwing exception etc
[22:03:58] hays: and as a user if I want to have a bunch of objects like this and don't want nested blocks, I can just use begin/ensure/end to manage the resources