This is a weekly roundup of awesome DEV comments that you may have missed. You are welcome and encouraged to boost posts and comments yourself using the #bestofdev tag.
The Describe Your Job With a GIF! thread was a ton of fun, and we could have selected multiple "top comments" from that discussion. @itsasine
selected a GIF which was much-loved and captured a hilariously common theme:
The You Can Do it in SQL, Stop Writing Extra Code for it article raised a lot of interesting points about the way that many programmers consider and use SQL. @melezhik
offered an important caveat and consideration:
Putting application logic into DB scope might end up with hard to maintain and troubleshoot code, though I can agree sometimes knowledge of SQL help you getting things done, but I'd leave this approach for custom reports based on SQL queries rather than for web application or something when you are free to process data in controller level.
I believe that Java, as a platform, will never die. The JVM and its ecosystem of incredibly high-quality libraries, coupled with its deep roots in large-scale enterprise environments, makes it a worthy platform to develop for and will always continue to live on.
However, I do believe Java as a language will be increasingly replaced by Kotlin. Other JVM languages (Scala, Groovy, Clojure) might have tried to replace Java, but they never really delivered on that promise. They all did wildly different things using Java as a backbone, but simply aren't comfortable to devs used to doing things "the Java way". Scala brought pure functional programming. Groovy made it dynamic. But Kotlin is the first that was actually created to just be a better Java, and by-and-large if you're comfortable writing Java8-style code you'll pick up Kotlin very quickly and fall in love.
But a major part of the success of Kotlin is its perfect interop with Java. Kotlin is great because under-the-hood, it is just Java. There is nothing fundamentally different going on with Kotlin than plain-ol' Java. Both Scala and Groovy have their own runtimes which run on the JVM but aren't entirely compatible with Java. Kotlin just compiles to the exact same thing that Java does, which is a huge advantage for incremental migration, especially in large, slow-moving enterprises.
So many of us have side projects that lie in some form of in-progress and/or abandoned. In How do you get back into a side project after months?, @andywer
provides a way to stay organized and motivated:
After having had that problem for years, I started... writing stuff down :D
- I create issues in GitHub, not only for what doesn't work yet, but also for features I want to add in the future
- I create pull requests when introducing code changes, even if there is no one to review them
- Oftentimes before I start working on it, I collect my thoughts on what I want to achieve and what pain I have that I want to solve
Not too detailed, a few bullet points per idea usually do the trick.
Doesn't take much time, but when I come back after pausing for months, I can just read up on my initial motivation and plans, as well as getting an overview of what I was doing before I left.
Plus: Not having to worry about forgetting good lines of thought is a very comforting feeling 🙂
Finally, in the How Unix programmers at restaurants search menus for their favorite plate article, @moopet
provides a meta comment in response to some of the other comments both on-site and on-Reddit (where it was gaining some popularity):
I've been reading the thread about this on /r/programming (how circular!) and they're mostly (deliberately?) missing the point and trying to optimise it rather than to see it as a demonstration of pipes.
grep -q 'shrimp.*$[0-9]\.' menu.txt && echo "Available" || echo ":("
\d shortcode for
[0-9] so it'll work with BSD and GNU grep.
See you next week for more great comments ✌