6 ms·
Man, I love Ruby. I think it is much more elegant than Python and I really really wish Ruby would have taken the world instead of Python. That said, it's often
by dyingkneepad 5y ago
Man, I love Ruby. I think it is much more elegant than Python and I really really wish Ruby would have taken the world instead of Python. That said, it's often the case where I want to do something where there's just no Ruby library for it (or at least not a maintained one) and there's a well known library for it in Python. Note: I do low level things, I don't do anything related to web or Rails.
Also, sometimes I start writing scripts for simple things, then they grow and at some point it's interesting to share them to my teammates, and they all immediately dismiss it since it's in Ruby. For that reason, I started doing all my work-related scripting in Python. But oh boy, it's always with that sad feeling of "I wish I was doing this in Ruby". Sometimes I think I should just not have learned Ruby and jumped straight to Python.
- Torwald 5y agoCan you give me one or twoo examples for such missing low-level stuff Ruby libraries, please?
- dyingkneepad 5y agoTwo examples I remember researching Ruby for and ended up giving up: hardcore statistics stuff (I'm using using Python's scipy.stats now) and GUI toolkits (yes, there are some toolkits available, but nothing like Python's official bindings for gtk/qt). It's hard to remember more examples. I remember having problems even with FastCGI on Ruby, but I ended up not writing the code at all so that won't count. Also something related to parsing emails.
- stevekemp 5y agoI have to admit I've had a similar reaction, at a previous company we were "forced" to use Ruby to be consistent. I grew to love Ruby, though I admit I always approached it with half a mind pretending I was writing Perl. These days I've sometimes fallen back into Ruby, but then had issues sharing it with colleagues - so I've largely switched to Go. While most people don't have a dev-environment setup I can give them binaries built via github/gitlab/jenkins, and so sharing tools & utilities is just that little bit less painful than with Ruby (and even Python).
- strzibny 5y agoruby-packer worked for my little Ruby things in that regard https://nts.strzibny.name/making-a-ruby-executable-with-ruby-packer/ https://nts.strzibny.name/making-a-ruby-executable-with-ruby...
- weaksauce 5y agowhy not docker?
- benbristow 5y agoI used to work somewhere where I got "forced" to use Perl but was more familiar with Ruby. Obviously Perl came far earlier than Ruby and Ruby was heavily inspired by Perl (There's even a quick comparison on the official Ruby site here https://www.ruby-lang.org/en/documentation/ruby-from-other-languages/to-ruby-from-perl/ https://www.ruby-lang.org/en/documentation/ruby-from-other-l...) but it always felt like Ruby is such a nicer language to read and write and obviously due to age was just a more modern overall. You could define a class as a... class! Whenever I wanted to make a quick script for myself for personal usage I'd always write it in Ruby. I'm now in a C#/.NET role and love typed languages now but I'd never go back to Perl, but I still have a special spot for Ruby.
- cutler 5y agoPerl got lost in arguments over whether to adopt a meta-object protocol (MOP) in the core and if so, which one. That and the endless variants of Moose just took TIMTOWTDI to ridiculous extremes. Meanwhile PHP and Rails were eating Perl's lunch.
- seiferteric 5y agoI just the other day started working on an idea for a ruby based shell: https://github.com/seiferteric/rbshell https://github.com/seiferteric/rbshell . The idea is to try to write a ruby DSL that looks as similar as possible to regular CLI commands, but return ruby objects so you can more easily process the results. I would be interested in some help if others are interested. I haven't yet decided on the exact syntax yet but it is already looking kind of interesting I think.
- freedomben 5y agoneat, I started a similar thing in 2014 but just didn't have the time it needed. I sincerely wish you well on your effort! I'd still love to have a shell based on ruby.
- subandi 5y agoI was just daydreaming about this the other day and would definitely give the finished project a spin. Depending on what you need (I'm a Rails dev, so pretty ok with Ruby in general but probably of not much help on the system end) I'd be happy to support you.
- ash_while 5y agoI feel very similarly! Ruby just feels like such a well designed system from the ground-up. The object model is so elegant and consistent. The standard library is feature-full and fun to use, and the docs are excellent. Ruby is a beautiful object-oriented language but also leans into the power of FP with a plethora of functions defined on the powerful base-classes like Enumerable. In comparison, Python feels way less thoughtful, more of an ad-hoc language constructed through independent decisions over a long period of time
- dyingkneepad 5y agoYes, exactly! Even Python's object orientation feels like a hack made on top of a procedural language.
- jacobsenscott 5y agoIt just shows how "cargo cult" driven our industry is. Ruby was in. Then it was out, because it "doesn't scale". Then suddenly Python is in, even though it is has the exact same performance characteristics, give or take some constant value, as Ruby.
- luibelgo 5y agoLanguages look similar, but Python value resides in the vast amount of libraries available to do data processing and ML. Most of them backed by C implementations under the hood.
- Grimm1 5y agoExactly, and though Ruby has an FFI (Foreign Function Interface) similar libraries were not created and Ruby was pigeon holed as a language you build CRUD apps in.
- rmetzler 5y agoThere is a dev adding Ruby bindings via FFI to ML libs. Unfortunately it doesn't seem to be a large community (yet). I don't do any ML and don't know much about it, but the Elixir / Phoenix people around José Valim now build ML software (nx, livebook) and I'm excited for this.
- cutler 5y agoThere's nothing about Python, compared with Ruby, that gives it any advantage, numerics or otherwise. Ruby's C ffi is just as powerful as Python's. It's all just a first mover phenomenon. Python is the VHS of programming languages.
- luibelgo 5y agoCommunity matters. In this case Python community around data science is huge.
- Glyptodon 5y agoI also think Ruby is so much cleaner and more productive than Python. I really miss it. The number of times I think "this is like a bad version of Ruby" while doing stuff in Python...
- seiferteric 5y agoPerhaps we need a ruby <-> python transpiler so you can secretly program in ruby on python projects.
- cutler 5y agoEspecially with Python lambdas. Such a contrast with Ruby's elegantly-designed blocks, Procs and lambdas.
- weaksauce 5y agoYeah I love ruby too... why do they dismiss it if docker is there for them to get running quickly? python is just so janky to me
- Grimm1 5y agoOne of the major reasons Ruby didn't take off [outside of web] is because of the library availability. Ruby was pigeon holed by Rails while in Python I can reach for a library for pretty much any usecase and scenario from Genomics to Web. The thing is that is an issue of community, because Ruby does have an FFI and there is really nothing stopping people from building libraries similar to how they're done in Python, calling out to C. They just didn't.
- deleted 5y ago[deleted]
- Shicholas 5y agoAnother comment to piggy back off the ruby > python love. RSpec is a million times better than any testing library in python and bundler solved package management issues years ago that python still hasn’t solved. Glad to see I’m not alone!
- likeabbas 5y agoI must be in the minority. I strongly dislike Python, and I loathe Ruby. Give me a statically typed language any day of the week.
- gorgoiler 5y agoRuby was in my blood, once. Mountains of systems integration and backend parsing and business logic. Never any Rails though. The older and more boring I got, the more I liked Python. Young me and old me both knew what they were doing.