03 Nov

GMane.Comp.Version-Control.Git – Linus Torvalds on C and C++

On Wed, 5 Sep 2007, Dmitry Kakurin wrote:
>
> When I first looked at Git source code two things struck me as odd:
> 1. Pure C as opposed to C++. No idea why. Please don’t talk about portability,
> it’s BS.

*YOU* are full of bullshit.

C++ is a horrible language. It’s made more horrible by the fact that a lot of substandard programmers use it, to the point where it’s much much easier to generate total and utter crap with it. Quite frankly, even if the choice of C were to do *nothing* but keep the C++ programmers out, that in itself would be a huge reason to use C.

via GMane.Comp.Version-Control.Git – Linus Torvalds on C and C++. Programmers are an opinionated bunch.

06 Oct

Seldo.Com Blog – PHP needs to die. What will replace it?

Ten years later, I can feel the tide turning again. Developers’ expectations of languages have moved on. If the critical thing Perl was lacking was PHP’s wonderfully flexible "associative arrays" (aka smart hashes), then what PHP is lacking is lambdas and method chaining. While PHP used to be the language where you could write a web page in twenty lines of code, nowadays it doesn’t feel like you’re doing it properly unless you’ve laid down at least a basic MVC framework of some kind. That boilerplate code is the tell: the language now requires modification by a framework to do what you need.

Back then, I felt the die-hards clinging to Perl for web development were silly. Now, with ten years of PHP experience under my belt, I’m in the same position. I can knock out a good website in an hour in PHP, and an excellent one in a day or two. Its performance characteristics are well-known and understood, so I can make it scale pretty much indefinitely. Every developer we’d want to hire knows it, and every system we’d integrate with has a wrapper library written in it. I am trapped by the convenience of PHP in a language that is losing its suitability for the task.

via Seldo.Com Blog – PHP needs to die. What will replace it?. I know what he’s talking about PHP is a language that at times shows it’s age and is ridiculed by people on the latest and greatest (Node.js/Ruby on Rails/etc). That being said PHP has some advantages that anytime soon are going to be hard to meet in terms of ease of deployment (name a shared hosts that doesn’t have PHP on it), tools and frameworks (WordPress, CakePHP, etc). I use PHP for my day job every day and will probably still be using it years from now, but there are times I wish the language itself was more modern. For a great overview of issues with PHP from a language design standpoint Hypercritical Episode 17 goes into some of the problems.

15 Jul

Mark Story – My thoughts on the built-in php server

Earlier today I saw the announcement that PHP5.4 will have a built-in web server . I mentioned on twitter that I wasn’t too happy about the server being added. In the discussion that followed, I feel like I wasn’t able to properly convey my thoughts through tweets. I figured I might be able to better explain myself in a post.

I have mixed feelings about the built-in web server to be honest. Having a low effort web server is great for lowering the barrier to entry when building things with PHP. I can also appreciate the instantaneous feedback you get from a simple command line server, and not needing to fiddle with Apache or other more complex web servers. All of these things seem really great in isolation, and when you ignore some of the problems that it creates.

I can think of a few problems that the new command line server creates. First, while its intended for quick and dirty development, it will invariably end up being used as a production server somewhere. PHP already has a spotty track record with providing features meant to be helpful, but later become painful. I’m thinking of things like magic quotes and register globals. All of these features were at some level intended to make development easier. Instead they have become huge headaches, and are only now being removed.

via Mark Story – My thoughts on the built-in php server. I think he reached into my brain and said exactly what I was thinking.

23 Feb

najafali.com – Why PHP is better than Ruby

PHP is better than ruby. There, I said it. In this article I’m going to show you why, and probably upset some twenty-something, flip-flop clad, mac-using hippie fanboys in the process.

via najafali.com – Why PHP is better than Ruby. Overall these are very intelligent and reasonable complaints against Ruby.

Update: I didn’t get the sarcasm in the article and yeah it was a pro-Ruby article.

22 Feb

Andrew Vos’s Blog – Amount of profanity in git commit messages per programming language

Last weekend I really needed to write some code. Any code. I ended up ripping just under a million commit message from GitHub.

The plan was to find out how much profanity I could find in commit messages, and then show the stats by language. These are my findings:

via Andrew Vos’s Blog – Amount of profanity in git commit messages per programming language. How both fascinating and funny.

24 Feb

Accent Folding for Auto-Complete – A List Apart

Accent Folding takes your application and lets it understand that cafe and café are the same word. It goes beyond just a mere language translation that most applications already have in place. It’s possible but be warned.

Be aware that there are a million caveats to accent rules. You will almost certainly get it wrong for somebody, somewhere. Nearly every alphabet has a few extra-special marks that do affect meaning, and, of course, non-Western alphabets have completely different rules.

via A List Apart: Articles: Accent Folding for Auto-Complete.

02 Jan

Why Java Is Not As Fast As C

Thanks to Hacker News for the link to a mailing list on Java Git vs. pure C Git:

So. Yes, its practical to build Git in a higher level language, but you just can’t get the same performance, or tight memory utilization, that C Git gets. That’s what that higher level language abstraction costs you. But, JGit performs reasonably well; well enough that we use internally at Google as a git server.

I’ll add that while I understand and realize that PHP is a slower language than others the time to build an application for me is more important most often than the computation time of the program. In the same sense that even Google recognizes that JGit is slower then C Git, it’s not enough of a difference to matter, most often the speed difference doesn’t really matter when it’s so easy and cheap to throw hardware at the problem.

03 Aug

Do Words Actually Matter?

The question is almost stupid to answer because on certain level they must matter or else I wouldn’t publish my thoughts. So words must matter to you because well you are reading this and you most likely communicate with society. There is a very good reason that being deaf and/or mute is an impediment to having a normal life. Communication is the lifeblood of society, at some level we all need to communicate for a host of reasons.

So words matter to the extent that one needs them to communicate with others in society, but on a deeper level do words really matter?

Hmmm, okay, well I am trying to convince you of certain position, so I must feel that words matter in the sense that the meaning of the words strung together can form a hopefully coherent argument that sways you to accept part or all of my position. But again we aren’t quite at the heart of the matter of do words matter.

Well let me first clarify the question a little bit, by do words matter, I mean do the words that we speak do they make a difference on our lives. In other words if someone insults you, does that hurt your feelings?

It’s an interesting problem, mainly because we all know that words matter because we use them all the time to communicate, to debate, to show emotion, a host of things only happen because of words.

Imagine trying to tell someone that you love them, without being able to talk to them. Just try to see how to express that emotion without the words to go along with it. Sure you can buy them gifts, give them your time, make love to them, but does any of that really truly express your feelings over this person? I doubt it.

Now that I have danced around the issue enough, let me just answer the question. Words don’t matter it’s the intent and the feeling behind the words that really matter.

Words themselves I believe have no power in and of themselves, it’s the emotion and purpose behind the words that give words power. Words are just that words, abstract concepts strung together in a meaningful manner to describe something. Imagine a beautiful poem, but being read in a monotone voice:

A VALEDICTION FORBIDDING MOURNING.
by John Donne

AS virtuous men pass mildly away,
And whisper to their souls to go,
Whilst some of their sad friends do say,
“Now his breath goes,” and some say, “No.”

So let us melt, and make no noise,
No tear-floods, nor sigh-tempests move ;
‘Twere profanation of our joys
To tell the laity our love.

Moving of th’ earth brings harms and fears ;
Men reckon what it did, and meant ;
But trepidation of the spheres,
Though greater far, is innocent.

Dull sublunary lovers’ love
—Whose soul is sense—cannot admit
Of absence, ’cause it doth remove
The thing which elemented it.

But we by a love so much refined,
That ourselves know not what it is,
Inter-assurèd of the mind,
Care less, eyes, lips and hands to miss.

Our two souls therefore, which are one,
Though I must go, endure not yet
A breach, but an expansion,
Like gold to aery thinness beat.

If they be two, they are two so
As stiff twin compasses are two ;
Thy soul, the fix’d foot, makes no show
To move, but doth, if th’ other do.

And though it in the centre sit,
Yet, when the other far doth roam,
It leans, and hearkens after it,
And grows erect, as that comes home.

Such wilt thou be to me, who must,
Like th’ other foot, obliquely run ;
Thy firmness makes my circle just,
And makes me end where I begun.

Now reread the poem, but this time give it emotion. It makes all the difference in the world. Words themselves are basically worthless, but words with emotion and feeling are indeed very powerful.

* Just on a side note, I absolutely love this poem, hence I used it.