HNHacker News
TopNewBestAskShowJobs

babarock

1,956 karma · joined October 7, 2011

My name is Joe. I work at Red Hat.

The opinions I express here represent my own and not those of my employer.

submissionscomments
babarock··on Awk in 20 Minutes
Good question. I've been working with awk for several years now, and here's how I feel about it.

AWK is old. 1977 old. Later versions that appeared (nawk and gawk are the most common) helped make it a smoother language, but it's still a pain. There are definite features you will be missing in an awk script:

- Any useful data structure slightly more complex than associative arrays. Try multi dimensional arrays, it's actually fun to do. Once.

- Any useful programming construct to help manage with complexity of scripts longer than a few hundred lines. No classes, no variable scoping, no namespaces in general. Not to mention an extremely permissive compiler.

- Any easy way to deal with the environment (other than text). Try sending http requests in awk, it can be a pain.

In 2015, if you need to write a script you should almost always prefer python/ruby over awk.

Now if you're asking whether you should learn awk? It comes in handy. There are a lot of awk scripts in the wild, and you may need to read them or edit them one day. Also, awk has a fun way of parsing input, which makes for very enjoyable one liners. Learning awk (and some complementary utilities like sed or find) turned me into a "oh, it can be done in a quick one-liner" kind of guy. Definitely recommended.

babarock··on Emacs 24.4 released
I spent a couple of years using vim before switching to emacs around 3 years ago. I'll write about my own experience with both editors.

Learning emacs won't automatically give you a huge productivity boost the way learning vim does. Vim is this blazing fast editor; it's been designed from the ground up to be good at editing text. If your goal is to increase your productivity, I'd say invest time learning vim advanced features, like jumps, macros, registers, and the plethora of other things I don't know about.

Emacs is not about speed. It's about control. It's a fully customizable environment to manipulate text. You can use it to edit prose, code, scientific formulas, but also emails, IRC/Jabber clients, clients for virtually anything with a REST API. Here are some of the use cases that make my work easier using emacs:

+ Evaluating pieces of code at once. I write a lot of Python. Most REPLs out there allow editing of one line at a time. emacs allows me to fire a python interpreter and evaluate regions (multiline function definition, or data structure) at once. Similar features exist for other "dynamic" languages.

+ Better code review workflow. I receive code review requests via email immediately inside emacs. I can play with the diff files, the source files. I can make modifs or run the code without leaving my editor. And since the code review system has an HTTP API, I can even post my comments and votes back.

+ Org-mode (http://orgmode.org/). I would use emacs for this module alone. It's a note taking system that can easily transform into an agenda, todo lists, memo, document markup, tables (oh, the org-mode tables!), ...

Basically, to answer your question: I think you'll get a lot of benefits from emacs if you enjoy customizing it and integrating it to your workflow. If you don't like spending time customizing and prefer something that will just make you write text (well, code and configuration files) faster, stick to vim and spend this time learning advanced commands.

babarock··on Emacs Lisp's Future
Quoting the linked email:

  So if we go for Guile-Emacs, we'll be stuck with Guile, i.e. we'd
  have (old and new) packages that use Elisp, new packages that use
  Scheme, maybe yet other new packages that use, say, Javascript (or some
  other language support by Guile).  That would make the work of Emacs
  (and GNU ELPA) maintenance harder.
babarock··on Typographic Programming Language
Could this help us avoid the ugliness of nesting quotes and backslash-escaping hell?
babarock··on Can Reddit Grow Up?
Advertisers want you to think of their work as information. It'd be more accurate to describe it as unsolicited information using gross exaggerations to build up a product and appealing to emotions not reason.

I too care about cheap razors, vacuum robots or newer smartphones. But I find it intrusive when a program I'm watching is interrupted with a fast paced 30 seconds clip of sexy naked people telling me to go buy their new product right now.

If I want information, a subscription model to some sort of info periodical is almost always available. But this is much closer to what we consider "journalism" than "advertisement". (I realize the limit between the 2 is sometimes difficult to define).

babarock··on List of Web Business Models
One thing worth mentioning for games is what Valve is doing with Dota 2.

The game is truly free to play, and giving them all the money in the world will not give the player any in-game advantage. On the surface, the game sells various hero skins and other cosmetic items that are little more than vanity items. Looking closer, it seems that Valve is making (or at least trying to make) money by developing a scene of professional gamers around this game. Just last weekend they held an international competition (conveniently named [The International](http://www.dota2.com/international/overview/) ) where the prize pool exceeded 10 million USD. This pool was partly funded by the community of viewers paying to watch the pros play their games. I paid my ticket 7.5€ (10$) a third of which went directly to the prize pool.

I don't know if this model is viable or profitable. Maybe someone has more info. But it's worth looking at. I've always been interested by products that are free to use by the public and make money from the pros using it.

babarock··on HAProxy 1.5
It's not necessarily part of OpenStack, but you'll most likely find it in every openstack deployment out there.
babarock··on Red Hat to Acquire eNovance, an OpenStack Integration Services Company
Has anyone gone through their company being acquired by Red Hat? How'd it go? Any stories (you're allowed) to share?

Full disclosure: I work at eNovance.

babarock··on One reason I dread Google doc shares
I started using this a few months ago. It definitely helps a lot, but it can still break the workflow.

Using OSX, when I click on a link inside Mail, it opens it in Chrome using the last used user. It's annoying when it's the wrong user. You still need to switch users and reopen the link in Chrome.

babarock··on Europe's top court: people have right to be forgotten on Internet
A couple of questions pop to mind:

- Will that affect the work of archive.org and the wayback machine?

- Is it okay for a politician to "erase" something he/she said 10 years ago?

babarock··on Python 3.4.0 released
I don't want pip and virtualenv to be constantly changing and evolving. We finally reached a stage where they're usable reliably. Some stability wouldn't hurt.
babarock··on Python 3.4.0 released
Here's a good explanation of this technique: http://julien.danjou.info/blog/2013/python-3.4-single-dispat...
babarock··on Python 3.4.0 released
If anyone's interested in testing out Asyncio/Tulip on Python 2, here's a mostly-compatible backport: https://pypi.python.org/pypi/trollius/
babarock··on Linus Torvalds: “I'm happily hacking on a new save format using ‘libgit2’”
For those who missed it, here's what Linus wrote in the comments:

"+Aaron Traas no, XML isn't even good for document markup.

Use 'asciidoc' for document markup. Really. It's actually readable by humans, and easier to parse and way more flexible than XML.

XML is crap. Really. There are no excuses. XML is nasty to parse for humans, and it's a disaster to parse even for computers. There's just no reason for that horrible crap to exist.

As to JSON, it's certainly a better format than XML both for humans and computers, but it ends up sharing a lot of the same issues in the end: putting everything in one file is just not a good idea. There's a reason people end up using simple databases for a lot of things.

INI files are fine for simple config stuff. I still think that "git config" is a good implementation."

babarock··on Next Arab American on a stamp could be Steve Jobs
Big mistake calling Gibran Syrian... https://en.wikipedia.org/wiki/Khalil_Gibran

Actually, even calling him American is wrong. From the Wikipedia article:

> The young emigrant from Lebanon who came through Ellis Island in 1895 never became an American citizen; he loved his birthplace too much

babarock··on Losing graciously
It matters to sysadmins and programmers.
babarock··on Poll: How do you feel about working hours?
It fluctuates. At my current job, I've had 35-37 hours weeks and 50+ hours week. I voted for the second option, at the time of this writing:

    "I work 40-45 hours, and have no problem working a little extra when needed."
Even though it's not always a "little" extra.

I love what I do (to be more honest, I love the people I'm doing it with) so I don't count the hours (this is literally the first time in 8 months I counted).

I don't think it's an easy solution. You want employees who are willing to work extra when needed, but you want them to achieve a good work-life balance so that the rhythm is sustainable.

To be more specific about the Penny Arcade post, I don't find it as repulsive as most (vocal) people here did. Full disclaimer, I'm 26 with no kids. I enjoyed the honest tone of the offer, and I think there's a subset (a niche?) of engineers today that would be interested in working in these conditions.

Is it a place to make a career? probably not. But I wouldn't mind spending a year or two in that environment, as long as I know exactly what I'm stepping into since day 1. Being given this much work load implies a lot of responsibilities, and, in turn, lots and lots of opportunities to get better.

How would you feel about a martial artist or a musician deciding to spend a couple of years practicing their art for 12-15 hours a day?

babarock··on 37signals Works Remotely [video]
I might start working remotely full-time in a few months, so I would like to hear about some of its downsides. Can you share stories of remote working that didn't go as wonderfully as described in this (promotional) video?
babarock··on Explicit bootstrapping of pip in Python installations
Vaguely related, this wonderful article by Paul Tagliamonte on how pip coexists with distro package managers (in this case APT): http://notes.pault.ag/debian-python/

Nice reminder that pip is a dev tool and should be used as such. It makes sense to be included in Python.

babarock··on Explicit bootstrapping of pip in Python installations
More importantly, it's nice to assume your users will have pip available no matter what (assuming we all move to Python 3. One day...)
babarock··on The code culture problem
You're probably right, what do I know I've only been programming professionally for 3 years.

However, I find that it's more helpful to have a positive attitude when reading code I didn't write. "Why did he write it this weird way?" taught me so much more than "this is shit, let me rewrite it the way I'm familiar with".

I'm not denying that I found seriously bad code running in production. And I'm not denying that it's more common that I would've believed. But the moment I start treating every piece of foreign code as shit, I'll miss out on interesting insightful techniques.

The point of this article is a reminder that it's easy to get sucked in the "this is shit" culture.

babarock··on Start Using Emacs – A Thorough Guide for Beginners
And you shouldn't miss Bozhidar's blog on Emacs (http://emacsredux.com/) where he explains a lot of the very cool techniques he included in Prelude.
babarock··on We may get fired and I don't know what to do
You can either resign silently, or step up and go talk honestly with higher management with the risk of getting fired. In any case, you shouldn't continue working like that.

Finding a new job is easier than you think it'll be. Living in such a stressful environment is not worth it. The only thin you'll regret is not doing something about it.

babarock··on Why Should I Care What Color the Bikeshed Is? (1999)
Modern communication is broken. We think we're just getting tools to be reachable by people of interest. Instead we're just giving the world a way of spamming us. Constantly.

Phones are the worst. Excluding the few times I'm actually expecting a call, every time my phone rings it inevitably interrupts something I am doing. It's almost never urgent. I am basically spending hundreds (if not thousands by now) of dollars to get a mobile device to allow the world to interrupt me at any time. And there's very little I can do about it.

* I often ignore it on purpose, set it to "silent" mode or simply refuse answering (an act now commonly seen as rude by most). 9 times out of 10 I get the notoriously useless voicemail: "Hey it's me, call me back when you can".

* Last year I was victim of what can only be described as a phone spam technique from my ISP. In the course of 10 days, I received over 25 calls (most of which I intentionally refused to answer) from commercial representative trying to sell me an "upgrade" to my subscription. They were calling from a private number. Short of completely changing ISPs (particularly difficult to do in my area) or going through legal channels, there was nothing I can do to protect myself from the spam attack. The phone system didn't let me, by design.

* In my home country, SMS spamming is beyond insane. I mean 5 to 10 daily promotional SMS. That's me paying money to get something in my pocket that vibrates to give me advertisements, 5 to 10 times a day.

Email, and online communication, are a _little bit_ better in that aspect. You usually have an inbox that you can check at your convenience. Unfortunately, even these inboxes get flooded with volumes of info you don't necessarily want in there. There's a very particular kind of spam, the one that doesn't (and shouldn't) be removed by commercial filters, that pollute our stream of info. The flooded mailing-lists mentioned in PHK's email is an example. The photo album of my dad's second cousin's niece is another one.

On top of all this, modern trend is to add "instant notifications" to your phone, so that even email (or Facebook/Twitter/your-favorite-website messages) will interrupt you several times a day.

And looking forward (a bit), it does seem that phones and emails are going to be outdated at some point. The current trend is to have these "Feeds". I distinctly remember closing my Facebook account, the day they switched the landing page from my wall to my "Feed". All of a sudden, Facebook was not a tool I use anymore, it's a data stream I consume.

I guess what I'm trying to say is that unsolicited interruptions irritate me. They irritate everyone when done physically. To me a phone ring is equivalent to someone poking me on the shoulder when I'm in the middle of something.

I had never read the Bikeshed email, although I was familiar with the story. I always heard it in the context of project management "we didn't deliver on time because we lost our time bikeshedding". It's actually about spamming and unsolicited communication. Don't pollute my stream of info.

And get off my lawn.

babarock··on Koding - Free VMs for online development
I know what I'm going to use it for.

I work on an open source project and I've just submitted a patch. Tomorrow, I'm travelling to go spend a week with my parents, away from home. I don't plan on taking my laptop with me, but I want to follow up on my patch. Reviews are probably going to ask for minor changes.

Basically, I can see myself using something like this when I'm on the move. I'm not a big fan of dragging my laptop with me everywhere I go...

babarock··on I cannot afford to go back to engineering school
She's not complaining or asking to be handheld. She's warning her fellow students that working to make money will impact the ability to pay for school.

It's counter intuitive. It's not obvious at all. It's barely mentioned or talked about. It can cost (and it did cost her) a college degree.

I don't disagree with the sentiment of your remark, but it's completely out of place here. She's simply warning others not to do the same mistake, since it's an easy one to make.

babarock··on GitHub and my open source life
I'm a huge fan of Github. I recognize the huge effect they've had, transforming the Open Source community, and I'm grateful for it. I also love how they run their company, how open and talkative they are about their organization. Their blog holds many gems.

However, I cannot work on Github. In my opinion, the Pull-Request mechanism is weak because it fails to address a major point: It's highly improbable that I accept the PR on the first try. There's going to be a lot of back and forth discussion, reviews, remarks, etc.

Standard PRs I deal with on Github usually end up with several redundant commits. When I ask people politely to rebase all the commits they're sending into one, most don't know how to do it. (It's okay not to know. It's weird when someone with several contributions per day never had to do it before). If I `git commit --amend`, my PR is actually overwritten and I lose the history of the first patch I've sent.

I started disliking working with Github ever since I started working on OpenStack. The process to send a patch there might seem a bit daunting at first, but it's really not that complicated. Using Gerrit (https://code.google.com/p/gerrit/) for code review has many advantage, like limiting your patch to one commit, keeping a detailed log history of successive patch sets, and generally making reviewing more inviting. On top of that, the whole suite of tests is ran against each submitted patch in a virtually never resting CI server.

And finally, I don't find Github's Pull Request that "easy, simple and fast". My workflow with OpenStack is a lot faster. 1 command:

    $ git review
A colleague of mine says it a lot better than I do: http://julien.danjou.info/blog/2013/rant-about-github-pull-r...

If I recall correctly, Linus Torvalds went on a highly publicized rant against Github PRs not that long ago.

I'm not arguing that every Open Source project should have a complete QA infrastructure, and Github is a great place to deal with your first Pull Requests. However, I do argue that you can very quickly reach the limit of what Github can give to you in terms of collaborative tools.

My rule of thumb: If you have more than 10 contributors, at least 4 of which are active daily, it may be worth it to invest in some real infrastructure.

babarock··on Founder of Tor Freedom Hosting arrested in Ireland, awaiting extradition to USA
Maybe I wasn't clear enough. I wasn't exactly asking about child pornography prosecution (which quite frankly, I know nothing about and am probably the least qualified person on Earth to have an opinion about), but about its automatic mention every time "online crimes" are mentioned.

I mean, I've been practically living online for too many years, stumbled upon some dark corners of the web and I can honestly say that I never came across CP (I mean inadvertently. I never actually targeted anything like that, so I don't know how easy it is to find if you actually want to. And I wish I could try it out to validate my claims, but the whole paranoia about the subject makes me afraid of having "underage porn images" in my search history).

My point is that if you listen to politicians, you'd think that the Web is ridden with kids exploited for porn. I can think of so many crimes I come across quasi-daily on the web: Credit card fraud, identity theft, copyright infringement, banking scams, stalking, harassment, ... I suspect, although I don't have the data to back it up, that these are more prevalent by several orders of magnitude, yet in our collective mind: "online crime == child pornography".

I honestly didn't mean to start a debate whether we should or should not prosecute offenders and how. I just find it weird that we mention it so much, and the slightly paranoid conspiracy-theory-loving voice in my head can't help but think that someone is spreading deliberate FUD by amplifying actual events.

babarock··on Founder of Tor Freedom Hosting arrested in Ireland, awaiting extradition to USA
Slightly off-topic, but I never understood the obsession of legal enforcement with child pornography. Don't get me wrong, the idea of pre-pubescent children being exploited by pornographers horrifies me as much as anyone, but it always felt so ... random.

Maybe I'm wrong and the problem is a lot more widespread that I think it is, but I think that there are so many more crimes committed online. Yet, almost every time some morally righteous politician talks about regulating the Internet, he or she mentions "Child Pornography". I can see how the words would have the desired effect in a political speech, but is it really THAT common a problem?

Where did that come from? Call me paranoid, but it feels like this term came out of an orchestrated propaganda campaign to scare uptight puritan Americans from the Evils of the Internet, similar to the propaganda movies we can see about marijuana in the sixties.[1]

    > The court also heard that a search of Mr Marques's computer revealed he had made inquires about how to get a visa and entry into Russia.
And it's valid to consider this suspicious? I've queried how to get entry into Russia before, I hope that didn't trigger any kind of alarm.

[1]: http://www.youtube.com/watch?v=-bm2koyUqmU

babarock··on 35h work week fading as the average full-time work week in France nears 40h
I never counted the hours I spend at my job. Not once. Lucky for me, probably, neither does my employer. I'm paid to get the job done, not to show my face at the office for a certain amount of time per week.

Some weeks are more intense than others. It happens, so what? I'll put in the extra effort, and get the job done. It helps staying motivated when the bosses are putting in the extra hours with you.

The opposite of what you call "Americanesque slavery system" is this, oh-so-common system in France, where people have no passion for their job, care only about the salary and picture quality time only "outside" of work.

I spend too much time working to not care. If my job wasn't fulfilling I wouldn't be doing it.

Disclaimer: I'm in my twenties with no family to feed, no financial debt and generally very little financial responsibilities. I don't know how long I can afford demanding having an interesting job.

← PreviousPage 4 of 11Next →