HNHacker News
TopNewBestAskShowJobs

compay

1,997 karma · joined July 18, 2008

I program, mostly for the web and mostly with Ruby and Lua.

Me: http://njclarke.com

My code: http://github.com/norman

My blatherings: http://twitter.com/compay

[ my public key: https://keybase.io/compay; my proof: https://keybase.io/compay/sigs/5ghM6xDeYY3U9odHk-2BOd7DxA9AIP5-QcWBkrTOgSQ ]

submissionscomments
compay··on Ruby 2.0 Refinements in Practice
Veto, no, but obviously the JRuby team are well worth listening to. Charles's post isn't really saying that refinements are a bad idea, but rather offering some, well, "refinements" to how he thinks they should be implemented.

It's taken a long time to get Ruby's performance up to the respectable levels it finally achieves with 1.9 and JRuby, so I'm glad to see Charles pushing to avoid letting features creep in which could seriously degrade it.

compay··on Ask HN: Help, I need to talk in front of a big audience & I'm scared, what now?
I'm also an inexperienced public speaker, and have decided to improve as much as I can. A few weeks ago I gave a talk at a conference in front of about 350 people, following this advice exactly. I still have a long way to go but the talk went well, and a lot of people came up to me afterwards and congratulated me. During the talk I was a little nervous, but not as bad as I would have thought.

So first and foremost, follow this advice - it's 100% correct!

compay··on Steve Klabnik Quits Job to Work on Hackety Hack
"Do what you love and the money will follow" -my Mom

Best of luck Steve. Props to you for living the life you want to lead. Now that's a great way to inspire children in and of itself.

compay··on TextMate finally gets an update
And, as of 7.3, Lua.
compay··on Meet The Team
Yeah, what lucasjung said.

A "negative transfer" is when you apply habits from one language to another and make usage choices that are not necessarily errors, but sound awkward to native speakers. It's not so much a translation thing as it is a non-native speaker thing.

compay··on Meet The Team
Yeah, some of them (like the ones before "that" and "when") are a negative transfer from German. Trivial to fix though, and something tells me they will. Definitely a beautifully put-together page.
compay··on Things in MySQL that won't work as expected
That depends on how and when you're going to use it. It's fine with small data sets, or if you're going to run the query and cache its output periodically. With MySQL you can also speed it up quite a bit by selecting only an indexed column rather than `SELECT *`.

But yeah, if it's in a query that you're going to run on every single hit to the index page of a busy site, then you're going to have problems.

compay··on Things in MySQL that won't work as expected
Most of the things listed there are not MySQL specific. Here's one that I'm pretty sure is:

SELECT * FROM example WHERE value = 'á';

where "á" uses UTF-8 encoding.

By default this will return rows that match both "á" AND "a", which may or may not be what you want.

If you want to make MySQL distinguish between an "a" with an accent and one without, then you need to specify a collation either in the table creation/alter statement, or in your query directly:

SELECT * example WHERE value = 'á' COLLATE utf8_bin;

compay··on Need a name for your startup? I wrote a domain name generator in Node.JS
Let me add my voice to the chorus: great job! This is the best domain name generator site I've seen yet.
compay··on Now that you have turned 22 can I please give you some advice...
I remember reading a few times in interviews with people that knew him, that Hendrix basically never put the guitar down. I think in the sense the author is trying to convey, he "never worked hard" and "it just flowed" because he must have truly loved what he did, and he was doing something that he had a gift for. But from what I have read, he dedicated a lot of time to practicing.
compay··on A Short, Simple Introduction to Information Theory
If you're looking for a good read, I enjoyed Jeremy Campbell's "Grammatical Man" quite a bit, it ties together information theory and linguistics. Obviously not the most in-depth book on either topic, but fascinating nonetheless.

http://www.amazon.com/Grammatical-Man-Information-Entropy-La...

compay··on Can I Make My Developers Write Efficient Code by Giving Them Slower Machine?
Having a slow machine available to test your code on is a nice option, but I'd be very annoyed if I was forced to use it as my development environment.

Then again, it depends on what you're doing. I have a pretty slow netbook that I use when I travel. Working in Ruby or Java can be painful, but working in Lua feels exactly the same as on my Macbook Pro.

compay··on Developer Joe Hewitt Tears Into Android’s Definition Of “Open”
"Open source" != "open project." This issue comes up every so often on the Lua list, and I think Roberto Ierusalimschy's explanation describes the situation with Android pretty well.

http://lua-users.org/lists/lua-l/2008-06/msg00407.html

compay··on Taking Uncle Bob to school
The article has some interesting critiques. But really, anybody's code can be improved, particular if you're willing to spend more than half your time nitpicking about style and formatting details. Writing an article taking a famous programmer to the woodshed just makes it seem like you're whoring for traffic.

> Usually what people struggle with initially is adapting to the functional paradigmes, which Uncle Bob seems to have gotten right in the first try!

Having heard the man speak, I really don't think this is Uncle Bob's first trip around the block with Lisp - even if he is relatively new to Clojure.

compay··on Git info in your ZSH Prompt
Nope, me too. I can see maybe using a prompt like this temporarily, or putting this info in an XTerm's title, but I spend most of my time on the command line and really don't want crap like this distracting me.

My prompt on localhost is always "$ " or "# ", but I add user and host on remote machines to avoid making any big mistakes on the servers I manage.

compay··on 2010 Nobel Prize in Literature Awarded to Mario Vargas Llosa
I enjoyed some of his books, but pop fiction is unlikely to win that award any time soon. :) And no, Paulo != Pablo, but it's an axiom that if a Brazilian becomes popular enough in the Spanish-speaking part of Latin America, he or she will eventually acquire a hispanicized nickname.
compay··on 2010 Nobel Prize in Literature Awarded to Mario Vargas Llosa
> whom time has failed to vindicate.

Yet.

compay··on How Fake Money Saved Brazil
Exactly - Brazil's history and relationship with Portugal bear little resemblance to the USA's relationship with the UK. Brazilians in general are, if not proud, then at least amused by their country's royal history, and most major Brazilian cities have streets named after famous royals.

http://en.wikipedia.org/wiki/History_of_the_Empire_of_Brazil...

compay··on DRM done right: Puppygames
"DRM done right" is an oxymoron.
compay··on Uncle Bob: The Hacker, The Novice, The Artist, and The Craftsman
Thanks - that definitely qualifies as "something obvious" that I missed.
compay··on Uncle Bob: The Hacker, The Novice, The Artist, and The Craftsman
I've seen Uncle Bob speak at a few conferences and his talks are always the best of the lot. He's brilliant, knowledgable, a great presenter and also seems like a heck of a nice guy.

This is a real question though - where can I see code that he has written? What product or project has he created? Has he only worked on proprietary software, or has he made any major contributions to free projects?

I realize that free/open source software is only a part of our craft and that plenty of brilliant people out there work exclusively or almost exclusively in the closed-source world. I also realize that people can make major contributions to software by doing things other than writing code.

But because he speaks so much on how to write code, it would inspire confidence to actually read and use code he has written, look through commit messages, and actually see how the guy manages a real project.

The fact that my Google searches turn up nothing tempt me to cynicism. Somebody please point out something obvious that I have missed.

compay··on James Gosling: Why I Quit Oracle
I'm almost 38 and had my first child not too long ago. Sometimes I surprise myself at feeling tempted to chase the illusion of "stability" at a bigger company. Then I remind myself of all my friends who have been through terrible layoffs and remember that there almost never is such a thing as stability nowadays.

I think a lot of people get the same feeling I do for the same reasons, but then forget the whole "remind yourself" part.

compay··on Mongrel2 Says, "Goodbye Python"
Josh Simmons, one of the main Mongrel2 hackers other than Zed, is already working on that.

The idea behind Mongrel2 is that you can write your own configuration system in any language you want, as long as the final result is an SQLite3 database. The one in C that ships with Mongrel2 is "just" a default - if you don't like it, it's not hard to roll your own.

Here's an early peek Josh's Lua config tool, and a sample config file: http://gist.github.com/578726

compay··on Coming Home to Vim
Nope. It's one of the biggest complaints about Textmate, and one of the things that led me to (mostly) switch to vim.

A lot of people are pretty upset with the author because rather than choosing to release an incremental update that adds smaller features like this, he decided on a total rewrite and got bogged down with no release in sight.

That said, Textmate still feels remarkably current despite the fact that its last major update was more than 4 years ago.

compay··on [dead]
"Compatibility mode to view websites designed for older browsers" has IE9 checked, but not FF or Chrome.

I was about to say something snarky but I think this just speaks for itself.

compay··on Phusion Passenger 3.0 Public Beta 1 is out
I doubt it. But I suppose somebody could potentially build a product around Mongrel2 which does.
compay··on Linus Torvalds became US citizen
No, the USA does not require that.
compay··on Duke Nukem Forever.. is back on.
Textmate 2?
compay··on Bribing maitre d' to skip the line
> I see it as a type of scam against the employer, though.

That's definitely sometimes true. But it depends - when I was in college I used to go to a bar (Redbones in Somerville, MA) where the owner had a policy of letting the bartenders offer a certain number of free drinks and appetizers to favored customers at their discretion. He did this because he said it meant more loyal customers, which helped both him and his employees. I definitely spent a lot of money in that bar and always tipped heavily because of the great service. Despite all the freebies I got, I'm sure they turned a well-deserved profit off my business.

compay··on Android Fork Brings Froyo To 12 Smartphones
Well, AFAIK Cyanogenmod is the only way to run Froyo on the G1.
← PreviousPage 6 of 16Next →