Page 1 of 1
[10:56:27] up|ime: the bot was having problems and I couldn't bother finding out what the syntax would be :P
[19:28:42] up|ime: i would create a specific exception so you don't end up try-catching all exceptions
[19:29:58] up|ime: and your test is closer to an integration test, but the first thing your test is that you need root
[19:31:34] up|ime: path_exists? is also just an extension to file.exists but instead of returning a boolean you throw if false
[19:31:59] up|ime: it may be harsh, but I don't think your helper is helping anyone in its current state
[19:33:12] up|ime: well my point is more that for instance def need_root raise('need root privileges') unless Process.uid.zero? end is very basic programming
[19:33:36] up|ime: it'd be more work to read your documentation, instantiate the class, and then run the method
[19:34:16] up|ime: if your goal is to help yourself: great, but consider that if a stranger looks at it they will wonder why you are reinventing the wheel
[19:34:47] up|ime: I would write a OpenBsdHelper to get around quirks of openbsd, rather than to alias "file.create" to "OpenBsdHelper.create_file"
[19:35:22] up|ime: if this is a learning excerise: Fantastic, but I question its use in the real world
[10:20:22] up|ime: i did the same, but in a more "i take this literal knowing it's not your problem"
[16:09:22] up|ime: Last time I tried RubyMine (the Jetbrains IDE) it sucked badly, 2 or so years ago
[12:43:44] up|ime: if you're dealing with forms they can send arrays of data and/or json post bodies