tuor

Activity Graph

Page 1 of 3 | Next »

2019-03-12

[08:30:14] tuor: has joined #ruby
[08:31:19] tuor: Hi, this is how my code is right now: https://dpaste.de/ok5i
[08:33:17] tuor: Are there any "don't do that!" in it? Or do you have any sugsetion what I should do differently for reason x? I wrote ruby befor like 3 or 4 years ago and learned a lot with this channel. But don't hit me if I can't remember all of what you told me. ;)
[08:33:55] tuor: So I'm still a beginner. ;)
[10:00:40] tuor: Thx for your comments, this is what I got up with: https://dpaste.de/C0u4
[10:29:34] tuor: I have the rescue part in my code, how can I fail in a part of the script and jump to that rescue part. Like `error = 'failure reason; go to rescue`
[10:38:31] tuor: ljarvis: I'm trying to put it into a function. but how can I let the function fail? If I'm not happy with the given path the function should fail.
[10:44:17] tuor: I tried it but it doesn't fail on an empty string: https://dpaste.de/QL2u
[10:52:10] tuor: It is working like this: https://dpaste.de/tWbz
[10:52:38] tuor: ACTION is going afk, but come back later and will read if someone mentions him!
[13:01:12] tuor: I improved failure handling. How does it look now? https://dpaste.de/o4Dt
[14:23:31] tuor: phaul: I'll read and try to understand. ;)
[14:24:31] tuor: ah I understand. This would be a lot better then what I do. :) I will change it. thx!
[14:32:05] tuor: done and some other small changes (comments most of it): https://dpaste.de/58qd
[15:07:46] tuor: Thx for all your help today! I'll leave now. bye.
[15:07:54] tuor: has left #ruby: ("cu")

2019-03-11

[09:51:39] tuor: has joined #ruby
[09:53:39] tuor: Hi, this is my code: https://dpaste.de/SZpp#L
[10:01:28] tuor: What I want to do is: if STDIN has a key path with a non empty string as value, make a Pathname with this string. I want to add to this code, that if path doesn't get assigned a pathname, path gets a default pathname. How should I do that? I could do it like this: https://dpaste.de/AHn0
[10:02:00] tuor: How would you do it?
[10:08:13] tuor: hmm ||= seems nice. I'll try. :)
[12:03:15] tuor: Ping timeout: 246 seconds

2019-03-07

[08:37:11] tuor: has joined #ruby
[08:38:01] tuor: hi, when should I use double quotes and when should I use single quotes for strings?
[08:56:21] tuor: It seems no general rule all agree on. But is my assumption right, single quotes are performing better?
[08:57:49] tuor: hmm ok. thx!
[14:35:27] tuor: Hi, is there ruby a option which passes a string as STDIN to a script? like ruby myscript --stdin '{"secret":"asdf"}'
[14:55:37] tuor: I can't call the ruby binary with bash. It's called by my IDE RubyMine and RubyMine doesn't support redirection of STDIN... So I am looking for some other way. Right Now I use STDIN.reopen('/tmp/path.json') in the beginning of my ruby script, but I have to comment it out befor each git commit. That's not very nice.
[15:48:40] tuor: How can I test if a passed object to a method is of a specific class?
[15:53:28] tuor: let me try.
[15:55:00] tuor: is working thx!
[16:22:11] tuor: ACTION can't remember having see === befor.
[16:22:22] tuor: s/see/seen/
[16:26:15] tuor: #is_a? and === seem both to be fine to me. :)
[16:30:31] tuor: I like the #is_a? variation, in my opinion it's more readable.
[16:35:54] tuor: has left #ruby: ("Thx for all your help today! cu")

2019-03-06

[13:03:05] tuor: has joined #ruby
[15:26:03] tuor: Quit: Konversation terminated!

2019-03-05

[13:43:25] tuor: has joined #ruby
[14:44:24] tuor: Quit: Konversation terminated!

2019-03-01

[11:09:53] tuor: has joined #ruby
[14:31:21] tuor: Quit: Konversation terminated!

2019-02-28

[09:08:17] tuor: has joined #ruby
[11:20:18] tuor: Ping timeout: 264 seconds

2019-02-26

[09:19:12] tuor: has joined #ruby
[14:12:33] tuor: Ping timeout: 245 seconds

2019-02-25

[13:42:52] tuor: has joined #ruby
[14:31:57] tuor: Quit: Konversation terminated!

2019-02-13

[10:54:22] tuor: has joined #ruby
[12:31:59] tuor: Quit: Konversation terminated!

2019-02-11

[09:14:31] tuor: has joined #ruby
[10:00:03] tuor: Ping timeout: 246 seconds

2019-02-08

[10:42:12] tuor: has joined #ruby
[15:36:04] tuor: Quit: Konversation terminated!

2019-02-05

[08:47:14] tuor: has joined #ruby
[14:51:21] tuor: Quit: Konversation terminated!

2019-01-31

[08:29:13] tuor: has joined #ruby
[16:03:06] tuor: Quit: Konversation terminated!

2019-01-30

[10:22:55] tuor: has joined #ruby
[10:22:56] tuor: has joined #RubyOnRails
[15:33:41] tuor: has left #RubyOnRails: ("bye")
[15:53:03] tuor: Quit: Konversation terminated!

2019-01-29

[07:49:29] tuor: has joined #ruby
[07:49:30] tuor: has joined #RubyOnRails
[09:02:33] tuor: Ping timeout: 246 seconds
[14:10:48] tuor: has joined #ruby
[14:10:50] tuor: has joined #RubyOnRails
[17:51:43] tuor: Quit: Konversation terminated!

2019-01-25

[09:44:34] tuor: has joined #ruby
[09:44:36] tuor: has joined #RubyOnRails
[10:15:48] tuor: hi, what does this line? `hostgroup_create = hostgroup_create ? 1 : 0`
[10:16:23] tuor: I know it is a variable assignment but the part with `? 1 : 0` is new to me...
[14:51:42] tuor: Quit: Konversation terminated!

2019-01-21

[08:49:36] tuor: has joined #ruby
[08:49:38] tuor: has joined #RubyOnRails
[10:00:31] tuor: Ping timeout: 246 seconds

2018-12-17

[14:44:16] tuor: has joined #ruby
[14:44:17] tuor: has joined #RubyOnRails
[14:58:06] tuor: Ping timeout: 244 seconds

2018-12-06

[13:24:34] tuor: has joined #ruby
[13:24:35] tuor: has joined #RubyOnRails
[16:10:55] tuor: Quit: Konversation terminated!

2018-11-22

[10:54:44] tuor: has joined #ruby
[10:54:45] tuor: has joined #RubyOnRails
[10:56:44] tuor: hi, I did configure rvm and change my terminal to use bash --login instead of bash. But I can't change how my IDE RubyMine invokes bash. In my terminal rvm is working just right but in my IDE I'm getting a warning:
[10:56:57] tuor: Warning! PATH is not properly set up, /home/aaron/.rvm/gems/ruby-2.5.1/bin is not at first place.
[10:57:33] tuor: RubyMine 2018.2.5
[16:44:27] tuor: Quit: Konversation terminated!

2018-11-19

[15:38:55] tuor: has joined #ruby
[15:38:57] tuor: has joined #RubyOnRails
[18:18:56] tuor: Quit: Konversation terminated!

2018-11-16

[12:21:25] tuor: has joined #ruby
[12:21:27] tuor: has joined #RubyOnRails
[17:12:13] tuor: Quit: Konversation terminated!

2018-11-07

[10:41:07] tuor: has joined #ruby
[10:41:09] tuor: has joined #RubyOnRails
[18:23:55] tuor: Quit: Konversation terminated!

2018-10-31

[11:36:00] tuor: has joined #ruby
[11:36:02] tuor: has joined #RubyOnRails
[12:33:32] tuor: Quit: Konversation terminated!

2018-10-30

[07:50:32] tuor: has joined #ruby
[07:50:33] tuor: has joined #RubyOnRails
[08:15:48] tuor: Quit: Konversation terminated!

2018-10-25

[07:09:26] tuor: has joined #ruby
[07:09:27] tuor: has joined #RubyOnRails
[08:32:15] tuor: Ping timeout: 246 seconds
[09:40:34] tuor: has joined #ruby
[09:40:36] tuor: has joined #RubyOnRails
[10:23:18] tuor: Ping timeout: 244 seconds

2018-10-24

[07:31:39] tuor: has joined #ruby
[07:31:40] tuor: has joined #RubyOnRails
[16:00:26] tuor: Quit: Konversation terminated!

2018-10-23

[05:42:50] tuor: has joined #ruby
[05:42:52] tuor: has joined #RubyOnRails
[14:05:16] tuor: Quit: Konversation terminated!

2018-10-22

[07:01:58] tuor: has joined #ruby
[07:01:59] tuor: has joined #RubyOnRails
[12:17:21] tuor: Ping timeout: 252 seconds

2018-10-19

[11:23:07] tuor: has joined #ruby
[11:23:08] tuor: has joined #RubyOnRails
[16:16:24] tuor: Quit: Konversation terminated!

2018-10-18

[06:19:10] tuor: has joined #ruby
[06:19:12] tuor: has joined #RubyOnRails
[08:24:18] tuor: Ping timeout: 244 seconds

2018-10-17

[07:39:19] tuor: has joined #ruby
[07:39:20] tuor: has joined #RubyOnRails
[14:25:03] tuor: Ping timeout: 245 seconds

2018-09-20

[09:54:17] tuor: has joined #ruby

2018-09-19

[06:59:28] tuor: has joined #ruby
[16:25:03] tuor: Ping timeout: 245 seconds

2018-09-18

[08:58:41] tuor: has joined #ruby
[10:44:38] tuor: Ping timeout: 245 seconds
[11:08:13] tuor: has joined #ruby
[14:21:06] tuor: Ping timeout: 272 seconds

2018-09-17

[05:45:02] tuor: has joined #ruby
[06:11:20] tuor: Ping timeout: 272 seconds

2018-09-14

[09:19:19] tuor: has joined #ruby
[15:23:02] tuor: Quit: Konversation terminated!

2018-09-11

[08:08:14] tuor: has joined #ruby
[08:09:12] tuor: hi, I have installed the rvm package from the ppa: ppa.launchpad.net/rael-gc/rvm/ubuntu/.
[08:11:23] tuor: Now I have tried to install ruby with rvm, but I got a lot of erros like this: tar: binscripts: Cannot utime: Operation not permitted
[08:12:18] tuor: What could be the problem?
[08:20:46] tuor: Knappe: did the trick thx.: rvmsudo rvm get stable
[08:22:21] tuor: has joined #RubyOnRails
[08:23:57] tuor: Knappe: checkout https://freenode.irclog.whitequark.org/ruby/2018-09-10 for the history of yersturday
[08:24:31] tuor: s/yersturday/yesterday
[08:27:25] tuor: found it in the channel description. ;)
[08:34:00] tuor: :) -> ruby-2.5.1 - #compiling.....
[15:53:55] tuor: Ping timeout: 246 seconds

2018-08-08

[14:47:45] tuor: has joined #ruby
[15:00:22] tuor: Ping timeout: 264 seconds

2018-07-26

[06:50:45] tuor: has joined #ruby
[06:51:28] tuor: (my setup: Ubuntu 16.04) Hi, I have installed gem with sudo and now I always need sudo to install gems. How can I remove all gems and start over with all my gems in my $HOME? So I don't require sudo to install gems....
[07:07:37] tuor: apt install ruby (I think)
[07:07:52] tuor: dalpo: pretty shure yes.
[07:08:40] tuor: I want to be able to install gems an use bundle and rake in my home without sudo. What do I have to do?
[07:12:24] tuor: I'm the only user of this laptop. Can I install ruby in a way, that gem, bundle, rake, what ever is all handled inside my home by default?
[07:33:06] tuor: I'll check it out. thx all of you for your help!
[07:34:07] tuor: Quit: Konversation terminated!
[07:37:42] tuor: has joined #ruby
[07:38:02] tuor: ACTION is back again.
[08:02:19] tuor: Radar: thx :)
[08:29:09] tuor: Ping timeout: 244 seconds
[09:45:18] tuor: has joined #ruby
[10:55:27] tuor: Ping timeout: 240 seconds
[12:38:39] tuor: has joined #ruby
[13:46:36] tuor: Quit: Konversation terminated!

2018-07-25

[14:33:52] tuor: has joined #ruby
[14:39:29] tuor: Ping timeout: 265 seconds

2016-01-12

[07:44:59] tuor: has left #ruby: ("WeeChat 1.3")

2016-01-11

[17:15:49] tuor: has joined #ruby

2016-01-05

[10:23:00] tuor: has left #ruby: ("WeeChat 1.3")

2015-12-21

[09:50:28] tuor: *.net *.split
[09:56:45] tuor: has joined #ruby

2015-12-02

[15:37:01] tuor: *.net *.split
[15:41:36] tuor: has joined #ruby
[15:53:11] tuor: *.net *.split
[16:47:51] tuor: has joined #ruby

2015-11-30

[22:47:14] tuor: Ping timeout: 245 seconds
[22:59:21] tuor: has joined #ruby

2015-11-29

[22:18:30] tuor: *.net *.split
[23:08:44] tuor: has joined #ruby

2015-11-27

[08:42:01] tuor: *.net *.split
[10:34:48] tuor: *.net *.split

2015-11-26

[08:09:21] tuor: has joined #ruby
[08:44:00] tuor: *.net *.split
[09:32:10] tuor: has joined #ruby
[18:33:46] tuor: *.net *.split

2015-11-22

[03:45:57] tuor: *.net *.split
[03:56:17] tuor: has joined #ruby

2015-11-14

[05:51:05] tuor: Ping timeout: 250 seconds
[05:51:58] tuor: has joined #ruby

2015-10-16

[00:13:38] tuor: has joined #ruby

2015-10-01

[07:19:37] tuor: Ping timeout: 265 seconds
[07:33:12] tuor: has joined #ruby
[10:36:52] tuor: hi, what gem would you use for managing keepass databases? (I know there are multiple but which one do you recomend?)
[10:38:39] tuor: "gem search --remote keepass" gives me 5

2015-09-30

[08:15:54] tuor: Quit: WeeChat 1.1.1
[08:28:11] tuor: has joined #ruby
[10:00:43] tuor: Quit: WeeChat 1.1.1
[10:00:57] tuor: has joined #ruby
[10:26:17] tuor: Remote host closed the connection
[10:26:30] tuor: has joined #ruby
[10:27:33] tuor: Client Quit
[10:27:45] tuor: has joined #ruby
[10:29:54] tuor: Client Quit
[10:30:06] tuor: has joined #ruby
[10:31:56] tuor: Client Quit
[10:32:08] tuor: has joined #ruby
[10:43:59] tuor: Quit: WeeChat 1.1.1
[10:44:12] tuor: has joined #ruby
[10:48:27] tuor: Client Quit
[10:48:52] tuor: has joined #ruby
[10:51:56] tuor: Client Quit
[10:53:28] tuor: has joined #ruby
[10:55:54] tuor: Client Quit
[11:00:21] tuor: has joined #ruby
[11:01:29] tuor: Client Quit
[14:01:11] tuor: has joined #ruby
[14:05:24] tuor: jhass, so I tried to improve my code: https://gist.github.com/nod0n/d01024a5b6aecab2b1c7
[14:09:02] tuor: For all the people which help me a time ago to improve my code, here is a new version of my class: https://gist.github.com/nod0n/d01024a5b6aecab2b1c7
[14:10:57] tuor: I tried to improve some stuff, but I know error handling is mostly missing and it's still not logging. Apart from this, what would you improve/change?
[14:13:21] tuor: certainty, why? (what would be the benefit?)
[14:16:09] tuor: export or import templates from a zabbix server.
[14:17:31] tuor: The thing is, it's using a gem for using the zabbix api. This class should give the missing possibility of the ZabbixApi gem.
[14:18:02] tuor: certainty, ok. I'll think about how to separate them. But when they need the same code (some methods) what do I do then?
[14:19:03] tuor: ok. Then i should make one class for the shared stuff, and one for each function (import | export).
[14:22:12] tuor: ok. I'll think about it (and try).
[14:28:50] tuor: Remote host closed the connection
[14:29:05] tuor: has joined #ruby
[14:36:08] tuor: Remote host closed the connection
[14:36:21] tuor: has joined #ruby
[14:42:30] tuor: Remote host closed the connection
[14:42:42] tuor: has joined #ruby
[14:56:42] tuor: Remote host closed the connection
[14:56:56] tuor: has joined #ruby
[15:14:05] tuor: has joined #ruby
[15:14:05] tuor: Changing host

2015-09-29

[10:18:32] tuor: jhass, i didn't change the names of all the methods because i want to rethink about how to do it and then directly rewrite with better names.
[10:18:45] tuor: I just want to do all the other stuff first.
[10:20:03] tuor: To assign to @templates_list comes with how I used it befor. I just didn't removed it (because I don't checked if it's realy changed every where)
[10:22:39] tuor: ACTION is working on list_templates.
[10:28:01] tuor: jhass, so the list_templates is cleaned a little bit up: https://gist.github.com/nod0n/e9db3cb04b4eb5557027
[10:29:44] tuor: I'll have a breake and then try to rewrite the options stuff. Cu later. Thx for your help jhass! :)