Hacker News new | past | comments | ask | show | jobs | submit login
What It's Like To Be Ridiculed For Open Sourcing A Project (harthur.wordpress.com)
1331 points by luigi on Jan 24, 2013 | hide | past | favorite | 781 comments



What the fuck. (And I rarely say that word.)

We've got to grow up. This is 9th grade all over again. You know, those weird people that do things that you don't understand? They're the ones that grow up and make big impacts on the world.

Why can't we get over our negativity? We can't stop ourselves from thinking horrible things, or even saying them out loud to people around us, but surely we can restrain ourselves from publicly humiliating someone in front of thousands (or more) people. And for what purpose? To say "funny" things like "our eyes are bleeding!". Seriously?

I really will never understand why people can't simply be more positive. If I ever start a company the #1 thing I will look for in others is positivity. I wouldn't stand for this crap.


>> If I ever start a company the #1 thing I will look for in others is positivity. I wouldn't stand for this crap.

What's conspicuously lacking here is not positivity per se, it's the absence of civility & decency. Those are two very different sets of attributes.

Lack of an outright positive demeanor won't sink a team. Lacking civility and decency, however, will stick a severe wrench in any project.

edit : On a personal note, reading this was unpleasant and embarrassing. I'm sorry the OP had to go through this.

edit 2 : retracting the following statement after reading apologies published by those involved - "I'm glad I now know who not to interact with in the community"


I guess you're right. Civility also sounds less cheesy than positivity! I find that teams can be balanced with people positive and negative, and it's how you handle negativity that's important, which is what you point out.


Corey Haines wrote a thoughtful apology here: http://programmingtour.blogspot.com/2013/01/im-sorry.html

Only one of the three to do so thus far.


David Cramer just doesn't get it:

https://twitter.com/zeeg/status/294307568019464192

https://twitter.com/zeeg/status/294306974248607745

All that despite confessing that he doesn't understand why the project was written:

https://twitter.com/zeeg/status/293829856381255681


Clearly. He also wrote:

"Are you mad that the Internet disagrees with you? Maybe get off the Internet?"

https://twitter.com/zeeg/status/294305445521268736

He's now gotten off the Internet because he's upset. Ironic.


Nope, still here.

I'm just not replying to you on Twitter because lol


Don't expect you to - you read it, good enough for me to know you did :-) Thanks for letting me know.

Your entire blog post is a big "The Internet disagrees with me":

http://justcramer.com/2013/01/24/being-wrong-on-the-internet...

You said something in 140 characters that was snarky and mean, that's actually not easy to do to be honest. And then you got called on it, and now you are getting criticized. Not nice, huh?


Actually, you know something... I correct myself. It is easier than I realised. I'm not sure that would be a skill I'd be proud of...


The internet doesn't disagree with him, a vocal minority of hyper sensitive cry babies and desperate white knights disagree with him. Very few people who don't care take the time to say "who cares?".


They care that you care? Why can't they not care that you care? Or is it the fact that they don't care that you care? Yet in that case then how can those who take the time to say "who cares?" say they don't care when they seem to care enough to ask who cares?

This is all very confusing.


Why is you confusing yourself posted as a response to me? You can mutter random nonsense to yourself offline, I don't need to be involved.


I take it from your response that you are the few who cares enough to say "who cares"? You sound a bit sensitive...


All you should take from my response is that I don't know why you replied with random nonsense.


A bit hyper-sensitive are we? That's the end of the thread from me though, my absurdist questions should have told you everything you need to know about my opinion of your horrid attitudes. Have a nice day: I fart in your general direction.


Classy. None of the "I am sorry if you were offended bullshit" just a sincere "I messed up". Take note, just about everyone else.


I agree. Everyone makes mistakes at some point and that apology seems to be the best possible way to deal with it IMHO.


Steve Klabnik has now also posted an apology http://blog.steveklabnik.com/posts/2013-01-23-node


And unfortunately it is exactly the "I am sorry if you were offended" type.


I don't think it is. I think its the 3rd kind: "I didnt say what I thought you said, but I can see how I hurt you and I'm sorry". Assuming that's true - which I think is a reasonable assumption based on how he teaches and his blog post from last year about being nice - it would seem wrong for him to post a full out apology.


no it's definitely a "I'm sorry for offending you, but seriously fuck you for using node."


He definitely said that in the later tweets. Maybe you're right - its definitely less of an apology than his comments merited.


Super relieved to see that - I was seriously disappointed to see Corey's name in amongst the mob. That's how an apology should be written.


I just looked at his twitter feed, and he has a lot of "I made a mistake" posts. What he did was bad, but at least he is not trying to minimize it. And this thread getting to the top of Hacker News will probably teach him a lesson.


I somehow feel the "Twitter culture" itself is partially to blame. A setting that rewards short, sharp, witty remarks that skirt over the surface is just few small steps away from endorsing sarcastic, bitter, passive-aggressive or even over-the-top spurts.

It's no wonder that no one who made those stingy tweets did respond to author's replies and questions. They didn't want to start a discussion in the first place.

Fortunately, the pendulum can also swing the other way here, as they are people who readily jump to defend against harassment.


I like his earlier writing too, on dealing with "open source assholes": http://harthur.wordpress.com/2011/06/30/dealing-with-not-dea...


(her)


Yep, my bad. The 'arthur' part of the url must've messed my brain up.


A good test of character is how one treats those that they perceive to be lower status than them.

I'd say these guys fail that test.


It might be better to say that they failed last night and leave a more general judgment open.

It's a good thing that people are calling this out and giving the participants cause to reflect on the problems with that kind of conversation (along with the rest of us). But I think it's also good if we don't rush to reduce people to some of their meaner moments. A lot of the participants have done a number of good things in the past, and they may well apologize and make this the exception rather than the rule.


I was being pithy. I don't mean to suggest that they're awful people.

I think in the open source community there's an ugly culture of celebrating people that act like jerks about technical things that reasonable people could disagree on (the poster child of that probably being Linus). I don't think that's a useful culture to have around. I think the best way to get rid of that culture is to make clear that those people can go fuck themselves. Just because you can be a dick doesn't mean you should, and the community should reflect that.

I'm not the positivity police, I don't think people should be nice just for the sake of being nice, but there's no reason to go pick on someone's project just because it does something you'd rather do with another tool.



So you ascribe personal, leveled, directed malevolence directly against Heather Arthur and her replacer library to their actions? You don't think it had anything to do with just doing it for kicks, anything to do with how people see Node?


I wouldn't be at all surprised if there was a strong undercurrent of misogyny involved here, motivating their incivility and rudeness.


I'm quite skeptical of this. It's not like her gender is immediately obvious from the GitHub repo, and it seems obvious that if these guys recognized the screen name they wouldn't have been foolish enough to make these comments about an engineer at Mozilla.


Accusing everybody criticizing a woman of sexism is certainly not helping. They almost certainly didn't know she is a woman. Moreover Steve Klabnik at least is a widely known ally (http://confreaks.com/videos/1089-madisonruby2012-anti-opress...)


"Accusing everybody criticizing a woman of sexism is certainly not helping."

It's not that they're criticizing a woman, it's ~how~ they go about it.


It is fundamentally impossible to provide enough evidence or preemptive apologies to find redemption once someone starts playing the Identity Victim card. Don't even bother.


It's the reverse - a lack of civility among those alpha-nerd types leads to the general acceptance of misogyny (and racism, for that matter) among them.


They both feed into each other.


I don't want to be the one to say it, but it hasn't yet been mentioned in this thread.

If the author was named Henry instead of Heather, this wouldn't make front page or have a comment thread full of white knights.

That doesn't make the critics right in their aggressiveness, and people overall should be nicer.


You have absolutely no way of knowing that this post would not make the front page if the 'H' was for Henry.

That sentiment is a huge pet peeve of mine. Forget the gender of harthur, and look at what's left: someone writes a tool that's useful for them, and thought it would be useful for others (and, based on other comments, clearly it's agreed that it is for some). At least three people publicly take a shit all over said tool because, you know, lolol. Those three people have now been called out, and rightly so.

I don't think those three have been called out because Heather is a woman. I think they've been called out because others can see themselves in Heather's place. I know if I published something I wrote, just a small convenient script I had lying around, I wouldn't feel too good to see it attacked in public. Genuine sympathy can be extended to anyone.


"If the author was named Henry instead of Heather"

I'm going to have to strongly disagree, I honestly didn't know the author was a girl until I saw the name, well after I had read comments and was intrigued overall with the topic. I think the jump to misogyny or gender bias is a bit premature, but I can't really offer up much evidence other then my own perceptions and interpretations of what I've read.

Simply put, the topic is really interesting in itself and hasn't really been discussed much on HN in this specific way, unless I've missed some previous threads. I think add the fact that the negative comments were from some decently well known people, which all responded to it as well, and I think you have all the explanation you need for it being a popular post outside of any sort of need to resort to guys going to to a girls defence explanation.


"have a comment thread full of white knights"

You're seriously suggesting that anyone here who decries the rude behaviour described in the blog post, is doing so just to impress the protagonist of this drama with their chivalry? What an absurd notion.


Using the phrase "white knights" as a gender-based insult for people sticking up to bully-behavior is pretty unnecessary and reflects poorly on you. There's no need to bully the bullied further because you feel some sort of nonexistent imbalance.


If the author was named Henry, the probability that this post would have been written would be far lower. For better or for worse.


Perhaps you are correct. While I completely agree that what happened to her was completely uncalled for regardless of her gender. I find that sometimes myself I am slightly harsher in criticism of my male colleagues and friends. Perhaps dcramer and steveklabnik didn't realize they were addressing the project of a female programmer? Nonetheless, their rudeness is still wrong especially in the public sphere.


I seriously doubt it was misogyny as much as it's just online disinhibition. Twitter is especially notorious because the very format forces you to be curt.


The majority of HN readers seem to have assumed that the author is male. I assumed the same thing for most of it, before getting suspicious at the non-joking use of "sobbing". I wouldn't be surprised if these Twitter posters made the same assumption.


The thing that bothers me is that some people changed their tone after they found out she was a woman and after they read her post. This speaks volumes more than the original comments. If anything it seems there's an implication that somehow women are unable to cope with jackasses as well as men.

Would it have even made HN at all if she was a man and wrote the same way? I doubt it, but if it did, and she was a he, he would have been pounded to the ground in the comments.

Of course, all of this could have been avoided if people act the way they're expected face-to-face. None of these people considered the "person" who wrote the code. And none of them considered "not useful for me" != "not useful". If it was, why are there so many tools out there besides UNIX?

BTW... Twitter's short form is a lame cop out IMO. You can be curt and still not be condescending. Allegedly "smart" people could have been cogent without being asses.


I just wanted to point out that (hopefully) these Twitter guys were posting because they truly disliked the project, rather than out of misogyny as the GP speculates.

It bothers me too when people here and elsewhere assume every single negative comment or piece of criticism directed at a woman is due to misogyny, and that somehow women should be "no criticism zones" or something. I really like when people maintain gender anonymity online, because it keeps comments and feedback at a gender-blind level.


At this point, I blame it on the assumption that Aspergers must run rampant and is severely underdiagnosed in the dev community.


Think about this: this statement, right here, is a completely unfounded (i.e. you have no evidence about any of the 3 people being ASD, and the probability of all of them being ASD is really low even among geeks like us), passive-aggressive (you are attacking people with ASD but making it appear sympathetic), pseudo-intellectual (how much do you really know that you didn't read in superficial internet threads) insult (oh yes it is) toward people with ASD. Ironically, presumably from a neurotypical, who by implication is supposed to be more sensitive than the alternative.

Congratulations. You bully in a thread about bullying being bad.


Thanks for writing this. As someone who has ASD (and who thinks he is not an asshole) it always makes me cringe when someone connects being a douchebag on the internet with it. Prejudices like that makes it very hard to tell people about it when some automatically assume you're an asshole for having ASD. All kinds of people behave bad on the internet for various reasons because they can and they are emotionally detached from the people they are writing about. ASD has absolutely nothing to do with it.


Ugh, this is exactly the 'asperger pride' mentality I mention in a thread below.

You are trying to make it politically incorrect to talk about the problem of aspergers in the dev community. The parent is a bully? really? A bully? come on.

Maybe these specific people have aspergers or not, but the problem of a high concentration of socially inept people in the technology world causing strife amongst each other is a real problem.

This is a problem and it should be talked about.


I've worked with people with Asperger's and Autism in a clinical setting. I'm not talking out of my ass.


While you might not be, you're probably the exception. The typical interaction sequence is:

1. Someone is rude on the internet.

2. "Ooh, look, undiagnosed ASD, lol, most software devs are ASD."

3. Self-applause, occasionally followed by discussion about whether Asperger's is different than Autism or whether it's a spectrum disorder, occasionally someone mentions the new version of DSM. (Sometimes this really bothers someone, and then there's the meta-thing where people smirk and say that of course people with ASD don't like reclassification, etc, etc. It's so tiresome.)

I think this may well be a worthy successor to Godwin's law.


It's not just rudeness that triggers this response -- it's when someone displays a severe doesn't get it moment. The most significant moment on HN I've had of this is when someone tried to argue that sexism can't exist in tech because there's a Wikipedia page that lists 50 women with significant contributions to the field.

That sort of thing makes me wonder, if after 20-40 years of being part of our society, that is your understanding of one of the major grievances held by people out there, then there is a missing connection. You don't have to agree with the sentiment or conclusion, but if you can't even understand the complaint then you are either woefully sheltered or perhaps it's time to consider cognitive deficiencies.

And this sort of failure mode happens all the fucking time in this community.


This is exactly it.

Time and time again you see large groups of people in this community exhibiting behaviors that show that they are unaware of normal social and societal conventions, and an inability to relate and sympathize/empathize with others.


No, you see that. I see different social groups having different social conventions. The fact that you can't imagine how someone in a different social group could possibly not follow the social standards you deem correct speaks only of you, not of them.


+! on succeeding Goodwin's law with tiresome and prejudicial accusations of autism spectrum disorders (often by people who really don't understand how offensive and insulting they're being

The fondness of this community to use words like retard and retarded as insults and use implications of special needs issues as forms of abuse is disappointing given the overall level of smarts of the community. But at least that's obviously offensive. The folks trotting out autism spectrum disorders don't even seem to realize they're being just as problematic and perpetuating unhelpful stereotypes.


I understand your point, but "makes my eyes bleed" is not a typical comment from a neuro-atypical person.

The neuro-typical can be assholes too.


Neuro-typical people can be assholes, but they tend to understand that they are being an asshole when they act asshole-ish.

I think a big problem in the dev community is a lot of asshole behavior out there from people who don't intend to, or even _understand_ that they are being an asshole.

Regardless of intent, this asshole behavior has consequences on neuro-typical and atypical people alike.

I think nerdy/geeky/dev/asberger/whatever people need to be more mindful of how they interact with people. Unfortunately the recent asberger pride movement doesn't help.


> Unfortunately the recent asberger pride movement doesn't help.

The word is "Asperger's". 'Asperger pride' is an attempt to reduce the hateful ignorant bigotry that the neuro-atypical face every day. The kind of ignorance that leads to early death, reduced job opportunities, reduced educational opportunities etc.


Thanks for the correction, I got lazy there.

I think the problem with 'Asperger pride' is it tends to focus on how neuro-typical people have wronged people on the spectrum. A lot of times the painful truth is that person with aspergers is at least partially culpable for the negative outcome of their social interactions.

This becomes a major problem when you work in a place where almost everyone is on the autistic spectrum. There are no oppressive neuro-typical people, yet stubborn asshole behavior skyrockets because all the nerds are being dicks to each other.


I don't know your workmates, but if I had to hazard a guess I would suggest that this is probably more a function of being in a highly male dominated environment rather than your co-workers actually having autistic traits.

If somebody is being a dick because they are hunting for a specific reaction from the other person that is not really Asperger behaviour.


"I understand your point, but "makes my eyes bleed" is not a typical comment from a neuro-atypical person."

Why not, out of curiosity?



OK, everyone, enough with this. Really.


I think it's autism that must run rampant and that it's underdiagnosed partly because people have called it Asperger's which doesn't seem as serious. With the new version of the DSM this won't happen as often.


There is a huge gulf between Asperger's and full blown autism.

People with Aspergers are "normal" people in the sense that they are generally capable of looking after themselves, communicating and working normal jobs etc

People will full Autism have severely limited communication skills (often no spoken or written language skills at all beyond repeating a handful of phrases) and require a significant amount of assistance in most areas of life. They will often live with full time carers.


There are still people that fall under the high-functioning category that have a hard time taking care of themselves and holding down jobs. Just because you check some boxes doesn't mean you check them all, and I'm glad the DSM is removing a term that tries to generalize a subset.


I agree, but the level of care required for an "aspie" vs that for somebody with severe autism is night and day.


I thought Asperger's was being removed from the new DSM, so it's all autism now?


Not sure of the new terminology but these are 2 conditions that vary not just quantitatively but qualitatively.

The term Autism as it is used today suggests severely delayed language development. This is not a symptom of Asperger's and sufferers of the latter can often develop advanced language skills.


No one taught middle school kids how to deal with emotions.

That's because the adults around them don't know how to deal with them.

We are educated in a math & science heavy society. That's good. However, it puts the focus on evidence. Emotions don't leave much of a trace unless you act on it. So we use behavior resulting from emotion as evidence of reality and ignore the experience of reality.

Then we say, "be real" and cut off an entire spectrum of reality -- that of experiencing emotions.

These are the makings of the shadow side, the Jungian shadows. When you disown or suppress experiences, then they get stronger.

So yes. We have not grown up because we don't know how. Or at least, no one told you how.

You cannot "get over" negativity. That's a form of rejecting something you don't want to feel. The only way out is to accept the experience of it as is, without rationalizing it and without acting on it. That's probably the hardest thing you will ever do in your life, but the most important if you want to grow as a person.

There are several methods by which one can do this. One of them, called vipassana, was taught to some prisoners with great results (http://www.dhammabrothers.com/). However, you don't need to be a criminal to use this.


Serious question to you and any offended people here: what do you think of sites like The Daily WTF? Is it an anathema to any civilized person and the owners should be ashamed of themselves and apologize? After all there are real people behind every TDWTF story and if - god forbid - someday they stumble upon it they may recognize themselves and their feelings will be hurt!

Or is the whole point here that Github accounts are not (necessarily at least, as in this case) anonymous and as long as no individual is identified personally we can all share a chuckle at their crappy code?


Folks on internet fail to understand that there are people on the other side of terminal and some civility is warranted. All of us should discourage uncivil behavior by non-participating in a silly conversation.


> If I ever start a company the #1 thing I will look for in others is positivity.

Good luck with ever hearing about any problem before it's too late to fix it then...


Now hold on... you can, in fact, raise issues in a positive way.

"Hey Larry, after I spoke yesterday I checked and we've got corruption on our RAID array... I think I can work towards resolving it, but if not then we need to come up with a mitigation plan."

vs.

"Larry, we've got corruption on our RAID array. I told you yesterday and you didn't work fast enough on my suggestions, so now we're all screwed. I can't believe your stupidity!"


Sure you can, but I suspect that if positivity is the #1 priority, you're pretty likely to see issues ignored or hand-waved away.


No more so than if you were extremely negative and played the blame game. Ignoring issues is not what I'd call positive though. That's just delusion.


Being positive in the face of unrealistic deadlines is exactly that, delusion, and it's a pretty damn common and popular one in a large percentage of all software projects.

Look, I'm not saying that a positive attitude is bad, just that it definitely shouldn't be your #1 priority as proposed in the first comment I was replying to.


Fair points :-)


the hell are you talking about?

every person that created something worthwile in this world has been ridiculed. for good reason. i hate the fact that people here spout that uber positivity crap.

you know what, you mess up -> you get ridiculed, what do you do? you make something better.

The world is not this pretty flower place where everyone can be happy and strive at the same time. there is no rich without poor, and there is no great without bad.

please everyone be happy is a stupid argument to make. it actually makes people NOT improve.

it has nothing to do with elitism developer community. it's the same everywhere. you don't get patted on the back for doing something mediocore at best, well that is, unless you're an mba.


So explain to me how she messed up. Because I don't see any messing up on her part. I see a number of assholes (and some generally good folks who did mess up) unable to get out of their own headspace and into someone else, but that's about it.

And there is a large gulf between "patting on the back" and being an asshole.


I fail to see what is being wrong with being positive and happy. We should strive to make the whole world as universally happy as possible.

We can improve others with constructive criticism.


Clearly you can take it too far. If somebody does something wrong, are you allowed to tell them? Even though it is going to be negative? Do you never correct your children? Do you keep people on who need to be fired?


There's a rather large difference in saying "what you've done is not only useless, it's so stupid it's making physically ill" and providing constructive criticism

It's the shit sandwich approach, say something good, say something critical, say something good.

Tearing someone down, just because you can is not productive. I wonder if these same tweeters would have said the same thing to this persons face, and then turned their backs and walked away.


Then I see these people’s follower count, and I sob harder. I can’t help but think of potential future employers that are no longer potential.

There's a big responsibility that comes with being well-liked and nice. When someone with a good reputation and the means to broadcast it speaks negatively about someone, it matters much more than someone who is routinely rude, frequently negative, or unknown. I know that if the most well-liked and nice person in my lab were to criticize my ability as a scientist (in the same manner), I would worry about what everyone else thought about me now, that someone who never seems to say mean things would so something like that.

These individuals do good things: they contribute voluntarily to communities, they help high school kids learn to code, etc. And these individuals are visible. And if you search steveklabnik on HN, his comments don't seem mean or negative.

It's easy to forget, and it's a little paradoxical, but when you're really nice, there's a different standard. Perhaps there shouldn't be, but it does have a different impact.


"Then I see these people’s follower count, and I sob harder. I can’t help but think of potential future employers that are no longer potential."

Speaking as a hiring manager, if I see people behaving like assholes on Twitter or mailing lists, those people go on my do-not-hire list. Yes, we are all assholes from time to time, but for some people it's a pattern of behavior. Those are not people you want to work with, no matter how smart they are.


There's a fine line between being critics (constructive) and being assholes (destructive). When hiring, be sure to differentiate the two.


No, it is a very thick line. Save for a few situations where you might question whether what you said was misconstrued, people for the most part know when they're being civil or not. "I'm just a straightforward guy", "I tell it like it is", and "I don't want to sugarcoat" are ways people justify being an asshole by acting as if they've got your best interests at heart and genuinely want to help. They damn well know how mean they're being.


A great quote I once heard is that people who claim they are just being "brutally honest" seem to be motivated by the brutality more so than the honesty.


My experience and belief is different: It's clear and obvious where the line is. People who provide constructive criticism in such a way that you can tolerate repeated critiques are strikingly different than people who are assholes under cover of providing constructive criticism.


A lot of very talented and successful people are successful. Michael Jordan, Linus Torvalds, and Albert Einstein come to mind.

If Linus Torvalds applied to work at your company, would you turn him away?


I know a guy who worked at Transmeta when Linus was there, and afterward he joked that anyone who got Linus hired should get their pay docked instead of a hiring bonus. So maybe.


If everybody who interviewed a candidate thought they were a raging asshole, then yes, I would turn them away. There are enough really smart people to hire who are not assholes. I cannot speak as to Linus, because a) I haven't met him or interacted with him and b) I don't think it's appropriate to comment on a named individual.

As an interesting point, I learned this lesson in who not to hire from Michael Schroepfer, who is now VP of Engineering at Facebook.


Fair point. Once I read the names of those involved, I was a little taken aback for this very reason. Friends I respect think quite highly of Corey, for instance.

Also worth noting, both [Steve and Corey] have published apologies on their own blogs. Both are worth reading.


Here's a link to that apology: http://programmingtour.blogspot.com/2013/01/im-sorry.html

I know Corey and don't really know too much about what happened here, so I'll only say he's one of the most positive and supportive people I know.


-1 in my regard for being a jerk. +2 for a sincere apology. A reminder that owning up to a mistake can make that mistake go away and then some.


People make mistakes all the time. If it's someone you know in person then you should probably give an apology (or vice-versa, depending on the situation). Someone has to own up because if it doesn't happen, you can end up with an ill workplace/relationship/whatever.

But the internet can be a strange place. How do you apologize to strangers? With blogs? I mean, these pieces are going around being viewed by hundreds of people. Is it really helping? I'm not sure, but, at the very least, people are trying.


Email, Google+, Facebook, Twitter? There are many ways to apologize to someone without making a public spectacle of it.


There might be something like a rule of thumb that apologies should be as visible as the insult. If someone insult someone in a conversation, say sorry. If someone insult someone in front of their boss, go back and tell that you are honestly sorry. It hurts and it is why you think before you speak.



This is bound to be an unpopular opinion, but why exactly does anyone have to apologize? He's absolutely right. Criticism comes from every corner, especially in the software world.

Your code stands for itself. Simple as that.

And I tell this to almost every programmer I work with at some point or another. If they have an emotional response to a code review, or criticism of any kind—"Code is never personal. Whatever I say about your code has nothing to do with you. All I want is for us to improve this together, and we do that by exchanging ideas."

Criticisms are never directed at people, they are never intended to be personal attacks—they are simply evaluations of quality, and we're all trying to achieve higher quality. When you put code out there, you open it up to response. If people decide that it's good, then great; if people decide that it's bad, then great! You have an opportunity to improve it. That is a godsend. It's a million times better than if you received no feedback at all.

Male, female, good coder, bad coder, I don't care who you are: if you go sob in a corner because you receive criticism, then you're not going to improve. You have to join the discussion like an adult. Cramer may have an asshole opinion here, but sometimes assholes are right. Sometimes the world is harsh, but through adversity we can become better. Deal with it.

* Update: Well, I've read up more. These criticisms were not the productive kind, and were tactless and mean. I stand by what I said, but the people in question didn't criticize right, and they deserve the vitriol being directed at them. Shame.


> Code is never personal. Whatever I say about your code has nothing to do with you.

I've heard this repeated ad nauseum (not just in this thread) and I think it's total crap. You cannot tell me that if you spend dozens of hours writing something then someone comes along and goes line by line telling you how what you wrote is an abomination that you're not going to have an emotional response.

If that's the case it has to go the other way as well. Just finish writing a new process that will save the company $30k a month? Doesn't matter. If your code doesn't have anything to do with you then it's not an accomplishment to write good code (I don't believe this).

Just to be clear, I do think code is personal but I do think people should welcome any constructive feedback, particularly the negative. Yes I feel a twinge in my ego any time someone criticizes my code, even minor stuff; but guess what? When they look at it next time they won't be able to make the same criticism, because I will have fixed it.


Of course the code we write is deeply personal. I think that what he means, however, is that the _criticism_ of code he gives is based solely on the code itself, and doesn't contain any inherent bias based on the author. He's saying "this code is crap" because of objective reasons that he (in theory) holds himself and others to as well, not because he thinks the author is a bad programmer.


People just don't work that way; at least, I don't.

Who reads code without thinking of the author? When I'm derailed by a bug in some library I'm depending on, or see code that works in a way I find unintuitive, clunky, etc., I absolutely think judgmentally about the person who wrote it.

When I'm reading someone else's code and find a solution that's significantly more elegant than I was imagining, I'm impressed by the person's accomplishment, and they basically get points in my head. If I meet them in person I'll quite possibly shake their hand a bit more warmly.

This is normal and natural, and I have to consciously counter-balance that with the learned (but not instinctive...) knowledge that I've written bad code myself, released buggy or clunky code, taken questionable shortcuts, etc..

When I'm in a position to criticize someone else's code (and it's part of my job to do it sometimes!) I usually rewrite my feedback a few times (and sometimes decide it's not needed at all) before writing or speaking to the developer, because it takes a lot of conscious thought to modify my instinctive response into something more fair and effective based on what I've learned over the years.

That's my experience.

Does everyone else actually think that differently?


One of the reason why I keep my mouth shut in code reviews unless something is very critical is precisely this reason. One of the easiest ways to ruin your relationship with your colleagues, or any one for that matter is to comment on their work.

Heck developers are still fine, try talking to a doctor about some other doctor's work, even if all you utter is a minor work of praise for the other guy you will receive nothing short of total angry response loaded with utmost display of ego possible.

Never needlessly criticize someone's work or praise a competitor in front of the person. Unless something big is at stake.

Everything is subjective and everything is personal. That's how human beings work.


humans suck. especially when they pretend to themselves that they are rational


Apparently the part of the brain that decides what we want activates before the logical part; thus we use our powerful brains mostly to rationalize what we already feel is the right answer.


Of course. I do too, it's only human. You gotta be tactful, and you gotta be nice. It's more striving for an ideal state of zen when accepting criticism than anything. Not always realistic, but it's virtuous.


Of course you will feel an emotional response when your code is criticized, and a considerate critic will try to minimize that. But you'd still be the one in the wrong.


> Code is never personal. Whatever I say about your code has nothing to do with you.

Maybe this is fine for psychopaths, economists, or machines that can eventually understand the criticism one day, but for normal people it doesn't apply. Someone's code is like someone's child.

It's great and I'd say necessary to use constructive criticism, but I just don't see the need to bully and make fun of people.


I am working on a team that is smarter than me. And I noticed, they don't attach a huge amount of their identity on their code. Taking myself out of it improved my skills.

Having said that though, when you ridicule someone, you've made it personal. When someone ridicules someone else, there's a high chance that they secretly feel ridiculed by others (Jungian shadows).

I forgot who observed this: adult males will kill off younger competition, unless they are teaching. One of the core values of the Open Source community is sharing and teaching. I suppose, if you stick around in opinionated software long enough, then you start moving away from that core value.


> I am working on a team that is smarter than me. And I noticed, they don't attach a huge amount of their identity on their code. Taking myself out of it improved my skills.

I guess it depends on context. For team work projects, maybe your coworkers don't feel like they have ownership over their work. I feel that this is very different compared to open sourcing your personal work.


> You have to join the discussion like an adult

You don't start "discussion" with "how to make sed and grep worse", you just don't. She (harthur) even attempted to get some real feedback out of the snarky twitter mob, but it turns out that "nothing's _wrong_ with it, but I don't want to build my app on top of others' code who are at this level of understanding".


Yes, I've better familiarized myself with the situation, and the people in question are, in fact, assholes, and the discussion was not productive. Sorry for ranting on a slightly-related tangent...


While I understand the point you're making, as long as there is a way to deliver criticism while being an asshole and a way to deliver criticism without being an asshole, people who choose the former route are assholes.

I also agree that assholes certainly don't have to apologize, as long as you agree that we're free to carry on considering them assholes.


> as long as you agree that we're free to carry on considering them assholes.

My father always told me, "It's a damn shame that it's legal to be an asshole in this damn country." But yes, it is, and yes, you absolutely are. I am a strong proponent of calling out assholes when they're being assholes; myself included.


The point didn't seem to be delivering useful criticism, it seemed to be mockery of the code. I guess you can brand anyone who does that with the world Asshole in scarlet, but do you never mock anything? I'd personally reserve the label for people that either deliberately hurt others or don't care about feelings at all.


Constructive criticism should always be welcome.

These comments weren't constructive, by any means.


So I see your update, but what exactly drove you to take the side of the critic before evaluating the criticism?


This may not be the best place to respond, but you say something I've seen a few times in these comments:

"if you go sob in a corner because you receive criticism, then you're not going to improve."

The corner part is up for discussion, but who says crying renders you un-improvable or non-adult? It's what you do after you cry that matters. I did not know harthur's gender until it was brought up, but women cry more easily than men and it isn't really relevant to their coding nor is it calibrated to feelings in the same way it is for guys. It's not the nuclear option guys think it is.

As for evaluations of code quality, I'd be thrilled to read a discussion of the actual "issue" somewhere. That would at least be interesting.


Hate to say it but I think his post is fair and to the point.

You don't have to like what he said but he puts it in context and within the realm of Twitter - a 140 limited space of communication.

His original tweet was "Ever wanted to make sed or grep worse?".

Really. Can we not be critical on the internet any more?

And here is EVERYONE saying worse things about him in the comments!?

Go look in the mirror people. I'll take the downvotes.

[updated: typos]


> Really. Can we not be critical on the internet any more?

I think that's a vast oversimplification.

I actually don't think this has ANYTHING TO DO WITH CODE. Anyone can walk into a subway restaurant, ask for a sandwich, take pictures of the people who made the sandwich, tweet their pictures laughing at how stupid they are and what a shitty job they did making your sandwich. You can do that to waiters, barstaff, cleaners, you can do that to anyone... but it makes you an asshole.

If you find yourself pulling up individual repos with <5 users and shouting 'Hey everybody look at these people recreating the wheel! What fools! Let's all point and laugh!' wouldn't you agree that's being an asshole? Is that bettering the community? No, frankly all you are doing is choosing to piss on a few people.

I have a ton of files on github and gist, most of them are absolute crap. I put them out there on the off chance someone happens by a similar issue/problem they might find something useful.

This morning there was a gist I was reading, and yeah it was mostly rubbish but it had the one line of code I was looking for.

That behavior needs to be encouraged by more people. We need to encourage people to put out their code and not delete it. Regardless of if it is crap.

If you see something picking up momentum with a growing base of users that you disagree with then by all means start raising the alarms; create a blog discussing the downside of using process X (examples of X could be nosql, sql, node, coffeescript, python, java, grails, groovy, haskell, go, maven, ant, gradle, etc etc)


Exactly.

It's one thing to be critical. It's another to ridicule. Being critical is rational and objective. Ridiculing is a form of contempt, an emotion. When you ridicule, you are not taking apart what you criticize, you are trying to take apart the other person. Those skilled at this will often do it in such a way to make it sound as if they are being rational, objective, and focus only the work, when in fact, they are projecting emotions of contempt and cutting someone apart. The way our society is structured, you can "get away" with something like that because there's a fallacy ... that what you can somehow separate the criticism and feedback you give from the feelings that you experience (or suppress).

Well. You can't. Emotions arise and pass: they are real, they are experienced, and they affect behavior.


  I have a ton of files on github and gist, most of them are absolute crap.
Honest question:

Is it okay for someone else to say (without swearing or making personal jabs) in public that it is also crap?

And again, to emphasize, this is a sincere question.


I don't think it's possible to answer without getting into a debate about community, morality and ethics. There's no way to distill this down to a "unit test".

Will it bother me? Maybe, depends on who it is. XxHackerPants420xX's tweet of 'Columbo is teh code suxxor' wouldn't bother me as much as pg choosing to write a personal blog post titled 'ode to Columbo's shitty github account'.

Is it okay? Meh. It isn't a community I'd want to be part of. I truly believe in the power of constructive criticism and I don't believe anyone can survive this environment by wearing their hearts on their sleeve. However, there's never justification for rudeness.


I understand. I didn't mean it as a unit test, more a litmus test.

And I agree - constructive criticism trumps criticism.

  Is it okay? Meh. It isn't a community I'd want to be part of
Also agree. However I'm unease about people flogged in public over generic criticisms. I think its important that people can say things (yeah, even mean things) since sometimes its warranted.

I'd prefer we save the public flogging to those that step over a hard-to-define line. I don't think that line was crossed in his case.


For once, reading with showdead on made me laugh!


> "You don't have to like that he said but he puts it in context and within the realm of Twitter - a 140 limited space of communication."

This is part of why I dislike Twitter - the 140-char restriction supposedly makes you to the point and concise, but in reality it just encourages snark and imprecision.

It's a world of sound bites, and "Ever wanted to make sed or grep worse" sounds wittier and has more jazz than "I really dislike this open source project and here's why."

That said, if a platform disallows you from being clear and fair to fellow people, don't use it. Ultimately the responsibility to be good to one another is your own to enforce, not Twitter's.

> "Can we not be critical on the internet any more?"

Honestly? No. The internet is full of flippant, callous, outright dismissals. It's reached epidemic scale - and it extends far beyond our little corner of tech. Everyone wants to have their little sound bite hating on something, and it's juvenile.

Given the current state of things, IMO criticism demands a higher standard than ever before. It's not that we can't be critical, it's that we can't be critical without qualifying and substantiating said criticism - there's just too much "hurr this sucks" floating around.

This may necessitate using communications platforms that permit more than 140 chars at a time ;)


I don't disagree with your larger point, but as an official member of the Twitter Defense Squadron (got a badge and everything):

> the 140-char restriction supposedly makes you to the point and concise, but in reality it just encourages snark and imprecision.

This is, of course, a false dichotomy. It does both, depending on the author, and the author's mood. The solution to this problem is to not follow jerks on Twitter. Follow cool people whose tweets have wit, poetry, interesting facts, and/or links to the same.

140 characters forces only minimalism, which exaggerates any number of latent traits, good and bad.


> "The solution to this problem is to not follow jerks on Twitter."

See my other post further down the thread. One of the prevailing attitudes I'm seeing in this thread is the notion that jerks/assholes are somehow exceptional. We're all more than capable of being terrible to each other, given the right context and the right triggers. Pretending that jerks are somehow a different class of people from "the rest of us" is folly.

No one is solely defined as "jerk" - most people have valuable things to contribute, the question is if the system is set up in a way that encourages good behavior.

I don't doubt there are many people who are able to tweet within 140 chars without behaving badly towards others. That's not the part under doubt, the question is if people behaving badly are in large part doing so because of forced brevity. We can make jerks contribute positive things if we set up the system correctly, we can also make more non-jerks into jerks by setting them up badly.

> "140 characters forces only minimalism"

This is a claim often trotted about, but I just don't see this. Looking at my Twitter feed it seems to encourage abbreviations, bad spelling, incomplete sentences, and truncated thoughts. Twitter proponents act like the internet was a giant cesspool of wordiness, and that Twitter was somehow the savior - I don't remember this internet when everyone was writing run-on sentences and long essays about their day.


sed 's/critical/snarky/g'

Or rather,

replace 'critical' 'snarky'


> Can we not be critical on the internet any more?

You can, but why? What good is served?


Having people criticize my code on comp.lang.perl.misc in 1999 improved my programming skill (and, even more so, my Perl skill) very rapidly. However, they were saying things much more detailed than "eyes bleeding".



Criticism is great and necessary, but piggybacking on someone's code with your friends without resolve is no different than picking on someone in grade school. Rather, this is more akin to talking crap about someone behind their back to the whole school because she had no idea it was even happening until a colleague brought it forth.


If the original comments about replace were motivated by "Diagnosis and error correction" or "Improvement", I don't see it.


He really spent a lot of time not apologizing. In fact, not once in his entire post did he even begin to apologize. Most of it was him trying (and failing) to excuse his behavior in the most childish way possible: by blaming everyone but himself.

Seriously, what an asshole.


> notpology

That basically summed it up. I guess it's clear the 140 character limit was never the issue.


Wow, David Cramer is a total asshole! That Steve Klabnik guy is also an asshole. The only one who doesn't appear to a complete dick is Corey Haines, whose apology was better. Not great, but better.

Here's the thing - if you ever even consider saying things like this to someone on the internet, you're an asshole. It's not a one time accidental thing. Nope, it's in your personality. I hope I never meet either of these two individuals, but if I ever meet them face to face I will make sure to tell them exactly what I think of them.


I'm sorry what? If you even consider saying that code is like an existing project but not good, or implying that a piece of code is badly written, you're an asshole!?

Don't you think you're taking this a bit far?


He didn't merely say the project "wasn't good", he implied it in a snarky, very unconstructive way.

Here's his quote from twitter:

>Ever wanted to make sed or grep worse? http://github.com/harthur/replace

In the world I live in, that's called being an asshole.

Look, I'm not saying these guys should apologize (in fact, if this is how they apologize it's probably best they don't), I'm simply stating that they're dicks. I know a lot of computer programmers just like them.

Edit: And I hate working with people like them. I don't care how brilliant they are, programming is a team sport in most places. If you're a jerk I don't want you on my team, no matter how many awesome sed scripts you can whip up.


> "that's called being an asshole"

There's a difference between "being an asshole" and "sometimes acting like an asshole". We all do the second thing sometimes.

A snarky comment and a bad apology may be an instance of the second thing. But they don't imply the first.

Compare another toxic noun, "racist". There's a difference between "being a racist" and "making a racist comment". If people could apologize for the latter when it happens, understanding that it does not imply the former, the world would be a better place.


> A snarky comment and a bad apology may be an instance of the second thing. But they don't imply the first.

Sorry chief, I'm gonna have to go ahead and disagree with you there. The snarky comment can be forgiven. (although I've since read other tweets/posts from David Cramer and it appears as though he really is that abrasive all the time)

By contrast, a bad apology is a clear indication of someone's true nature. If the apology is backhanded or otherwise poor, it implies a lot. If you issue an apology but don't really feel sorry, then you're just doing it to placate others, and you really are a jerk.


He did not attempt to apologize, he defended his position. He wasn't being underhanded or antagonistic, he was attempting an objective justification. Nothing in there resembled passive-agression or "dickishness."


He admitted he was nasty in his blog, but he was proud of it. Enough said.


I don't see where he said he was proud of it.


Luckily, Cramer wasn't giving an apology. That post was not apologetic because it was an explanation of a single tweet. If you keep shitting comments that don't reflect the reality of the situation, that makes you the asshole.


Agreed, asshole :) (or was it the other way around ?)

Holly Ass, Twitter, by essence is an assholy thing. What can you expect from someone who has "3500 friends" or "50 000 followers" ? Follow the Holy Shoe of Jerusalem :)


The effort you spend denouncing them- 116 words v.s. less than 160 characters total in theirs- makes you look like a tosser.

Their actions weren't advisable by any measure, but you've certainly demonstrated a willingness to make up your mind about them, based off a number of extremely extremely short pithy statements. Dial down your indignation, friend: help us get rid of this reek.


> Dial down your indignation, friend: help us get rid of this reek.

I agree with you and gave you an upvote. Maybe my comments do make me look like a "tosser" - but these people were behaving like bullies, plain and simple. And man, I can't stand that shit. I see it every day. People will go out of their way to make others feel miserable. Or they use their power/standing/influence to pick a fight with someone weaker just because they can.


Steven and Corey have both more or less begged off from even trying to say what they mean- they have simply apologized for introducing volatility, for hurting feelings. I find it outrageously presumptuous to take such short, pithy tweets, and to claim they were made with malice, intending to antagonize, or were in fact bullying.

The fact is Nodeites are renowned for rehashing the entrenched. It also, gasp, has callbacks. These people weren't gentle in pointing out a capital example of just these two things. I don't think that makes them bullies or bad people, nor do I guess they even considered the human behind the works nor hardly the work itself: my _guess,_ and indeed, everyone is guessing here, is that they were making a crack on the idea of replacer, as justly emblematic of what Node is renowned for.

And although I think one would be a fool to become so polarized in view as these people showed themselves to be, I would much rather we have open channels where such conduct is permitted, where we can be a little low brow, boorish or lively, and express our ruffian selves: I'd rather have a wildness. I prefer tolerance and resilience. I loath the intolerance that says we must sterilize and purify and be of good behavior, must watch ourselves constantly.

Harthur talks about feeling like her identity has been injured, wounded forever. Yet here we are condemning and slining insults, armed with the zeal she has given us. Here we are, enacting new moral codes, legislating terms where nothing but support and good manners towards one another will be accepted. She felt that she had not been tolerated, not encouraged, yet the response is to mandate intolerance of another behavior, yes a boorish one, but regardless, just another tripline for ourselves to unintentionally trip over. Let's instead seek discourse- which she did- and failing that, tolerance. Let's not go troll hunting, lest we lay too onerous a minefield for any man to hazard.

A girl got caught in the crossfire of polarized communities. She cried. Everyone felt bad, many got indignant and decried other people and other communities for their action or contact with the affair. The internet got more uptight about itself. That, to me, is the absolute losingest situation imaginable, and I'd handily pass out yellow cards to 80% of this topic as contributors towards winding ourselves up, of taking ourselves too seriously, of ascribing way too much levity to an event that was tiny in size, and which we have not been given a codex to understand- it remains a context free situation, one we merely make projections about, without knowing what the real intent was, we just know people tweeted, for whatever reason, because something struck them, and they created, made and shared new content about their experiences.

They shared. I don't understand, they haven't explained, I don't think I'd like it even if they did explain it better, but these were people keeping themselves amused, first and foremost. That that would be subject to so much scrutiny, the cause of injury, is itself the most tragic here. We need to be tolerant, and find good, not focus on censoring bad or fretting about our identities, as first Heather did, and now the three authors are likely doing.

Sorry for labeling your writing as tosser like, not cool of me. I feel like ascribing intent to what happened is an impossibility, and even with bad intent I'm still very uneasy with censoring, with mandatory good behavior. I beg for de-escalation.


Okay, okay. This is enough. Both. Thanks for calling for a de-escalation, that sounds like a wonderful idea.

First things first, bullying is not always conscious. You seem to imply that and I happen to believe that is not true. Someone can act bullying-ish without being a bully. It happens. It sucks, always. It sucks especially when you're not in fact a bully and you didn't mean to act like one. (someone made a comment about "being a racist" and "saying something racist". It's similar.)

This point has been made over and over again: Someone with such a large audience and such a public channel has a certain responsibility. For better or worse, they represent a certain part of a community, they are looked up to. You can't deny that with a certain amount of, let's say "Power" comes a certain amount of, let's call it "Responsibility" ;)

And that responsibility is that they can't afford the same boorishness and low brow-ness on their e.g. public twitter channels. It's not just a developer expressing an opinion anymore. It becomes a community thing. I even read tweets in German, bashing this github repo. And when it goes that far, the vitriol in the air just grows exponentially. People don't think about it anymore, it's suddenly a hive mind thing. That's why it spreads so quickly. Monkey see, monkey do.

It may have been only one tweet per person by three people, but they happened to be high-profile enough to spread it far and wide. I also want to keep the communication channels open and tolerant, but it is important to conduct yourself in a courteous manner that you would also use face to face. Especially if you have follower counts in the thousands or ten-thousands. (it's a tight-knit community...)

I don't, however think that the public communication channels need to be tolerant or indeed designed for low-brow, ruffian, boorish behaviour. You can do that at home with your friends. Or indeed on Jabber/XMPP. Or on your own forums. Or mailing lists. Not that I would want to ban people from exhibiting these behaviours on public channels (To the tolerance-mobile!), but I would like to see the community frown upon them. In my opinion, they add very little value to the content and they benefit mostly the person exhibiting them and not the community at large. That to me means definitely that it should stay in private circles, especially if it can be detrimental to a single person.

You say that the community doesn't do itself a favour, reacting as harshly as that. But many of us (I think) love the idea of open source. Many of us would put out a small tool like that on github and we would probably be upset if someone (seemingly) just took a quick look at it and go to twitter and just essentially start a high profile pitchfork mob. That is why the reaction has been soo strong and passionate.

Also, the fact that Heather got caught between communities warring (apparently. that was not known to me...) is fairly irrelevant. This kind of conduct needs to stop. If someone wants to duke it out on twitter, take it up with someone who 1. agrees to it, i'm sure there are enough zealots in either community. or 2. is of a similar high-profile stature.

Some thoughts on what was said, what was meant, what was perceived. What was said: "I cannot even make this stuff up [link to gh:harthur/replace]" What was meant [speculation?]: "Hmm, I wonder why someone would remake sed with node.js? Weird." What was perceived [speculation?][citation needed]: "OMGWTF, LOOK AT THIS IDIOT MORON!!11 DOESN'T TEHY KNOW THAT THIS IS LIEK SED BUT SHIT? ALSO NODE.JS, LAWL!!!11"

This is only one of the examples. This is a problem, agreed? Most people seem to forget that perception is the most relevant of these three things when you conduct yourself in public.

Wow, this got more rambly than expected.

PS: To everyone that says "grow a thicker skin, the world is bad", please don't do this. It should be very reasonable to expect people to not be idiots. It's not a stupid thing. It's something we as a community should strive for. We should be moving towards a community that frowns upon these behaviours, protecting the new and the defenseless. (What you do in your startup world is none of my business, of course.) Why this hit so close to home for Heather [speculation?] and many of us [speculation?] is because we feel safe in this community and we didn't expect to [citation needed] be backstabbed out of our own ranks.


Best summation of this issue I've read so far. Hear, hear.


I'll take a page from the book of the guys you're defending and make a pithy comment to add some "levity" to the situation, as you called it.

"At no point in your rambling, incoherent response were you even close to anything that could be considered a rational thought. Everyone in this room is now dumber for having listened to it. I award you no points, and may God have mercy on your soul. " - Billy Madison

Man I love your version of tolerance.


It shouldn't matter if it's unconstructive. He's not talking to the author of the code. I still don't see how being snarky, or god forbid considering being snarky, makes you an asshole. It's just some code; he's not insulting anybody.


Insulting someone's code is like insulting someone's kid. The guy probably feels he put a lot of thought and hard work into it. It's not that hard to give constructive feedback as opposed to being an asshole.


> "Insulting someone's code is like insulting someone's kid."

You are way too attached to your code.

. . .

What these guys said was still extremely rude.


I didn't come up with that quote. I believe someone famish like Martin Fowler did a few years back.

> You are way too attached to your code.

For most people this is subconscious. If you're not, good for you.


Someone like Martin Fowler should have better sense. Probably 75% of code is hideous when it's written. Probably 99.9% is hideous a few years later.

Someone who's so attached to their code that they can't accept criticism (even harsh criticism) of it is pretty much guaranteed to be writing crappy code.

You'll notice that harthur didn't flip out as if her child was insulted. Instead she asked for constructive feedback, a sign of professional maturity.


> Someone like Martin Fowler should have better sense. Probably 75% of code is hideous when it's written. Probably 99.9% is hideous a few years later.

Whoever came up with the orig quote does have good sense. I've worked with a lot of people ranging from NASA to new hotness start ups. I would say 95% people would be pissed no matter the skill level if you just made fun of their work as opposed to offering constructive criticism.

> Someone who's so attached to their code

I'm sure that most people who care about the quality of their work is somewhat attached to their code.

> that they can't accept criticism (even harsh criticism) of it is pretty much guaranteed to be writing crappy code

The issue at hand isn't that Heather can't accept any sort of criticism. The issue is still that you don't have to be a fucking dick to criticize someone else's work. It's not hard to offer constructive criticism as opposed to just trashing and making fun of something someone worked on for months or even years.

> You'll notice that harthur didn't flip out as if her child was insulted.

Umm she was crying; not only that - she posted that she cried. I would say she was pretty upset; she just handled herself well despite the circumstances.


> I would say 95% people would be pissed no matter the skill level if you just made fun of their work as opposed to offering constructive criticism.

I wasn't saying people wouldn't get pissed if you insult their work. I'd be annoyed if someone made fun of my work. But I certainly would not be as angry as if someone insulted my child. Or even my dog.

> The issue at hand isn't that Heather can't accept any sort of criticism.

Obviously not. She handled the situation with an overabundance of grace and asked for meaningful criticism.

> The issue is still that you don't have to be a fucking dick to criticize someone else's work. It's not hard to offer constructive criticism as opposed to just trashing and making fun of something someone worked on for months or even years.

Absolutely. These guys were being jerks. My comment was about being as attached to your code as you are to your child.

> Umm she was crying; not only that - she posted that she cried. I would say she was pretty upset; she just handled herself well despite the circumstances.

I'd say the fact that she asked for feedback is clear evidence that she is not attached to her code the way she might be to a child. Try walking up to a parent and tell them that their child makes your eyes bleed and let me know if they ask you for constructive feedback, vs hitting you, screaming at you, spitting in your face, or just walking away scowling.


Very true,

Everything in this world is subjective. When you talk about someone's work you are inevitable bringing some degree of comparison into it, and human ego has huge troubles dealing with that.

Nobody ever forgets an insult, it comes back sooner or later.


By "the guy" do you mean "Heather"?


yes


That's fine, but saying "this code makes my eyes bleed" is very obviously meant to demean the human being who wrote the code, not the code itself.


I honestly don't see that. It insults their coding ability, or at least their focus when coding that particular thing, but disparaging a single skill that a person has is not being demeaning to that person. At least in my mind.


That's pretty much what demeaning means, though.

It's not "a single skill" as if you were telling Torvalds that his juggling skills were crap and he should keep his day job; if someone has enough coding experience that they're releasing OSS on GitHub, coding is quite likely their job (or they're in school to make it their job).

So yeah, snarkily saying that the product of someone's career activity makes your eyes bleed (or whatever) is demeaning to them -- i.e., directly attacking their dignity and others' respect for them.


Their dignity should not be dependent on their job area being flawless. Thinking they screwed up on a single hobby project should not cause a loss of respect for the person.


There's a big gap between "not flawless" and "my eyes are bleeding" or "I can't make this stuff up".

Also: "should" != "is", I'm afraid.


I'm trying to make a distinction between 'a code project' and 'all the code they make'. Generally speaking, having one shit project doesn't do much to someone's overall record. 25 good, 1 shit is better than 10 good, 0 shit.


I think most people would find it demeaning to hear it said about their code.


If you make a criticism of someone's ability to do something, you are making a criticism of their intelligence. If a product gets bad marks across the board, are there no consequences to the team that developed it?


Ever wanted to see a bad argument? Read the post by Dylan16807!


As long as you're linking a specific post, go for it. I've made mistakes.

But I'm going to hope it's not just a post you disagree with. Just like I hope you don't call code bad because it uses OTB or omits semicolons. It should be failing to solve the problem it sets out to solve, and in an interesting manner. (Note: I have not looked at the code tweeted about.)

Edit: Wait how did THIS post get downvoted? I can understand the earlier posts but I can't even imagine what's objectionable about this one.


Don't know, but possibly because you're derailing the discussion.

The outrage is not about constructive (or even unconstructive) criticism of the code itself (which appears to be fine): At least one of the guys ridiculed the author and questioned her competence for the sole reason of implementing a subset of the features of GNU find+sed on top of Node.js.


Well then maybe those people should have been mentioned in the article. When I see top-level comments I don't realize I have to read hundreds of comments they are replying to without using the reply button. I was only talking about the examples given up front, which insulted the code, not the author.

Thank you for the useful info.


Buried beneath the snarkiness, the implied constructive criticism might be along the lines of "don't re-invent the wheel, kid". I looked at Heather's code. It seems pretty tight to me.


What a stupid comment! My eyes bleed! (But the author is probably a decent chap).


So you don't take pride or feel a sense of ownership over your code? That would put you in the minority I surmise.

Fact: The vast majority of people would take the twitter conversation Heather posted as a personal attack. Not many people are able to separate attacks on their work product from attacks on themselves (for good reason - since I feel like most people derive a sense of pride from their work).

I dare say it would also take an asshole to not recognize this fact and make rude comments and not realize someone would be personally offended even though "it's just some code".


in fact, if this is how they apologize it's probably best they don't

That's a beautiful bit of writing and thinking, right there :)


Meanwhile calling people assholes and declaring that the reason is "in [their] personality" based on what they may have considered saying, that's perfectly ok?

Have you really never made a comment without fully thinking out the ramifications, without missing some of the consequences, or just simply without really thinking period? People say shitty things sometimes, but labeling them as an asshole for all time based on that is patently ridiculous.


Oh sure, I've made plenty of stupid comments, but that's not what these guys did.

They picked a repo on Github that they thought was duplicating functionality in Unix (oh the horror!) and engaged in classic schoolyard bullying. Publicly shaming the code and the author, apparently to make themselves feel better and show the world how smart they were. And at the end of it, the apologies they issued after the internet turned against them were poor.

So yes, I do occasionally say dumb things, but I'm never a bully. If I say something mean it's because it was provoked. And if I need to apologize for something, I do it with real contrition.


I can comfortably say, based on more than a few arguments and discussions, that Steve Klabnik is not a bully. This situation sucked all around for a lot of reasons, but "that's it, this guy is an asshole end of store" is a poor reaction to it.

If you want to judge a person with any degree of finality by one isolated incident that you barely were involved in, that's your prerogative. I think that speaks more about you than it does the person. Hopefully you'll give me some evidence that changes my mind, I'm at least still open to that.


How can you begrudge me my opinion when the only facts I have corroborate it?

http://blog.steveklabnik.com/posts/2010-09-24-trolling-is-a-...

This post was from 2010 where he admits he's a jerk and can't help it. I think that pretty clearly is a victory for my thesis.


...did you link to the right post? The one I'm reading says he is aware that he is capable of this kind of behavior and has taken steps to mitigate it. If anything it hurts your I'm-right-in-declaring-this-guy-an-irredeemable-asshole thesis.


Dude, I don't know what to say to you. You're going to argue for the sake of it, even though you're objectively wrong. Maybe you can shed some light on why people do that?

The man HIMSELF admits he is intrinsically an asshole, and that even when he uses his real identity he can't help himself. Yes, he's trying to be better. But an alcoholic trying to fight the bottle is still an alcoholic.


In 2010 he said he had arsehole like tendencies. That's some time ago, I think it's a stretch to say that it makes him one. I've agreed with you right up to this point!


Well, he engaged in 'arsehole like tendencies' two days ago. When an alcoholic is on the wagon for a long time and then falls off again, they're still an alcoholic.


Comparing an alcoholic to an arsehole is absurd. An alcoholic can never touch a drop of alcohol for fear of getting addicted to it again. Someone can be an arsehole some of the time, and very nice the rest of the time!


>Wow, David Cramer is a total asshole! That Steve Klabnik guy is also an asshole.

Since we are talking about insults, reputation and constructive criticism: Does HN think the quoted text is appropriate?

Personally I think it is about on par with "makes my eyes bleed".


To be fair, that criticism is backed up by evidence. Whereas the main reason harthur's code made their "eyes bleed" was because it was written in node.js.


>>>and what separates people is how they deal with it.

That.


cramer's apology does imply that he didn't apologise properly the first time, and it was his lack of communication that did it. of course that could just be damage limitation


Here's the other apology, http://blog.steveklabnik.com/posts/2013-01-23-node

Heather, don't take it personally - your code is fine! JavaScript, on the other hand, is a wounded warrior by now..


My takeaway:

"Twitter makes it so hard not to accidentally be an asshole."


I once saw a BBC documentation about "why do car drivers easily get angry at each other?"

This is really interesting, maybe you want to think for a minute yourself before I reveal the reason. When I watched the documentation to the end I was surprised, but when I think about it now I'm not surprised anymore:

Car driving involves no eye contact, in fact you hardly ever see the face of the other person. People behave differently and more nicely when they look into each other's face. One illustrative example were Laughter Clubs. People go there to laugh. So when a new member joins, all others stand around him, start to laugh and look him in the eye. No matter if the laughter starts artificially, only few moments later the person in the middle cannot stop laughing... ;)

Back to the topic: Twitter is probably the most impersonal way to communicate. E-Mailing with my tax consultant is more personal. I cannot tell how often I realized that misunderstandings were created with E-Mails (which have arbitrary length.) Or even text messages which are limited to ~500 characters; but Twitter? 140 character stubs to talk to complete strangers?


Text messages are normally limited to 160 English characters, or fewer from other languages. I thought that was actually where the Twitter limit came from originally.


It's certainly not Twitter's fault. Lately, the open source community's underbelly has been exposed.

"But open source is right and we are the good guys?!", or... "But I know those guys and they are usually really cool!"

We want to categorize people as being bad or good, and it messes with our brain when we think we may have to re-categorize. It's more useful to realize that we all have a capacity to do both good and harm. It's also more useful to judge ourselves than others. Recognizing the need to change is the beginning. I know that I need Outside help to maximize the good and minimize the bad that I am capable of.


Yes, it's partially Twitter's fault. Enforced brevity in a popularity contest setting encourages smartassery and discourages (or makes impossible) nuanced expression.


Twitter isn't coming up to anyone, twisting their arm and telling them to be a dick. Lots of people manage to use Twitter without coming across like assholes.

If one feels that 140 characters isn't sufficient to correctly represent one's nuanced thoughts, then don't tweet.


And that's why I don't tweet!


Where's the button to give you 10million upvotes?


And yet you expressed your idea in under 140 characters.


That's a main reason why I don't. But I gather that in some circles the social pressure to tweet is not much short of arm twisting.

I doubt you could find many twitter accounts (barring commercial PR stuff) whose history is entirely free of rudeness.


> Lately, the open source community's

There is no "open source hivemind" so please don't disparage the millions of open source coders who will never make the frontpage of HN by lumping the entire conglomerate into one community.


Sorry, I didn't mean to disparage open source or people creating open source software - I love it!. The point I was trying to make was that even people with good ideals are fallible.


No, Steve Klabnik being an asshole makes it so hard for him to not accidentally be an asshole.

Look at this quote:

> nothing's _wrong_ with it, but I don't want to build my app on top of others' code who are at this level of understanding

What a prick!


Yeah... criticizing code is one thing (perfectly acceptable IMHO), but turning it personal made him into an asshole.

Note that of course there's an element of "uncomfortable truth" to this—evaluating programmers' ability is probably a good thing, and he's right to a degree. We all know amazing and experienced programmers who write libraries that are like diamonds in the rough compared to other coders' work, but 1) you have to be tactful; you don't put people down for their code no matter what, because 2) you have to help them get there, and negativity is not how you do that.


that quote is from where?



Out of curiosity, do you think there would there have been blog post apologies if the harthur post was written by a guy?


It took me up too now to realise it wasn't written by a guy, so.


I think it's the public ridicule aspect which is new, thanks to everyone using twitter like it's their backyard, and forgetting it's a mouthpiece to the entire earth.


No. The hot button topic right now in open source is "increasing diversity" which means more attention is being focused on this.


Yes. I didn't realize the post was written by a woman until I read comments here.


I wish he would replace his home page. I have to wait ~5 seconds to see the navigation for no reason other than the stupid terminal animation, and there's no obvious way of skipping it.


Please don't bully him like that. Have you learned nothing from this incident?


How nice of them. Makes you wonder how many apologies are outstanding.


To clarify - apologies to other people.

There's no such thing as accidental one-off snobbery.



> I cannot even make this stuff up: <url>

You are clearly well versed in this subject. So, how would you attribute this remark?


Twitter; you don't have space for detailed (and possibly constructive) criticism, you substitute witticisms because that's what gets retweeted (i.e. what the environment rewards). Maybe you read another snarky tweet just before and want to one-up it. Maybe you just worked on some messy code and are a bit frustrated and this looked like the right place to vent.

Off-hand snarkiness can be pretty mean, but that doesn't mean that everyone who engages in it is a fundamentally bad person; In fact I sincerely doubt anyone here has never written something similar.


Indeed, and thanks for explaining it better than I ever could.

People are treating "being an asshole" like an exceptional state of being, when in reality we're all assholes to someone sometimes. To pretend that some people are just intrinsically assholes, and everyone else is incapable of it, is a pretty surefire way to end up being the next asshole.

The reality is that snarky, flippant comments are easy, and it demands a level of self awareness to not engage in it. Recognizing your own ability to be an asshole is part of that.


> you don't have space for detailed (and possibly constructive) criticism, you substitute witticisms because that's what gets retweeted (i.e. what the environment rewards). Maybe you read another snarky tweet just before and want to one-up it. Maybe you just worked on some messy code and are a bit frustrated and this looked like the right place to vent.

And that's basically what we shouldn't do.


Sure, I understand that he is not an inherently mean person, who went looking for a sloppy code to bash. I meant that if he acted this way once, there's a good chance that he said something similar before, but it went unnoticed at that point.

Given his apology, he clearly would've not made that remark in person, nor would have he done it if didn't have a receptive audience that appreciates such snobbery.


Only one, from @zeeg.



The open source community surrounding popular languages such as Ruby and to a lesser extent Python has some really obnoxious behavior. They look more like popular girls at a high school than serious programmers interested in sharing good things with the world and helping others.

Also, people who live in glass houses should not throw stones at others. What is to prevent someone from going all Dijkstra on them? So be kind to others, it won't take much for someone much smarter than you to trample you.

This is nothing but bullying and can have a serious affect on the bullied person's mental health.


tl;dr: With great power comes great responsibility.


> Steve Klabnik ‏@steveklabnik

> @harthvader @zeeg nothing's _wrong_ with it, but I don't want to build my app on top of others' code who are at this level of understanding

This message [1] in particular is absolutely disgusting. Someone hacked together a script that met their needs, and threw it up onto GitHub in case anyone else found it useful? Yes, let's take the opportunity to condescendingly insult their mental competency.

What does he even mean by saying that he doesn't "want to build my app" on top of harthur's code? Nobody asked him to; steveklabnik himself made the original post, taking the opportunity to show off this smug sense of superiority.

[1] https://twitter.com/harthvader/status/293829635823792128


> What does he even mean by saying that he doesn't "want to build my app" on top of harthur's code? Nobody asked him to

I can't speak for him, but based on another comment further down ("I'll be over here in not-node"), it read like a dig at Node itself by proxy / extension.

> Yes, let's take the opportunity to condescendingly insult their mental competency.

Indeed. This type of behavior is almost never justified, but particularly less so when the object of scorn is clearly an exceedingly talented programmer. One glance at her GH profile reveals several well-used open source projects, including a neural network library and a bayesian classifier.

It really does drive home the point that if this can happen to someone of her caliber, then it really can happen to anyone. In fact, it probably does - except with less public attention.


I might be an emotionless robot or something, but I don't get the furore over this.

Everyone writes crap code sometimes (viz. github.com/007 aka craptown USA). Just because you are "exceedingly talented" or have "well-used" projects doesn't mean everything you write is rainbows and unicorns.

If your project is useful to you, then screw everyone else - why care what they think?

https://github.com/harthur/kittydar is useless but brilliant. I'll be bookmarking it for the next time I need feature detection in JS, and because it mentions HOG descriptors.

https://github.com/harthur/replace is useful but not-brilliant. I'll bookmark the 'sed' or 'awk' manpage instead.


But it seems that complaints against the replace code wasn't about the code itself. It seems it's more about the fact that it isn't sed, that it's javascript, that it's node, and that they themselves would choose not to use it. For all those reasons they chose to publicly criticize the project in what can be considered a demeaning way. For an "open" source community, that's a bad thing and deserves this furor. In fact, it should happen more often than it does.


One glance at her GH profile reveals several well-used open source projects, including a neural network library and a bayesian classifier.

Thanks so much for pointing that out (and thanks Heather for writing it :P)! I would have missed it otherwise, and I have always wanted to play with neural nets as well as bayesian filters.. this seems very friendly for me to get into, so it made my week(end) if not more :)


What a great idea to go around calling other people stupid for creating personal open-source projects that they enjoy using, mocking their competence and treating them as if they should go away because they aren't as good as you. What a productive use of a developer's time.


Even stranger is the fact that harther isn't exactly a novice programmer: apparently, she's part of Mozilla [1], and wrote brain.js [2], a neural network library in JavaScript with almost 1,400 stars on GitHub.

[1] https://twitter.com/harthvader

[2] https://github.com/harthur/brain


which is doubly embarrassing for the people insulting her because odds are anyone taking the time chastising someone's hacky duct tape script as if it were a Real Thing Worth Talking About probably has no comprehension of real algorithmic work, real computer science, like that needed to implement neural nets.


To be fair implementing a simple neural network is probably about par for the course as a sophomore CS undergrad project.

The basic algorithms you need can be found via google.

In my (extremely limited) experience the much more difficult part is using them to successfully solve real world problems.


Sure. My point is anyone who really seriously gets on their high horse about how great they are by looking at a simple little script that is essentially background noise for professional engineers are probably pretty far removed from even a sophomore CS undergrad level of sophistication.


Certainly, although in my experience smart , sophisticated people are by no means under-represented in the "asshole" population.

IMO the problem comes when you have people who's entire ego is based on being smart. In the past they probably had their egos massaged by getting the highest test scores in class etc and "winning" in that sense. Since the world does not work like that anymore they feel that they have to "win" at github instead.


brain looks pretty cool and I also noticed she not only works at mozilla but also regularly speaks at conferences. Weird how judging a person's competence based on looking at a single for fun open source project may not be a great idea.


Here's the thing, when someone like Linus Torvald says things like that, we applaud him for it.


I'm not sure if that's the same thing. Linus usually criticizes things in a way that actually points out the flaws. This guy is just essentially saying "LOL U SUCK"


And with Linus, it's not usually about the person (unless the person is actually being obstinate or negligent).


And here I was thinking that Linus was the one guy in open source who says "moron" a lot.


LOL U SUCK. Kidding, though some of the threads I read involving C++/C with Linus involved are so childish they are actually entertaining.

Example: http://article.gmane.org/gmane.comp.version-control.git/5791...


"Some of the threads"

goes ahead and provides one link everybody here has read by now

does see or mention context


Oh, the C++ one came to mind immediately when I read the parent comment.


Linus is often rude, but AFAIK not gratuitously, but I may have missed some of his public messages.

But even if it's the case, he is rude with the guys who work with him, his "captains" that he knows since a long time.

He do not bash a random project on Github totally unrelated to him just like that.

You can't compare.


No, Linus is often gratuitously rude.


Got a link ? Of Linus being gratuitously rude with a perfect stranger ?


Linus telling someone to shut the fuck up last month: http://news.ycombinator.com/item?id=4962912


Different because Mauro is talking on behalf of the Kernel and claiming obviously bad changes are good ones. Linus is reprimanding a subordinate that is supposed to be one of the most well-informed members of the Linux community as a kernel maintainer -- he's not criticizing a stranger for posting a tiny script in case it "might be useful".

Linus is DFL (not so benevolent sometimes) of Linux, and can lash out when one of his trusted lieutenants is acting like an idiot. What these guys did is call out a stranger on the street and said "YOU SUCK!"


Be that as it may he was a complete dick. I wouldn't want to work with someone like that, no matter who he is.


You don't have to. Then again, that's not a criteria for anything.


My guess is most people prefer not to work with assholes. And its a pretty good guess.


I don't think another maintainer on the Linux kernel qualifies as a perfect stranger. The team isn't /that/ large.


Why does it need to be with a stranger? Rude is rude.



tubbo 0 minutes ago | link [dead]

He's usually rude to code presented to him, but he doesn't go out of his way to diss code. It's a big difference.


I think it's inaccurate to suggest Linus is universally applauded for his rude behaviour. The last public outburst that caught wider attention than the LKML seemed to quite divide programmers in terms of its appropriateness. Personally, I found his attitude repellent and his tone unjustified.


Linus doesn't say things like that.

He goes after people who enter discussions without bothering to understand the details or the history. If you want to code your own kernel in Java, that's your prerogative. But if you come to lkml and start preaching C++ advantages, you will get flaked.


Who's "we"? HN, let alone software devs as a whole, are not a hivemind.


Linus doesn't say things like that.

If you don't understand the difference of context, well, look again!


He does. This was pretty nasty.

http://shutupmauro.com/


Do you really not see the difference between Linus Torvalds recalibrating a kernel contributor and three nobodies of questionable "conference-fame" picking on a random stranger?


No, I don't see why there should be different standards for civility in the two situations.


I don't see the difference. Could you perhaps explain it?


Yelling at someone you're in an argument with is a world away from picking on a stranger.

(It's not necessarily good, but it is categorically different behavior.)


Dressing down someone like that on a public mailing list is absolutely picking on them. It's not an argument, and is basically no different to the behaviour here.


It is basically worlds opposite to the behavior here.

a. Linus uses swear words. Steve Klabnik used none.

b. Linus provides substantive criticism. Even if you need flame-retardant underwear to hear it.

c. Linus never ever ridicules outsiders.

So what do the two have in common, again?

I loved the mauro thread because you're seeing Linus talking to an insider of an influential project and tell him that the relative outsider with no status is right. By doing it publicly he reinforces the culture of the kernel: we don't break user code. We are a meritocracy, and if you're wrong I will not be shy about letting you know.

He could do it with less profanity. But I heartily support his doing it so emphatically. Nobody else on lkml will brush something off as a userland bug for a year.


Ridicule is an extremely poor motivational tool, and when someone of Linus' standing does it, other people think that makes it somehow ok.

There are many ways to reinforce meritocracy, or reinforce a culture without telling people to shut the fuck up in all caps.


"Linus never ever ridicules outsiders."

That's actually not true. His "security monkey" references towards other projects being an example.


If someone brings up their child in a way I think is wrong I may disapprove, but it would be wrong of me to be abusive about it. If someone deliberately hurts my child and then makes excuses, I may very well end up serving 10 years to life for what I do to them.


Do you have this opinion when you are doing it?


Sounds like a general reprimanding a subordinate who has put people's lives in danger repeatedly and needs a straightening out. He clearly explained what the problem is, and expressed frustration that this had been explained before. Quite different from what is going on with this post.


I'd say that Mauro Carvalho's replies show a class act!

https://lkml.org/lkml/2012/12/23/87

https://lkml.org/lkml/2012/12/24/125


it is nasty but it is useful and when you a kernel maintainer is probably deserved.


Steve Klabnik:

"I find it incredibly hard not to be judgmental.

I'm not sure what part of my personality makes this happen, but even when I try to curb tearing down other people, I end up doing it anyway. I'm not sure if it's just me, but I think part of the problem is that these kinds of things are rewarded."

http://blog.steveklabnik.com/posts/2010-09-24-trolling-is-a-...


Textbook weasel apology.


Note the date; this one was from 2010.

His most recent post is http://blog.steveklabnik.com/posts/2013-01-23-node


From that post:

> Twitter makes it so hard not to accidentally be an asshole.

No, I'm pretty sure being an asshole makes it so hard not to accidentally be an asshole. Plenty of people, including Heather, weren't assholes on Twitter.


And it's still a weasel apology


Generally a weasel apology would be:

"I'm sorry If I made someone feel bad"

Not

"I am sorry. I feel terrible that I made someone else feel terrible."

Corey's apology did feel nicer, but I don't think that Steve's was a bad apology.


In his "apology", Steve says three times that he was "accidentally" an asshole. That doesn't sound very sincere.


He also talks more about his feelings than the person he's apologizing to!


I don't think textbook weasel apologies are usually done several years in advance.


Seriously, what a complete prick.


Not to contribute to the mindless hate, but look at the dude's Twitter photo. He's clearly an eccentric fellow. And also, apparently, an asshole.


This is scary. I share a lot of bad code in various places, that I created in process of learning or just because I needed something done quickly. I always inform that this code shouldn't be used in any system "as is", but may serve for learning purposes.

I know that a lot of people do that. And I find it incredibily useful, sometimes finding a snippet of code saves me time from jumping extra hoops, just because (for example) driver misbehaves or documentation is incorrect/incomplete.

I hope this incident doesn't stop anyone from sharing their code and findings, no matter how good or "professional" they are.


Heather, I agree that people are unnecessarily rude to you. Don't sob. Your code shows you are already a more capable programmer than most of the ones I interview. No one has given you a clear answer as to why your code is reinventing the wheel, so allow me to do it politely. I took every single example from your README, and show you below how everything can be reimplemented with sed -r (nice extended regex syntax, mostly like js regexs), and find/xargs:

  replace 'var' 'let' *
  sed -ri 's,var,let,g' *
 
  replace 'var' 'let' . -r
  find . -type f -print0 | xargs -0 sed -ri 's,var,let,g'
 
  replace 'var' 'let' test/file1.js test/file2.js
  sed -ri 's,var,let,g' test/file1.js test/file2.js
 
  replace '(\w+)_(\w+)' '$1-$2' *
  sed -ri 's,(\w+)_(\w+),\1-\2,g' *
 
  replace 'var' 'let' . -r --include="*.js"
  find . -type f -name '*.js' -print0 | xargs -0 sed -ri 's,var,let,g'
 
  replace 'var' 'let' . -r --exclude="*.min.js,*.py"
  find . -type f ! -name '*.min.js' ! -name '*.py' -print0 | xargs -0 sed -ri 's,var,let,g'
 
  replace 'var' 'let' . -r --preview
  find . -type f -exec sh -c "echo == {}; sed -r 's,var,let,g' {}" \;
  (not sure if --preview does exactly that, I echo the filename followed by the modified content)
There is only one case that justifies reimplementing things: if your tool has the requirement of supporting the exact js regex syntax, then yes you did the right thing to reimplement this in js. I have run into similar situations myself. One time I had to support Perl regexs, and I started by simply using Python's standard regex module, thinking that it would work because both Perl and Python use PCRE. Well as it turned out the regexs I encountered used some advanced features (such as negative/postive look-behind/look-ahead, etc) that Python's regex module plainly did not suppport. So I ended up rewriting part of my implementation in Perl.

Edit: I spoke too fast. As a commenter pointed out, other legitimate cases for reimplementing this in js would be when you can't afford to or don't want to fork a process to run find/xargs/sed. It sounds like you were running the tool from the command line, so I didn't think that would be your situation.

Edit 2: Yes, the exercise of reinventing the wheel is also useful for learning... I am not going to argue that.

Edit 3: If you care about simplicity, I would personally rather write a small shell script wrapping find/xargs/sed and hiding their arcane options, as opposed to writing 173 lines of js.


Honestly, I think you ended up really making the case for replace. The nix CLI examples are convoluted at best.

I've used CLI tools for years, and it would probably take me 5-10 minutes of scanning the man pages to reproduce all but the simplest of those snippets. Granted, this boils down to the sporadic use-case, but that's the entire point.

The replace examples are all clean. It would mean I would not be juggling little peculiarities of arcane syntax, such as which sed flags to invoke, or whether to use exec or xargs.


I agree. I've used Linux for 18 years, and I'm comfortable with all the find and xargs use. But sed is too obnoxious. Beyond the extremely trivial, I'd do stuff in Ruby instead rather than bother with scouring the sed documentation to figure out what I need.

I might have an issue with doing a replacement in JS for node, though. But for those who are already using node, why not.


Then take the 5-10 minutes to scan the man pages. Write a simple shell script wrapper exposing a syntax as simple as "replace". And be done with it in 15 minutes top. It seems to me that writing all this js code would take a lot longer than 15 min.


The issue is that it's 5-10 minutes to scan each man page every single time I want to use sed, find, xargs, etc.

I quickly reach a point where I just think "Fuck it, I'm writing a Python script for this."

A simple tool that only takes a couple of minutes to learn, then a five second look at the man page to refresh the syntax is very valuable, particularly if it focuses on doing the one job that people want to do most often.


You completely skipped over reading his post, and thus your response makes no sense. Read the docs once, and write your weird syntax version as a shell script. Then you don't need to look it up ever again, because you are using the weird syntax you invented for yourself. It is just much simpler and easier to do it the reasonable way than to write it in javascript.


I didn't misread it at all. I just completely disagree that it's 10 minutes to work out how they all work. And that's every time you want to use them, because few people use them often enough to learn the tools properly.


You said:

> The issue is that it's 5-10 minutes to scan each man page every single time I want to use sed, find, xargs, etc."

Which means you could put in a one time investment, write a wrapper shell script, and be done.

And if you insist on disagreeing still, then that's fine, but the this whole point was brought about in response to:

> I've used CLI tools for years, and it would probably take me 5-10 minutes of scanning the man pages to reproduce all but the simplest of those snippets.


You keep saying that you have to research how they work every time. But we tell you: no, you only have to write the wrapper shell script once. It is a one-time effort. Just like harthur put a one-time effort in writing "replace". You wouldn't have to remember find/sed every time, just like harthur doesn't have to re-write "replace" every time.


You are the one who claimed 10 minutes. If you didn't misread, then you are deliberately ignoring what people are saying just to be obstinate.


I think the point everyone is trying to make here is. Should every person spend 5-10 minutes doing this?

If the problem occurs too frequently, it makes more sense to make the solution re usable. Which is exactly what 'replace' is doing here.


> I think the point everyone is trying to make here is. Should every person spend 5-10 minutes doing this?

Exactly. People tell me "Nobody needs ack, you just write wrappers around find+grep" and I say "You could, but I published it and now people don't have to."


This reminds me of the first of Larry Wall's three virtues:

"[Laziness] makes you write labor-saving programs that other people will find useful, and document what you wrote so you don't have to answer so many questions about it. Hence, the first great virtue of a programmer."


I use ack, but that's because it searches for the right file types, ignores source control directories automatically, and has pretty colors, not because it's find+grep.


Other than "pretty colors", your statement contradicts itself. Doing the things you mentioned is being find+grep. That's the entire point of ack, to be find+grep.


I didn't say that find couldn't ignore source control directories or find only specific file types. However, ack does that far better as it has a better semantic awareness of both concepts.

I don't have to worry about updating my find command lines to account for new types of source code or source control folders in unfamiliar programs, I need only ensure that ack is kept up-to-date.


I'm not sure what you are trying to say. Your post contradicted itself. You literally said "I don't use ack because it is find+grep, I use it because it is find+grep". I am simply pointing this out.


Except by that logic, you could say that any user of a high-level language was really claiming (in the end) to be using assembly.

C++ once compiled to C, but even then people wouldn't claim they were using C, they'd claim they were using C++. "I don't use C++ because it's C with 'classes', I use C++ because it sets up my vtables and overloaded functions"


That analogy makes absolutely no sense. You are claiming an intended use. And then contradicting yourself by saying you don't use it for that intended use. The analogy would be "I don't use C++ to write programs, I use C++ to write words that have a particular syntax that a C++ compiler can understand and translate into executable machine code". And that statement is just as contradictory as the one you made.


The point everyone seems to be making is that there is no reason to do this in javascript if it's for command line use. Implementing it in js like this is just silly.


JavaScript has a widely used, native regular expression engine. That's enough technical defense on its own for that particular design decision, besides the usual, "Reimplementing a unix command-line tool in your favorite language is always a useful exercise."


Then write it once and share the wrapper script on github. No?


Why do you have such a strong objection to someone spending their own free time to simplify and / or mimic [insert unix tool functionality here].

It clearly serves a purpose and it's apparently useful. Most importantly, it exists, so there's no need to argue over how you think it should have been implemented.

I'm sure if you were to release your own [script / wrapper], someone would find use for it, in the same manner that some have apparently used 'replace'. I honestly fail to see the big deal here.


I know it someone's right to do this, of course. I object because I come from an environment (software industry) where I have spent hundreds of hours undoing people's poor jobs where they wasted time and money reimplementing (incorrectly) library functions, system commands, etc. Because of this personal experience, I reacted the same way many reacted when seeing her script. So, I decided to explain to her and attempt to convince her that she should have spent her time and skills on something else (especially because she seems a rather good programmer!) Does it make sense?


I object because I come from an environment [...] where I have spent hundreds of hours undoing people's poor jobs where they wasted time and money reimplementing [...] system commands

What you fail to take into account is that there's definitely a niche for Node.js-based development tools such as this script: The GNU userland is not ubiquitous.

Node.js did not come with a system command to search and replace across files - now it does.


It's a one off tool, unlikely to be used in any project you are writing software for. She provided the source code freely, and the code isn't bad at all.

I fail to see why you will ever need to rewrite this?


Fair. I can see where you're coming from.


You have better things to do than tell people to invent time machines to go back and not do things that are already done.


C'mon we are long past the days where tools had to written in $somelanguage. These are days where even things like compilers and databases are not being written in C.

If its of any help I think its time for the Unix community as a whole to sit down and self reflect. If people are beginning to think something like 'sed' as too level to use, then better job needs to be done to make them more accessible and usable. There are enough examples on this thread where people are saying that they look at sed as an API on top which a program needs to be built up on. And not a complete program in itself. Also shell is not a full fledged programming language.


I respectfully disagree with you here. The beauty and the wonder of these small command line tools (for me, at least) is that they are a) small and b) fast and c) ubiquitious. I do a lot of data manipulation, and while I'll do anything complex in a real programming language (with a REPL) sed, awk, grep and find are really really handy for quick data finding and manipulation.

Any new API on top of them would only be present on a fraction of machines, and thus would reduce the major advantage of them in that they are available everywhere.


Wow, you actually stated something that was wrong enough to force me to comment. The beauty of these tools are that they are small, fast, ubiquitous, AND easy to replace with other tools if they fit your problem better. Unix was built exactly for swapping in these small one-off programs and to deny that is to deny the beauty of it's design and to basically ignore the fact that the system is built to string arbitrary programs together to solve complex problems in simple ways.

One advantage of her Javascript replace is that she can drop it on any machine with a Javascript runtime and it will work, unlike sed.

And the real truth is, she wrote something that solves a problem she has, which is the measure of her success, not someones arbitrary comments.


> It seems to me that writing all this js code would take a lot longer than 15 min.

Probably, but I can't really speak to that.

Either way, we were originally talking about the syntax & implementation. It doesn't make a lot of sense to object to a hobby script on the basis of development time.


Well, the whole point is that writing sed-replacement in the language of your choice really is simpler/quicker than learning to write decent "simple shell script wrappers exposing a syntax".

Such wrappers aren't lingua franca anymore - nowadays they are as arcane and as COBOL, since [for most X] it's easier to write a perl|ruby|JS script to do X than a shell script to do X.

Starting from scratch (say, from a Win background) it might be easier to learn a language like Haskell or Scala than to learn the shellscript language with the whole pack of sed/awk/grep/etc flags and tricks.


Add another 30 minutes or so for learning how to write a shell script. I mean how to pass variables into a shell script and stuff like that. Actually no idea if 30 minutes are sufficient for learning how to write shell scripts (it can get pretty confusing with environment variables that are suddenly not available and what not).


Who cares how long it took the author? The API is what matters. And I personally think her API beats the snot out of obscure sed, awk,and grep compositions.


I've been coding since 1993 and I have never made room in my brain for stuff like -print0.

Moreover, there are times when you'll want to do this stuff from within another program. What are you going to do, shell out to a find(1) pipeline? Then people like me will be giving you shit.

There's nothing wrong with rewriting sed in Javascript.


> There's nothing wrong with rewriting sed in [X]

Indeed, especially since there's sed and sed.

The examples given use -i, but no luck with BSD sed, where you will use -i~ at best. Also, lack of -e before the expression may make things blow up at times. And the sed regex does not support stuff like +, so many times I end up replacing sed -i~ -e with perl -pi -e or ruby. Besides, sometimes your looping logic is not implementable with a find easily or at all, especially when its context is readily available in the original language, so maybe you use the CLI at times, but this CLI might just be a frontend to a lib part saving you from forking a thousand times over.


> And the sed regex does not support stuff like +

Are you talking about BSD sed here, because GNU sed does support + with the -r flag.


The problem is that it's hard to use sed portably, because GNU sed's "-r" is "-E" in BSD sed. (There's also the differing behaviour of "-i" as mentioned earlier in the thread.)


Not it's not. GNU Sed compiles pretty much everywhere. Just use that.


And nobody seems to have mentioned the fact that to run this script you'll need to install node and npm (although you can argue that node comes with npm, but anyway…). You might as well just install GNU sed in BSD if that's the problem. Also, I believe GNU sed is much faster than any javascript script.

Moreover, if you want to use this as part of your node app, then it's a good reason to reimplement some of sed's functionality.

I still don't see why you'd laugh or ridicule someone else for doing something like this, and sharing it (if anything at all, it serves as a good tutorial on file manipulation with javascript/node IO.


"You might as well just install GNU sed in BSD if that's the problem"

Often not possible depending on what authorizations and hosting you have.


What are you talking about? Yes, GNU bloatware is massive and hideous, but it is still far easier to install than javascript + framework + package manager + package. If you don't have the ability to run binaries in ~/bin then you can't use this sed alternative either.


I took it that I already had node.js installed because that's what we were using. Asking for a replacement for an already existing sed is probably not going to happen.


You don't need to ask unless /home is mounted noexec. It seems rather absurd to assume a seldom used and rather massive ecosystem of language, libs, framework and package manager are installed, but that it is impossible to upload a copy of gsed to ~/bin. The number of shared hosting environments where you can't run your own code, and you already have node installed is miniscule.

And although its getting a bit off-topic at this point, doing replacements directly in the file isn't even a good idea. The standard "move $file to $file.backup, run sed against $file.backup and pipe it into $file" method is not just recommended because it is portable, it also saves your ass when you messed up your search+replace and broke all your files.


"You don't need to ask unless /home is mounted noexec."

You'd be surprised what is restricted in a lot of corps beyond the "approved" software list. It is amazing what big things get approved and what little things don't.


No I wouldn't, I've dealt with them extensively. I have no idea how that is relevant though. If Enterprositous Corp X needs a way to do replacements, they install one. They would have to install node and a ton of other crap anyways, why do you pretend installing a single trivial binary is beyond hope of possibility, but installing a huge language+framework ecosystem is totally cool?


You just made his point.


Or by escaping: \+ I didn't even know there is a -r option, I always escaped the plus sign (and parentheses)


I looked up what print0 does as I use find and xargs a lot.

Here's what print0 does - it separates the filenames with a null byte so that names containing spaces and newlines can be interpreted correctly.

Hopefully someone else will find it useful.


The TL;DR of -print0 is just to make sure find works with all kind of weird filenames.


Wish I knew that a year ago. Really.

On the bright side, normalizing file names before batch-processing them was a good idea too.


Also - it's much easier to debug the equivalent dynamic language's code than to try to figure out what went wrong in your xargs pipe.


" I've been coding since 1993 and I have never made room in my brain for stuff like -print0."

Seriously? find/xargs is nearly impossible to use (safely) without it.


I use find|xargs pretty much exclusively for /usr/include and in my source code directories. Anything more complicated than that and I tend to be in an irb.

So you know who you're dealing with here, I used Emacs for something like 10 years before I figured out how to do regexp search/replace.

I'm pretty comfortable with my abilities as a software developer. If I was Steve, I'd be about as embarrassed about the idea that someone's "level of understanding" of find|sed|xargs was worth commenting about as I would about the rudeness. Of course, if I was Steve, I'd have apologized privately and not fed into the shitstorm, too. :)


You never need things until you begin to need them. If a way exists to solve your problems without learning arcane syntax people will take that way.


IMO, if you deal exclusively in shell on UNIX-alikes, you'll likely only need -print0 once in blue moon because people just don't tend to create filenames with spaces or other amusements in them. The instant you add Windows to the mix, suddenly it's the best feature ever and becomes the default for any 'find -print0 | xargs -0 ...' pipeline.

I also think that binary sized string should be the default for shells and command pipelines; plain text was great in the 60s, but it's now the 21st century and I use too many shell flavours on too many systems to remember their arcane quoting rules, locale rules, unicode bugs, etc.

Regardless, it's a shame that there's not a standard separation of UI from functionality in all these utilities - more than once I've wanted to just be able to dynamically link libsort.so from another program because writing files and exec'ing ... urgh.


You might be surprised at how often a filenames I make is OSX becomes a PIA (because of spaces) to handle in the terminal.


Sure, if this were intended for doing it from within a JS program.

But it's not. It's a command-line tool. To replace the best, most powerful, most flexible, most stable tool (and additional tools) made for the command-line for this exact purpose. This is the definition of reinventing a square wheel. It's just a bad idea.

(p.s. by using xargs (with or without -print0) you can use one option to parallelize the function, vs writing it all in your own code. but i guess getting mad over a fork/exec call is a better idea)


I'm not going to downvote you, but you've not really put your case. Using replace simplifies the workload for a lot of people, the commands (which incidentally, I actually like using) is still somewhat arcane even to the most experienced Unix guru.

If you can replace a long line of pipes with a simple command line, then why not?


Perl was created as a replacement for sed, awk, grep, and other tools of the day. It can be used as one command to perform anything you could ever want to do, with a minimal amount of typing and several command-line arguments to perform useful tasks with ease.

When admins use it, they often simply shell out to the identical console tools. Why? It's easier. They just do everything you need, they're universal, and they work well together.

Go ahead and write a new Perl in JS, and nothing will change; the console tools will still be there, better than anything else.

I agree that it simplifies the workload. Unfortunately, it does not reduce the workload.


Yeah, when I first saw this project I didn't get the big deal with why it was so bad. Something I might of done if I could have found the time. It probably made doing something easier for a time. I've also never liked using sed much and pretty much have to re-read the man-page and google around a bit almost every time I have to use it again, because I just can't be assed to remember how it works.


One of the subtler issues I've had with piping find in a scriptis that you end up calling a program N times instead of just opening N files in the program.

So if the program has overhead when loading, using a -r option instead an outer find loop can make a magnitude of difference to program operation.


Look at using find's --exec with the + ending instead of \;.


Please, tell me you're jocking: on your platform you cannot afford a pipe but you can launch node.js?

by the way: "-print0 | xars -0" is really idiomatic, you know? Lucky you didn't have a single filename with spaces to handle...


I don't know what this even means. I'd already be running v8 runtimes. They're unavoidable. But there's no need to fork and exec (many times over) just to sweep a filesystem tree for files matching patterns.

It's the shell, by the way, that cares about "spaces in filenames". Not dicking around with shell metacharacters is just one of the many wins you get by not shelling out to accomplish basic programming tasks.


I get what you're saying for the "already in a REPL" thing, but as far as fork/exec overhead, xargs does a single fork/exec for every thousand or so files you search; the overhead is tiny compared to everything else.


Not even that, but xargs can also be made to run N processes in parallel ('xargs -P N'), making a find|xargs sed pipe perform much better than anything you could easily invent on your own.

Note that 'xargs -P' behaves very similar to 'make -j' and is often useful as a simple work-unit scheduler.


"find -print0 | xargs -0" handles spaces in filenames perfectly correctly.


That's his point.


If you use GNU Parallel instead of xargs, then you probably never need to make room in your brain for -print0. GNU Parallel separates on \n and deals correctly with files like: My brother's 12" records.ods


Yes, find options are very strange, and it's certainly flexible, still, the learning curve is steep going beyond the basics

Still, someone probably rewrote something similar to sed in JS


To my (naive) eyes, your examples act as a compelling advertisement for her library.

The sed/xargs/etc. examples look increasingly like impossible-to-memorize line noise to me, while the --include, --exclude etc. options in `replace` are comprehensible and seem to follow standard command line argument practices.

Again, this is from a very entry-level unix tools perspective, but there it is.

It also seems to me that reimplementing things with the stated goal to make them easier to use has to be one of the best justifications around, no?

I hope I sound as respectful here as you did in your comment -- I certainly appreciated seeing a clear response to her library, so thanks for that.


Impossible to memorize? I wrote all these examples from memory. I tested them in a shell and had a single error (sed -ir needed to be changed to sed -ri because -i takes a glued "suffix" argument). I really don't think it is that hard to memorize the basic find/xargs options. You only have to memorize them once in your lifetime. They are a basic cornerstone of a Unix skillset. By comparison, I often forget the custom syntax of my custom scripts I wrote years ago.


I can write complex vector math in C from memory - doesn't mean everyone needs to be able to do it.

That replace library does what it's supposed to do - it replaces shit easily.

Don't like it - don't use it.

If people want to do more - then they'll figure it out for themselves. For everyone who already knows more - eat some humble cake.


>Don't like it - don't use it.

This is a false dilemma and completely misses the point. The replace library was written by a person who either never heard of or never learned how to use SED. Just because they created their own hack as a workaround doesn't mean it's the right thing to do.


Why would you assume that, because they wrote an alternative to an existing tool, they don't know how to use it? Perhaps she just doesn't like sed, or would like to use the replace functionality in an environment where it's not clear ahead of time whether GNU or BSD sed are available. Or any of a number of reasons. Your assumption that she must be ignorant to have created her own solution is just as boorish as the original tweets, imo. Was tmux written by a person who had "either never heard of or never learned how to use" GNU screen? What about GNU itself? Why bother when UNIX already exists? People have lots of reasons for writing software, and deciding for them whether it's "the right thing to do" because some other software already exists is absurd.


Just because it does something that you like to do a different way, doesn't mean it is hurting anyone for someone to write it.

By this logic, there is no way for beginners to write much of anything since there are existing implementations of almost any idea, and it should be disallowed ever to make a new thing which could replace any old thing.


If you take a look at the readme, the first commit back in 2011 says this:

"It's similar to sed but there are a few differences:" and then goes along to list out the differences.

I would expect this person to 1) have heard of and 2) have learned to use sed in order to write a tool that is similar but has slight differences in syntax to sed.


There is no wrong thing to do when writing tools for personal productivity, as OP clearly stated. If it works, it works. If they decide to open source it, that's great. Maybe someone has use for it. The end.


If a program is nontrivial to learn and use (as the sed examples shown in mrb's post illustrate) then a good solution is to make a better, more easily usable tool tan sed.

As for editors - there is a niche for emacs and there is a niche for notepad. If a program is weaker on some aspects but clearly superior in another aspect, then it has a valid niche and making it really is the 'right thing to do'. Usability/discoverability is a very important aspect of software, and sed is a bit lacking there.


> Just because they created their own hack as a workaround doesn't mean it's the right thing to do.

Are you honestly at HackerNews posting that someone hacking together some code to scratch their own itch is not "the right thing to do"?


Right is arbitrary.


Please don't follow up a false dilemma with circular reasoning.


Guess you've never heard the KISS principle. So what if you can remember arcane commands? If there was a "replace" program, I'd be sure to use it. I understand all of these as well, trying to pipe them together or to use a "replace" command - I'd choose replace every time.


It would appear they're the basic cornerstone of YOUR unix skill set. I spend all day in *nix, I didn't understand everything you wrote there.


>Impossible to memorize? I wrote all these examples from memory.

Yes. And people can site Pi to the 10.000 digit. Doesn't make it any less useless.


The arguments to common UNIX commandline tools like sed or xargs are without doubt going to be longer-lived than the arguments to your helper script, likely even longer than the language your helper script was written in, and maybe even longer than the idioms and philosophies you had in mind when you were building your tool(s).

Calling the basic operation of these cornerstones "useless" speaks more about your disposition than the tools, I think.


>The arguments to common UNIX commandline tools like sed or xargs are without doubt going to be longer-lived than the arguments to your helper script, likely even longer than the language your helper script was written in, and maybe even longer than the idioms and philosophies you had in mind when you were building your tool(s).

Yes. Sad isn't it?

It's not as if they were perfect when the were designed.


There's another reason to reinvent the wheel:

    $ replace "Foo" "Bar" 
is common sense and easy to understand.

Not to mention that sed -i is a GNU extension.

I haven't used replace but it seems like a pretty innocent piece of helpful code for someone who likes JS.


I agree and also I took a peek at the code and my eyes did not bleed... it's a nice little one-off that doesn't try to do too much and is written in a decent ad-hoc manner... what's wrong with that?

Heather, you've created a nice and useful tool with a modern tool-set, did a very decent job coding it and took the time to open-source it. In my eyes at least it puts you in the top 0.01% of coders in the world.


I actually had something similar myself, a shell function called findRE, the entire purpose of which was to automate searching a given path recursively for a given regex.

However I used it so infrequently that whenever the need would arise, I would invariably screw up the order of the 2 (only 2!) arguments. I could have added support for --help, --usage or similar, but that seemed like overkill.

I eventually just learned how to "properly" use find and grep (both of which I was already using anyways, which helped me remember the command line for each).

With that said I do agree that I'd never use shell script or Unix userland on purpose when writing scripts that are intended to be portable across different Unices (or even Windows), that's the kind of thing I'd reserve for personal use on my own userland. Hell, even on one machine you never know with some distributions what kind of shell you'll login to by default...


Am I the only one who finds replace's syntax much nicer?

I haven't spent much time learning unix utilities, so that might explain it. But I can't help but shudder at find . -type f ! -name '.min.js' ! -name '.py' -print0 | xargs -0 sed -ri 's,var,let,g'


She was able to simplify her command line interface in order to support only the features she needed, so of course her syntax is nicer. Whereas sed/find/xargs can do a lot more things, so of course they come with a more evolved syntax.

It is the usual tradeoff between simplicity and features.


Right... she had different requirements, so she wrote a different tool. Which is why I find your near-rant above somewhat disturbing. It seems predicated on a (seemingly) very arrogant belief on your part, that you know more about what harthur needs, then she does. Personally, I am very sceptical on that point.

There is only one case that justifies reimplementing things

Or, um, how about the one that goes "I felt like it"? That's sufficient justification in my book.


Yeah, who needs TextMate when you have vim, right? Or Ruby when you've got Perl?


I beg to differ on your first argument. Learning Vim was one of the best decisions I've ever made in terms of how I write code. Other editors feel like toys in comparison.

I'm siding with mrb on this one. Learning flexible tools gives you immense power in comparison to low-learning-curve ones. The time invested is considerably smaller than the time spent figuring out how to solve edge cases with simple tools. This is something which appears to be impossible to communicate to people with words. Learn some of these tools and you will see for yourself.

By 'learn' I do not mean, for example, becoming familiar with hjkl for navigation in Vim. I mean mastering the tools to the point that using them requires no effort - where just as you experience the impulse "I want a glass of water" and without any effort go to fetch one, you experience the impulse "I want to create a new class in file X, navigate to file Y then modify method Z", your fingers start moving and suddenly you're done. I get frustrated watching my IDE using co-workers write code - it takes them a very long time to do very simple things. Their tools are narrow and do not facilitate expression - they constrain it.

Pre-emptive strike on the argument that code completion is better - Eclim (Eclipse with a Vim frontend) solves this problem very well. Nonetheless, I have it installed and configured but can barely find a use for it.


My only point is that what's right for you isn't necessarily what's right for everyone.


Exactly, and its something happening all the time and many people seem to like it. If not, everyone would be using Linux Desktops vs OSX/Windows, vim/emacs vs Sublime/Textmate/an IDE, plain ruby/python/etc vs Rails/Django/etc, OpenGL/DirectX vs Unity/any Game Engine etc.

Even in the consumer world, this is Apples strongest selling point for example. Make products simple and easy to use, but still do 90% of what anyone would want to do with it. If that isnt enough, there are other things to use.

I think the same can be said over replace. I find your skills with sed/grep impressive and its certainly very useful in some cases (mostly devOps) but in case i need it myself i would just look it up and in the meantime use simpler tools and get the job done.


>If you care about simplicity, I would personally rather write a small shell script wrapping find/xargs/sed and hiding their arcane options, as opposed to writing 173 lines of js.

I would rather use my language of choice to implement the above (mine wouldn't be JavaScript, but it clearly was Heather's) than to research all of those arcane command lines.

Rather obviously YOUR language of choice for this kind of problem IS sed. So OF COURSE you would use a shell script wrapping sed etc. to implement these functions.

But guess what? To handle all of those options at the command line would still take a pretty large fraction of 173 lines of code, if you added in an equivalent level of parameter checking and option handling.

And if you want to make MY eyes bleed, hand me a file with ~150 lines of logic in shell script that spawns cryptic command lines. Despite not REALLY knowing JavaScript, I would much prefer to maintain the JavaScript than a shell script with the above commands.


I'd present the argument that, once you learn sed, it has the possibility to replace more then just this 'replace' command. If you tend to live a lot on the commandline, you'll naturally start using it where appropriate, and become more familiar. After learning how regular expressions work, it really amazed me how many things I used to think "I'd have to write a script for this", when now I just write a quick line of sed.


I believe that your complexity estimate in writing the wrapper indicates you are perhaps not a proficient shell scripter. However I sincerely believe it is possible to write such a wrapper in less than 15-20 lines. The trick is to do as little argument parsing as possible but enough to be safe (for example pass the ! -name "*.min.js" as is to find).

PS: I will do it in 15-20 lines, if only to prove a point, if someone sends 1 BTC to 1F43fceWvwznv4rH7s1B3du2w5VznFJY58 :) (yes, my time is valuable - I have other things to do)


No interest in seeing a proof of concept. And I make no claims about being a "proficient" shell scripter: You've nailed me there. I can write a shell script if I absolutely have to, but I avoid it when possible since Bash is such a terrible "language."

When I DO see non-trivial shell scripts, they are just this side of arcane gibberish. The command lines above are completely opaque to anyone but an expert in EACH of those tools (I know some of the tools, but not all well enough to know EXACTLY when I need to backslash a paren, or how many backslashes to use, or when I need quotes or not...).

When I see the JavaScript that spawned this conversation, despite not knowing JavaScript well at all (probably about the same level I "know" shell scripting) I was able to follow everything that was happening to the point where tweaking it to add features would have been easy.

The objective shouldn't be to write code in the fewest possible symbols. Everyone would use APL (or a more recent evolution of that language) if that were the case.

The fewest possible readable and modifiable lines of code is my objective. Shell scripting tends to have lots of obscure and unpleasant syntax to accomplish the most basic flow control.


I'd ague that her version is at the very least syntactically much easier to use.


Hear hear!

I've had a sed book on my shelf for years and I've used it more than once, but 99% of the time I end up giving up on sed and using a GUI-based tool instead of trying to concoct the cryptic lines given above as examples.

I absolutely would rather use the clean interface of replace, written in JavaScript or anything else, than to memorize that steaming pile of cruft.


Two reasons why it's better to memorize the cruft:

1. You can pipe find/sed/grep/cut/awk/whatever to other utils. Today you might be replacing, tomorrow you might be analyzing text logs, and the more core utils you learn the more things you can do with them.

2. When you're ssh'd into another box that doesn't have that spiffy replace utility, now you don't know how to do an inline replace.


> 1. You can pipe find/sed/grep/cut/awk/whatever to other utils. Today you might be replacing, tomorrow you might be analyzing text logs, and the more core utils you learn the more things you can do with them.

Fair.

This boils down to an individual's needs. I think most people in a position to be making this choice are fairly well aware of what's possible with standard nix CLI tools, and can decide whether or not to invest the time to learn them.

In my experience the ROI for nix wizardry is fairly high at first, but begins tapering off. There are a half dozen or so command chains I use daily without which I could hardly see myself working, and the rest I may not touch for weeks or months on end. YMMV.

> 2. When you're ssh'd into another box that doesn't have that spiffy replace utility, now you don't know how to do an inline replace.

It doesn't make sense to optimize a workflow around an edge case. You don't often hear this brought up as an argument against dotfiles, key bindings, vim plugins or what have you.


You actually do hear this brought up as a case against dotfiles and vim plugins, even the use of vim as opposed to vi. There is just this school of thought which says you should never use anything which isn't in a default CentOS install.


As a sysadmin, I can totally relate to those thoughts.

If you run nonstandard, you basically have to learn vim/vi as a default install for an OS and another with all your add-ins and customization. Sure the key bindings are similar, but I don't have my macros and why is my tabbing funny, there's no line numbers, and damn it, the backspace key doesn't work. I forgot I set that in my .vimrc.

Sure, I can remember most of the latter with set tab and set no, but when you're popping around systems, switching to root (with it's on .vimrc), keeping applications as stock as possible is very helpful.

I personally have a slightly custom .vimrc for my local use, but I don't rsync my dotfiles across the globe for my other home directories. I basically try to keep it as code development (with .vimrc) and sysadmin (may not have niceties, but I'm not editing code).


I know the core basics of find/sed/grep and I've even used awk on occasion (though I typically have to Google for that one), and occasionally I use them when I'm ssh'ed into a box.

But as soon as I want to do something more sophisticated, I again reach for the tools I know better.

No I can't use my GUI tool on a box I'm ssh'ed into, but I can push my changes to a git repository and pull them to be local, where I can do complex things really quickly and without having to memorize tons of obscure options and corner cases.

In a case where that's not as feasible (hundreds of megabytes of log files, say), and what I need is beyond my find/sed/grep skills, I usually drop into my language-of-choice and produce a tool that is much easier to use for my purposes. Honestly I haven't touched awk in a long time because the pain is so much greater in awk to accomplish what I can in my own more familiar toolset.

I get that those tools work fine for any old-school Unix hacker, and the combination is quite powerful in its own right. I don't have the desire to BE an old-school Unix hacker, though, and my tool-set is quite powerful enough to accomplish what I need without going through that particular hazing ritual, thank you.

My need for tools like this happens rarely enough that even if it would be faster once I'd learned the tools to type out the appropriate command line, the amortized time to GET to that skill level in those tools would be far more than the time it takes me to just use my "less optimal" tools.


Your argument that it wouldn't be available on other boxes can be applied against any new command, no matter how fantastic, so it doesn't seem very constructive to me.


I think it is a good argument to learn basis before reinventing the wheel. When using unix, there are already far too many commands to learn. Not having to learn useless commands is a bonus.


And yet, it's not useless to so many.


1. Perhaps learn that when you actually need to analyze text logs?

2. Perhaps you don't need to do this. Or perhaps you'll work it out when you ssh into another box.


i've downvoted you while i wanted to upvote you.. wtf.. i agree with you


Thank you for taking the time to write these translations. In fact, I'm going to bookmark this thread and use it as a reference in the future.

I feel these examples serve more as a selling point for why one would use something like `replace` over a cacophony of flags and pipes. The interface for `replace` is simple and elegant. It does one thing, and it does it well. I think that's commendable.

P.S. The `sed -r` flag does not exist on POSIX systems like OSX. You'll have to use something like perl -pie, or write a convoluted buffering loop.


Or install gnu sed


I don't even get what the issue is. People have a problem that she even wrote this? I wrote something similar because there IS no standard replace tool along the lines of grep. Sed is awful (it's essentially impossible) for multiline expressions for example. Could this really be penis measuring because people think they are so cool that they know unix commands exist? Congratulations, you have turn invocations of a simple, convenient tool into a shitpile trainwreck of find and sed. Golf claps for infinity.


You have a valid point but its incomplete, allow me to explain you why we need projects like replace.

You are right in telling that sewing a few utilities using pipes can emulate 'replace'. But remember you are talking about learning those 'few' utilities first. Trust me unless you have practiced your way out of these thing with hundreds of hours with experience over years its humanly impossible to remember and use a tool like sed to its full capacity. The more utilities you add to your pipe chain the number of ways in which these utilities can be used more or less follows a exponential curve.

Now if some one comes along and gives you a version 1 of a tool that can simplify these things and give you simple way of doing things in a command instead of doing it with a ten pipe chain commands, he/she is ideally solving a problem of a great importance.

As some one who loves the Unix CLI, I have often wondered why people spend a whole day writing a java program what could have easily done with sed and awk in a line or two. But these days I understand why. Learning and using sed/awk to their full potential is a time consuming task. You not only have to learn them factually through a manual. You also need to study the problem cases for which they are appropriate. Then you need to go and put their solution patterns in your brain. Then you need to map all problem patterns with solution patterns. Then you need to learn all the arcane special cases. Generally this comes to a person over years practicing those utilities.

As a matter of fact Perl was invented because using C, with all these utilities was getting very difficult.

Now if somebody can give things like these. Which do many things out of the box, without you having to go through the pain of learning things and practicing over the years. They would have indeed given you a tool of great value.

In my experience even if some one fails working on something like this, by third or fourth version of the tool they generally come up with a thing of great value.

Think of this like Vim Vs Sublime Text 2. In case of vim there are ways of solving problems. In ST2 many of those solutions are automated and sometimes given to you out of the box.


I have just publish a report on monday where I explain that the command line should be used instead of some small scripts that encapsulate for loops.

The argument is that basic shell knowledge should be trained in order to not lose skill (or to improve). At my work, these skills are useful when facing unexpected urgent needs.

Having a short script is a very poor benefit (simpler syntax and reduced key typing) for a big loss: - loss of knowledge - loss of understanding of what the script is doing - need to learn the name of the script which is not a reusable knowledge.

Learning the basic usage of sed, awk, shell is an investment that is quickly rewarded.

Learning all the intricacy of "replace" needs to know many javascript details and how they interact with shell escape sequences and your LOCALE configuration. I am sure it is less documented than the sed command.


This is like saying you should learn C before using [some-lang] when all you want to do is cobble together a web page. Yes, it might be beneficial to some, but it's not absolutely required.

Some people just don't live in the shell. We're taught to build upon useful building blocks to make useful things - why would you not abstract away the monotonous tasks?


All I can say is I'm glad I don't work somewhere where someone writes a report on how I should get my work done at the most basic level.


It is a report on How and why I have done my work the way I did, What were the advantages and disadvantages, What could be done to improve the process.

This kind of reports are useful for people doing similar activities.


> There is only one case that justifies reimplementing things

Who are you to decide how she may spend her time? Why in the world do you think that she has to justify to you what projects she creates?


The clear answer is probably appreciated however the implication that reimplementing something needs to be "justified" is absurd, even setting aside the fact that the syntax you use is representative of the arbitrary, inconsistent, and generally horrible CLI of unix commands, and does not represent a good case against implementing a better interface. Open source is packed to the brim with "reimplementations," some out of ignorance, some for learning, some to improve, some to port to different languages, some for ego, some for principal, and some for many other reasons.

Frankly the code is hardly deserving of derision. It looks perfectly capable to me, and the syntax is far superior to arcane unix commands. Just because you'd rather write a sed wrapper than write this code doesn't mean it makes sense to deride others for trying to move the human race forward.


Some of my examples can be further simplified (no -print0, no xargs), without a perf issue ("{} +" passes multiple filenames as arguments), with GNU find which is standard on Linux:

  replace 'var' 'let' . -r
  find . -type f -exec sed -ri 's,var,let,g' {} +

  replace 'var' 'let' . -r --include="*.js"
  find . -type f -name '*.js' -exec sed -ri 's,var,let,g' {} +

  replace 'var' 'let' . -r --exclude="*.min.js,*.py"
  find . -type f ! -name '*.min.js' ! -name '*.py' -exec sed -ri 's,var,let,g' {} +
To all the Unix shell critics: don't try to argue that writing a 173-line js script is "simpler" than learning 3 find options (-type -name -exec), the bang(!) 'not' operator in find, and 2 sed options (-r -i). This is just wrong, seriously.


>To all the Unix shell critics: don't try to argue that writing a 173-line js script is "simpler" than learning 3 find options (-type -name -exec), the bang(!) 'not' operator in find, and 2 sed options (-r -i).

In the context of discussing the open-sourcing of the script, the issue isn't really whether or not writing the JS is simpler than learning "3 find options", it's whether using the JS is simpler than learning "3 find options".


You are still wrong, she is still right. If we wouldn't have to care about either 1) the resource use or 2) the easiness of use, then most of the programming would be unnecessary. Her solution is better than yours on 2) always, and on 1) as soon as you need that functionality in node.js contexts.


You are wrong about #1: her design goal was use from the command line (according to her readme), not from node.js.

You are wrong about #2 too: I have said this 5 times already: you can write a very short (much shorter than 173 lines of js) a wrapper shell script exposing an interface as easy as "replace".

Please read what I wrote!


Even if she designed it to be used from the command line, and this is still not the only possible use of the JavaScript code which she open sourced, she had one more reason: sed doesn't have JavaScript regexps. Anybody who really wants to use JavaScript regexps doesn't have other choice but to use her tool. Now you can say that you don't need that, but you still has to admit that others may. So you're still wrong.


With all due respect, you add nothing to the discussion, I already acknowledged this in my OP:

"There is only one case that justifies reimplementing things: if your tool has the requirement of supporting the exact js regex syntax..."

(Please read what I wrote, really!)


a) Can you agree that the main reason of open sourcing a JavaScript code is for others to use the same code in their projects, not to "run the command line"?

b) Regarding those that do want to "run the command line," can you agree that there are users who really want and need to use JavaScript regexps from the command line and not some other regexps with different semantics?

c) Can you accept that these are the valid use cases that your "use sed" arguments just don't cover?

I've read your arguments and I've never seen clear acceptance of a) b) and c). I've also seen that you had to carefully think and even improve your "use sed" implementations, giving also the good argument in favor of her approach. Having the tools that demand less from the user is a good thing. Can you accept that (d) too?

Can you see why we discuss, when you just quote yourself as "There is only one case"? That's why I claim you're wrong. There's not only one case.


You don't need to write a 173 line js script, in the same way you don't need to write the thousands of lines of C code behind find or sed.

You just use it.

Let's face it. Most people will never bother learning shell commands in and out. I've been a *nix user for 20 years and I still have to be checking man pages, and I often stumble upon basic shell command options running differently in different shells.

Other than for sysadmins, shell commands are going the way of the dodo. This isn't new, it's been happening for many years already. Increasingly capable computer people from the newer generations will be focusing their skills and time elsewhere. Arguing against this reeks of grumpy old coder bitterness. I know my shell stuff and it serves me well. I use vi/vim daily. I don't impose my usage patterns or expect that something "existing" means it's appropriate for everybody.


Replace looks a LOT cleaner to read and write though and more intuitive though for smaller/simpler things such as these examples.


Learning how find, grep and a bit of sed works is a better investment of time, they have a broader use than this replace utility.


I can think of no better advertisement for replace than this post.


both Perl and Python use PCRE

No, Perl doesn't.

PCRE was written because a lot of people liked some of the ideas that were first introduced in Perl's regular expression engine. But PCRE was a reimplementation, and never was all that compatible with what Perl was doing.


The funny thing is, that Python doesn't use PCRE either and never had.


True enough. It's not the first time I hear about PCRE and Python, so maybe it's a common misconception.

Other than "re", there's "re2" and "regex". None are PCRE but "regex" is close enough most of the time.


I'd argue that wrapping crappy syntax is decent syntax is 90% of what tools do.


I often write wrapper scripts to make complex syntax simple. Just for me.

Don't get me wrong. i actually _know_ the f* syntax because I'm and old crazy fart like that by now. But when it comes to use it, it takes a while to type. Sometimes I make typos. Sometimes i forget one specific option or character and I gotta look in man again.

The simplified syntax wrappers make it f' easy.

The other day I made a csv column grepper. It just calls awk and assign numbers to column names, so i can just grep by column names no matter their order.

So yeah, a huge line of awk can do it. An even less understandable line of grep can actually do that too. Some other tools as well. Mine is just ./supertool colname colname colname ... | awk "$2 != blah" |column -t

(For the record, there were similar wrappers in python and perl, each of which were 5 to 35x slower (200 to 1000 lines script) than my 20 lines bash script, which is another complain I have. Reimplementing that stuff in high level languages is generally a bad idea, specially when you don't understand what happens underneath.


sed -i the way you use it is not portable. BSD (and therefore Mac OS X) requires a mandatory argument to -i (the suffix to use for the backup files). In Linux sed the suffix is optional.



Ironic that the post just before that on her blog is about dealing with the assholes you will likely encounter in Open Source.


I would rewrite these functions for fun, even with an understanding of them. It doesn't matter if the end result is useful or not, we're programmers, we enjoy programming, not using. Of course that's to a point; time spent making something useful that's fun to make is more rewarding to most.

I'm just making the point that it's not just about learning, it's about writing the code. If you're the type of programmer that is only looking for a means to an end, this isn't for you, but if you're like me, the fun is in figuring it out yourself without the help of libraries.


Why are people so opposed to reinventing the wheel?

In a professional context, I understand[1], but this is a personal project someone wrote to scratch their own itch. Why is it unjustifiable? I can think of plenty of reasons to reimplement something but I think the burden is really on you to say why it shouldn't be done. If you think replace is a waste of time just don't use it - simple as that.

[1] I've spent the last two years maintaining an application written in a homegrown web framework - don't get me started.


I've been working in software companies for a few years and I could say that something like this "replace" application is pretty much useful:

- Node.js can be installed on Windows and sed/find are not available on this platform.

- Many of my coworkers don't understand sed/find syntax, and even if they could learn it, they don't have plenty of time.

Btw, it's terrible that a few guys make rude comments about a free and open source software. If you don't like, don't use it or if you think you can make it better, fork it or shut up.


Why are people even arguing about this? Is there some religion that forces people to only believe in and use GNU tools that they can't appreciate a competing tool?

A tool's a tool. If it's useful to you, use it. If you don't need it, then don't. Why does this have to turn into a debate about why someone shouldn't have invented another tool because one already exists?

Look around the world, there's competition and choice in literally everything. Why can't they be choice in what CLI tools to use?


I think it can be valid to do stuff with a scripting language you know, rather than shell commands (isn't that the good old Perl philosophy?). I've actually even looked up sed once and did stuff with it, but it doesn't come up often enough to remember the gory details. And learning sed just to replace stuff takes too much time.

That said, the javascript solution does look a bit long winded.

Also, please don't take it as a negative comment on your comment, I actually appreciate the solutions and it makes me consider sed again.


You just made a point why this 'replace' may actually be useful to do things instead of bothering with using something as needlessly complicated as you have illustrated sed.

It would be far quicker for me to write an one-use program in a number of languages than to find out how to do this in the sed oneliner style that you show - ergo, the sed approach has drawbacks in some use cases, and alternatives should be tried.


Replace looks better to me. I can figure out the command line options from just looking at them, and it does what I expect. I like it.


Very nicely done. It was cool that you outlined this in a lesson format and pointed to how things could have been done differently and attempted to show the perspective of the commenter. Talk about constructive input.


The good news is that in every single example, her command-line equivalent is fewer keystrokes (sometimes many fewer).

Depending on how much you need to this sort of workflow, this could be extremely valuable.


Hers is concise and elegant. sed and find are just defaults.


I guess I'll point out that if you want to play "golf", the replace command was shorter in every single one of your examples.


ack-grep does quite a lot of this as well.


>I took every single example from your README, and show you below how everything can be reimplemented with sed -r (nice extended regex syntax, mostly like js regexs), and find/xargs:

And why assume a POSIX command line?


Funny how @coreyhaines has made hugboard.com ("giving the gift of encouragement"), @steveklabnik is a maintainer of hacketyhack, a tool for learning how to program.

"Hackety Hack will teach you the absolute basics of programming from the ground up. No previous programming experience is needed!"

And while you're busy learning the basics, we'll just wait until you release something so we can publicly ridicule you on Twitter because you did something we don't approve of. Hurrah!


hah, that's just pure irony


I get a fair amount of ridicule any time anything I write makes it into sites like reddit, and a small amount (depending on topic) when it makes it onto HN. When one of my posts hit the front page yesterday, I decided to re-read "How to Disagree": http://www.paulgraham.com/disagree.html

Having done that, I can now just privately laugh at anyone who fails to come up with an adequate refutation of my central point. People who just say things like "this is crap" can be prodded like "okay, maybe it is, but you didn't say how", and then when they fail to come up with how, you know where they are functioning.

It looks like she did exactly this (asked them to explain it) on Twitter, and got the same sort of "it just sucks" reply. Eventually, you can get to a point where they can be safely ignored or even used for your own personal entertainment.

One sent to me on HN: "What an asshole. Chromium's code is there for review, you know."

I said in reply: "Thanks! Comments like this mean I'm on the right track."

Yeah, it's stupid that you have to suffer before you can get to this point, but it's not like we're talking about an industry which defaults to caring for others.

...

Regarding the actual program, I don't write shell utilities in JavaScript so I can't say whether it's a good or a bad implementation. It's just not my space. It's not something I seem to need (since I tend to abuse perl to do such work), so I can't comment on the overall utility, either.


  > Regarding the actual program, I don't write shell
  > utilities in JavaScript so I can't say whether it's a
  > good or a bad implementation. It's just not my space.
According to some other posts here, the quoted mockers are Ruby programmers. I believe the Twitter posts are about the concept of writing sed in Node-Javascript, not necessarily the implementation. As I understand it there's something of a rivalry between the Ruby and Node communities, and the Ruby community is known to be tolerant of boorish behavior.


So there is some truth to the stereotype of the angry asshole Rubyist?

I thought the community had moved on since those days. I've been tossing up whether to learn Ruby or Clojure next, and this kind of crap is a real turn-off for Ruby.


Do Clojure. Ruby suffers from a number of serious basic errors in its design. I'm in the middle of the long task of writing a clear, substantive criticism of them, but why they were bad choices is quite subtle, though it has large implications. That and Ruby has a culture of little or no documentation, even of the standard library, no attempt at consistency in APIs, even for something as basic as different kinds of network socket, and a community with rather more noise and rather less experience than makes me comfortable.


As much as the "truth" of the stereotype of the jock PHP developer or smelly, fat, bearded C developer. That is to say, those people surely exist within each world but it's a shame when others lack the peripheral vision to see the true, bigger picture without falling into stereotyping.


I'm not a regular user of either, but I've much more enjoyed my time playing with Clojure and lurking in the community. For the most part they seem like solid people.


That's what you're taking from this? Really?

As someone remarked elsewhere in these comments:

    > There is no "open source hivemind" so please don't 
    > disparage the millions of open source coders who 
    > will never make the frontpage of HN by lumping the 
    > entire conglomerate into one community.


Having tried Ruby for a year, I have experimented this myself. With a strong OOP background, I can assert that it's not even an elite that enjoys ridiculing noobs.

It reminded me of this: https://www.youtube.com/watch?v=YX3iRjKj7C0

Also, just look at the top comment in that video. The irony.


Oh is that what it is? The tweets weren't specific enough. Basically a point and laugh response but I didn't get it. I looked at the code briefly and it certainly seemed odd that node/javascript was being used as a command line tool to do something that can already be done with other tools, but this person created this to make their life easier.

Created. Had a problem and wrote working code to solve their problem. Then shared it. Not really something to point at in mockery.


Hum. It reminds me of performance art, to be honest.


It does, any art really. If the software were the brushes, no piece of software is right for every artist.

Should we trash people for making 'yet another social network' or 'yet another online map database'? This is even a smaller scale project and barely worth the effort to complain about.

Programming can be a much more creative exercise, and sometimes people forget that. I don't always do things to be useful, I do them to be fun and educational.


It's disappointing that someone like you who is trying to share information and learn together would be attacked like that. People are awful.

I have a new policy of not responding to any comment that includes any form of ad hominem argumentation or any continued argument that is full of logical fallacies. It's just not worth the time to be arguing with people on Reddit or HN.


I have to agree. You need to look at the quality of the people who like you vs hate you.

There's plenty of haters on the Internet. As jrockway said (just a couple comments up): "If you do something, chances are someone hates you. Why? They are jealous that you are getting attention instead of them."

I heard a metaphor once: You've got a bucket full of crabs. If one crab tries to crawl up and out of the bucket, the other crabs drag him back down.

Try your best to ignore the haters.


I looked at the actual code and, although I'm no expert with Node, it looks pretty reasonable. The only things I can find to criticize was the word "replacize", which makes me cringe much like "performancing" or "optimizely", and the use of == instead of ===. But I think reasonable people could disagree about those things. Someone who isn't me might think "replacize" is sufficiently humorous to retain, for example.

The nesting goes a little deeper than I would like: https://github.com/harthur/replace/blob/master/replace.js#L9... is 7 indents deep, for example, where I think something like 4 indents is a place where I should stop and start questioning what I'm doing. But three of those indents are a tradeoff forced by the node.js async API: anything that has to wait on the result of an asynchronous operation must necessarily be in another function, and you can choose whether to nest that function deeper or to move it somewhere unrelated and give it a name; and you have to use error codes instead of exceptions for error handling from those operations.

The program actually includes a synchronous version of the same code, where the line corresponding to line 90 above is https://github.com/harthur/replace/blob/master/replace.js#L1..., the blank line following "var text = fs.readFileSync(file, "utf-8");". If that fails, it throws an exception, so the "if" block isn't needed, and the code that follows doesn't need to be nested.

This is the agony and the ecstasy of Node: everything is (normally) asynchronous, giving you unwanted levels of nesting, but on the other hand, everything is asynchronous, so you can process the files in the order that the filesystem finds it most convenient to return them to you in. I wouldn't be surprised if it turned out that Heather's code was typically much, much faster than find | xargs -P sed, simply because it was able to productively manage many more outstanding I/O requests at once.

Line 90 also points to a pitfall that often befalls us with parallelism: at some point parallelism stops being productive, so you have to limit it. In this case, Heather's code throws the ball back to the user and suggests that they rerun their command in synchronous mode — albeit having partially completed the replacement task, which might be a bad failure mode, depending on whether your replacement is idempotent.


I was pretty appalled when I first saw those tweets. I held my tongue at the time (after all, who am I?) but as a member of the Rails community, seeing this sort of behaviour from community leaders is frustrating and kind of embarrassing, and I do think it needs calling out when it happens. I'm finding Twitter has become more and more depressing lately with similar incidents.

I don't know much of Dave or any others who stuck the boot in, but Steve and Corey are both involved in educational endeavours and should know better. Steve also recently railed against the idea that "you are not your code" (https://twitter.com/steveklabnik/status/279399353729286145) which makes his jab even more insulting.

I've often wondered why concepts such as MINSWAN even exist, but it seems some people actually have to be reminded to be nice.

If they haven't already, they definitely owe you an apology.


Maybe before we spend a lot of time complaining about how federal prosecutors are unsympathetic assholes, we should start by examining our own community.


Death, prison, and felony convictions are not the same as public ridicule and hurt feelings. Only a nazi would equate such things. What?


HN's collective reading comprehension seems to have dipped lately. Fortunately, pg is usually concise enough that we can use this as an exercise:

"Maybe before..."

"before" merely implies order. It does not mean "instead of". It means, "this first, then that."

"...federal prosecutors are unsympathetic assholes..."

The subject here is not jail sentences or felony convictions or legal antics. The subject here is sympathy. For example, a statement made on HN which would fit pg's subject is, "federal prosecutors had no sympathy for...".

"...we should start by examining our own community."

The implication here is that our own community is also often unsympathetic and full of assholish behavior.

pg was not comparing public ridicule and hurt feelings to death, prison, or felony convictions. He was only suggesting that one of the complaints here over Aaron's case has been that the prosecutors were "unsympathetic", even though our own community is also unsympathetic.

I have no idea how you could have misinterpreted a single statement of 24 words that badly.


I was mainly making a joke, but the content of the statement was a problem. Let's consider the relative merits and priorities of "spending time complaining about federal prosecutors" vs. "examining our own community". The former is about trying to change our society to make it more just, the latter is aimless introspection.

The comment was a bit of a troll and not insightful so I trolled back. If this were not pg's website, I am certain you wouldn't be defending the statement because it lacks substance.


> The former is about trying to change our society to make it more just, the latter is aimless introspection.

On the contrary, the former is something we probably won't change [1], while the latter is almost certainly something we can change.

> The comment was a bit of a troll and not insightful so I trolled back. If this were not pg's website, I am certain you wouldn't be defending the statement because it lacks substance.

I seriously doubt he was trolling, and you shouldn't be so certain. This being pg's site is completely irrelevant in this case [2]; I'm simply ... actually, disgusted is about the best adjective I can think of to describe how I feel about the nonsense arguments on HN lately. People seem to be in some kind of a hurry to disagree, because they aren't actually reading and comprehending what other people are writing, they aren't stopping for a moment to consider that perhaps the person they're responding to isn't an idiot or a troll, they aren't maintaining basic principles of civility, they're commenting on (and arguing about!) subjects that are way outside their expertise, and they seem to be nearly drooling at the chance to engage in a witch hunt.

For example, nothing in my reply was a defense of pg's statement. Nothing. Not a single word. The entirety of my reply was a tutorial on high school level reading comprehension and a snide remark about HN (well, and a question about you). So, how is it that you interpreted that as a defense of his statement?

--

[1]: I may yet be pleasantly surprised. I certainly wouldn't've guessed at how much press the Aaron Swartz case would end up getting, and there is some small chance now that it might end up causing some kind of change somewhere. That would be great. As of yet though, it has changed absolutely nothing.

[2]: Assuming of course that you don't find it significant that the founder of one of the programming communities on the internet is indicting the community's behavior -- although it's not clear if he's referring to the HN community or the broader programming or technical community.


> The entirety of my reply was a tutorial on high school level reading comprehension and a snide remark about HN (well, and a question about you)

Maybe before you spend a lot of time complaining about how other people comment, you should start by focusing on making a positive contribution yourself.


jcampbell1 and pg are bringing up a conversation from a another thread: http://news.ycombinator.com/item?id=5110270.


Hmm. pg and jcampbell1's comments predate that thread by several hours, and I don't see the connection anyway. Did you link the wrong thread, or am I missing something?


I'm also not seeing the connection here. A few mean tweets over code quality vs threatening someone with life sentences over downloading documents is a very poor analogy on how we should be spending our time.


Both of you seem to think he said "instead." Consider the clauses rephrased: "Maybe we should start by examining our own community, before ..."

Why? I'd guess because the blog post refers to celebrity hackers bullying another hacker. The community -- more than just these few guys -- can't even behave civilly. It's a case of the pot calling the kettle black.


Compare the cause-and-effect of both the situations. One can send someone to jail for life and destroy their finances, reputation etc... the other can hurt someones feelings.

Contending the latter should be addressed before (or even comparatively) to the former is what I take issue with.


Do you really think Paul Graham doesn't know the difference between someone being insulted on Twitter and someone being threatened with federal prison time? You don't think maybe it's you that are missing something, and not him? Because if my response to something he wrote depending on him not noticing the difference between prison and twitter, I would worry that I was missing something. No, wait, I wouldn't; I like giving him shit.


He can still make a fallacious and ignorant comment while being aware of the difference.


The actual objection here, the reason why pg's comment is "fallacious and ignorant", is a bit fuzzy. People have pointed out a difference between HN users and federal prosecutors, but not why that difference is important. I can only think of one possible line of reasoning, but it's unbelievably hollow. Are you sincerely arguing "It's OK for me to be an unsympathetic asshole because I don't send people to jail"?


>The actual objection here, the reason why pg's comment is "fallacious and ignorant", is a bit fuzzy

Because he is suggesting that "someone said someone else's code was bad" is a more pressing and concerning issue than "the federal government threatened to destroy the life of a young man and drove him to suicide over a trivial non-offense".

>Are you sincerely arguing "It's OK for me to be an unsympathetic asshole because I don't send people to jail"?

I can't imagine how one could make an honest, good faith attempt at communications and come to that conclusion. It seems more like you are deliberately looking for a strawman. I am arguing that pg can in fact make a fallacious and ignorant statement, even if he is aware of the difference between two cases he is comparing.


> Because he is suggesting that "someone said someone else's code was bad" is a more pressing and concerning issue than "the federal government threatened to destroy the life of a young man and drove him to suicide over a trivial non-offense".

As someone once said to me: I can't imagine how someone could make an honest, good-faith attempt at communications and come to that conclusion.

What pg said, albeit more politely, is that calling out federal prosecutors for lacking sympathy when you don't exhibit any yourself is rank hypocrisy.


No, that is not what he said. He very clearly, and completely explicitly stated that we should concern ourselves with this trivial non-issue before we concern ourselves with the serious issue. The only reason we could need to address one issue before we dare to consider another, is due to the overwhelming importance of the issue.

Stop trying to pretend he said something other than what he really said. His words speak for themselves, you don't get to invent an absurd justification to pretend they mean something else. You can read the post yourself, it is still there.

He has no way to know if the people calling out the federal prosecutors have sympathy or not. There is no hypocrisy in Bob saying the prosecutors did something wrong while Joe (who Bob has never met or heard of) is saying Sally wrote some bad code.


The probability that he, or any other decent, civilized person, would make that comment is very, very low. Let's admit that parent, GP etc. are trying to pick on pg and move on.


He did make it. It is still there, you can read it. I am not sure what you are trying to convey.


If empathy were a limited resource that demanded to be spent only in descending order of the seriousness of the potential injury, then you might have a point.


Time is a limited resource. But fair point, as one could spend less time being unsympathetic towards others and instead spend it more valuably being empathetic towards legitimate causes.


It is a limited resource, but you are right about that there is no clear order.


| One can send someone to jail for life and destroy their finances, reputation etc... the other can hurt someones feelings.

And destroy their reputation. And, in some cases, push them to the edge.


Why is this a before/after situation? The people addressing one issue are a completely different group of people than the ones addressing the other. And what is keeping people from addressing both at the same time? And which one is closer to us that we can have a more direct effect on?

This idea that we shouldn't try to address problems in the HN community because there are problems elsewhere in the world is ridiculous.


Of course, it's the Godwin's law.


Better yet - let's do both.



I wonder if the cause is the same in both cases.

It's a lot easier to be an asshole to people in certain structured formats -- prosecution, online chat (IRC being the ideal, but even email, twitter, and blogs lead to aggression). It's harder in person, or in other formats (essays?).


I don't really see the problem. I never remember sed syntax and instead just use perl -e. It follows that someone may want to use JavaScript instead though I would personally avoid JavaScript at nearly any cost.

As for haters on the Internet, yeah, welcome to the Internet. If you do something, chances are someone hates you. Why? They are jealous that you are getting attention instead of them. They could write a better version of grep, but are too unmotiviated, lazy, or dumb. So instead they trash your version. Attention flows back to them, they look smart in front of their friends, and ???, profit! You don't have to play a part in their fantasy, though. Just ignore them and let them bask in the idiocy of their idiot friends.

Or, if they have actionable feedback ("line 34 is indented wrong"), fix it and send them a thank you. Investing any more thought than one of those options, though, is a waste of time and mental energy.


>Welcome to the Internet. If you do something, chances are someone hates you.

You know, this is really what we have to keep in mind, or at least try to any way. Doesn't stop it from stinging a bit when it happens though. Especially when they are the first kind of comment you receive when you show a project in a public forum.

I usually expect a couple of 'Fuck you. My eye's are bleeding from your coding." style comments anytime I show a project publicly, but there are still times that it catches me off guard.

For instance, not even code related, I once asked on Reddit for a couple of people to help beta test a Skype plugin I was working on. At that time, I had never written a threaded piece of software before, and had no idea how it would perform when a bunch of users were accessing it simultaneously. I wanted a larger test pool than the two or three of my friends who were online at any given time allowed.

So I made my post, and received almost entirely negative feedback from it. To the point that I was completely unprepared for. I got stuff about what a loser I was, and even PMs about how I should just kill myself now for being such a loser, etc, etc.. It seemed like once the first negative comment popped up, the bandwagon effect took over, and suddenly it was an inbox full of hate.

So I sat there in my chair, wondering what the hell just happened, what I did to all of these people people to cause such hostility, and on top of that, I sat there wondering why I even cared what a couple of assholes on the internet said. I didn't want to care, or be that guy who was bothered by "the mean people on the internet," but dammit I was a bothered by the whole thing.


Not related at to code at all but your comment about catching you off-guard reminded me of a comment chain I was a part of on reddit. There was a comment about assigned seating in movies and I replied with how I liked the system and why, and then the reply to me was something along the lines of, "Remind me to never hang out with you.". Water off a duck's back to me but it did give me a moment's pause and I recognised that if I weren't used to such behaviour it would have affected me.

It reinforced a feeling I have that, sadly, you can't seem exist in communities on the internet without being ready to put up with unanticipated 'hate' (for lack of a better word).

I know many people who given time to become more experienced, would benefit greatly from various aspects of the net, but I worry they wouldn't last a week before they decided it was something they never want a part of.


If I've learned one thing is that the Reddit community is not friendly. I swear to God, there must be a underground competition to who can bully and troll more users there.


On the main subs, I think it is that there has been a down tick in the average user age. Being on the site and not being logged into my account feels quite a bit like visiting my 14 year old little brother facebook page. Just kind of base-line, 14 year old funny.

My point being, I think a percentage of the trolling may come from that demographic. It's not rare to run across account that literally was set up just to hurl insults and racism. I just imagine that there are a group of 14 year olds sitting on the other side which boast to each other about how much negative Karma their 'troll' accounts have.

In other areas, I think it's that some people just take karma far too seriously. I used to spend a lot of time in the language specific learnprogramming subreddits. It seemed like a nice way to help the 'community,' without having to do the race to the answer game that you do on stackoverflow.

I learned that some of the most unbelievably childish people hang out in the language specific threads so they can play 'expert.' I ran into a couple of users that would downvote every answer in the thread that wasn't theirs. I sent one a message about reddiquette and that fact that he's really being a bit of a dick in our small community, but his response was to downvote all of my posts, and say that all other answers were wrong but his (they weren't).

Needless to say, it seemed a waste of effort to continue to post if everything was just going to be buried thanks to some guy's e-ego.


the worst bit is that a lot of the ridicule seems motivated by the fact that it's fashionable to hate on node.js. this tweet as much as admitted it: https://twitter.com/steveklabnik/status/293831920872194050


Isn't it (scientifically documented) that if (a software project) A is threatened by B then supporters of A start to bash on developers and users of B? Because that's what I see here. node.js is very much a competitor to rails, and Steve Klabnik is very close to rails.


Agreed. I wrote this blog post:

http://paulbjensen.co.uk/posts/2012/07/11/thoughts-on-rails-...

Then Tony Arcieri wrote this rebuttal:

http://www.unlimitednovelty.com/2012/08/debunking-nodejs-gis...

He made some good points in his post, but the snarkiness was in my opinion a bit uncalled for. Being labelled a Rails Enthusiast when I had worked with Rails for over 4 years (2007-2011), 2 of those at New Bamboo (a big Rails agency in the UK) was cheap.

I then tried to deduce why he was so rude, so I looked through some of his older blog posts, and found this:

http://www.unlimitednovelty.com/2012/03/why-critics-of-rails...

but then this tweet summed it all up:

http://twitter.com/bascule/status/274281490437767168

The issue I see here is that there are some in the Ruby community who hate Node, but who then extend that hatred of Node to being rude to people involved with Node.js. Tony has been rude in the past to both Substack and Isaac Schlueter (major figures in the Node community) over Twitter. I can only reason that the rudeness towards Substack was because he made this comment on his blog post: http://www.unlimitednovelty.com/2012/08/debunking-nodejs-gis....

As for his replies with Isaac, see this: http://twitter.com/bascule/status/281932459719921664

I'd like to say it stops there, but it doesn't. I actually had someone email me because Tony had been rude to them on Twitter because he compared npm to Rubygems. Can you believe that?

Tony is a smart guy, he's written some really awesome software, but when it comes to Node, he is a troll.

As for Steve, he hates Node, but I don't think that he intends to be rude to Node.js people. When I posted this on Twitter:

http://twitter.com/paulbjensen/status/271691672348409856

followed by this:

http://twitter.com/paulbjensen/status/271733415580164096

and this:

http://twitter.com/paulbjensen/status/271734483538018304

Steve Klabnik followed up later on with this:

http://twitter.com/steveklabnik/status/271749289154330625

Compare that to this:

http://news.ycombinator.com/item?id=5018201

Both Steve Klabnik and Tom Dale retweeted that HN comment. So where Steve might hate on Node, he doesn't hate on people who like Node.js, or have expressed a preference for it (otherwise he would probably have not linked to my post).

I know I'm not the best person to say this, but I wish that this could be the end of animosity between the Ruby/Rails and Node.js communities.


It's shocking the historical parallels between Node vs Rails and Rails vs Java. You'd think given the history of Rails that its practitioners (me being one for 7 years) would be more careful about dismissing a new technology for not being as "mature" and that you can "do all the same stuff" in Ruby.

I mean lets be honest: there is no outright revolution in Node anymore than Rails was a revolution, rather it's a matter of bringing useful ideas to the table in a convenient package. Node has particular strengths that Ruby does poorly, and we need to be intellectually honest about that rather than contorting ourselves to find ways to justify why ruby is always >=.

A lot of this animosity seems to come from a passion for the craft and subconscious fear of perhaps not using the best tool, and thus a need to justify to oneself why another tool is inferior. However if you look dispassionately, most of these conclusions are reached from highly asymmetrical knowledge and experience, and often rest on matters of taste. The hatred of Javascript for instance, is largely a matter of taste since its prototypal inheritance gives it a similar dynamic power to Ruby, just slightly uglier.

All that said, your original post also seems to come ever so slightly from a defensive position. Some arguments don't seem well argued, like why you thinks Rails is not good for APIs and heavy JS front-end (Rails has never been great with its Javascript, but it also mostly does the right thing to stay out of your way).

In any case though, I think we all have a tendency to overthink this stuff (me included). If the goal is to do good work, I think 1% of your time should be spent looking at new ideas and latching onto interesting new things, and 99% should be spent actually executing the craft.


I hope Node can keep it's frontier attitude up. Rails and Rake have been very homogenizing boring exercises in top-down fascism. So much of Node's spirit is in tiny modules, in the freedom and ability to hack up and try new things, to always be inventing: it's cost to create are low, the assumed body of knowledge one has to bring into a new project are tiny, the conventions are borderline non existent, and that's all a huge boon for staving off fascist boring mundane dead-end consensus. Keep iterating, stave off the little death, don't become your entrenched patterns.


The frontier is always settled.


The worst bit about it is that it's part of a petty language squabble?


no, that a petty language squabble was worth abusing someone over - it had very little to do with her actual code


the hatred of node.js always reminds me of anti-apple people.


I have to say that node.js can be an entirely useful tool, and I can even support Heather's activity of making things she wants to use with it, without drinking kool-aid that node is better than everything and solves everything and should replace everything. And the same of Apple. It seems inaccurately simplistic to describe this as 'hate'.


I mostly agree with you but it seems to me elitist behaviour like this has a lot of tacit acceptance among developers. I have seen it many times in my career, and have also noticed that workplaces where is is not acceptable tend to make everyone more productive.


It's a people problem, not a developer problem. Watch the gossip magazines trash actors' clothes and haircuts.


Good point, but some communities seem more civil than others. I went from theoretical computer science to development and there was a noticeable drop in civility. Of course the theoretical computer science community is tiny when compared to software development.

I'm loving the great supportive comments in this thread however.


The difficulty of a subject acts as a filter. For mastering a hard subject you need to be able to control your impulses, which might also cause a more civil behaviour.

I don't think that it's accidentally, that the Haskell community is the most civil community I have been part of. Just being part of it makes myself a nicer and more civil person.


> Watch the gossip magazines trash actors' clothes and haircut

And also reading some of the more interesting messages on the Linux Kernel mailing lists, specifically messages by Linus. It's sometimes entertaining to read them and the responses in defense of Linus because he's awesome. I wonder what the reactions from HN would be if it was Linus, or some really high profile programmer, making these comments?


Sorry, being in a vituperative argument based on some actual issue may be rude, but it isn't the same as spontaneously bullying people on Twitter with zero-content flames about their personal github repos.

Someone gets in a fistfight over a woman, this is not mature, but it's different from cold-cocking strangers on the street because you think it's fun.


"Most of being nice, in a software context, is about being considerate. Not unnecessarily trash talking other people's stuff. Not going out of your way to be a jerk. Try to be helpful. Treat others how you want to be treated" - http://blog.steveklabnik.com/posts/2011-08-19-matz-is-nice-s...

What can I say?


The irony, it burns. I have a feeling there is an apology incoming. Everyone screws up and most people will poke some fun at some point. Seems like one of those off instances for him.


There exist two types of people:

1. "Hur hur, sed piped with other tools already does this, you loser, why did you waste your time?"

2. "Cool, a different take on sed written in Javascript. They've written some basic doco and made a npm package, I might try it."

Ignore #1 online and in-person, be friends with #2.

People who adhere to type 1 behaviour are alien to me. I fundamentally don't understand what their motivation is to respond with such harsh criticism. You've liberated some close source, personal tool, into the public domain. There's some group of people, perhaps in the long-tail, that will use this tool, or learn from the source code. Clearly people have expressed interest in the tool (74 stars and 5 forks).

Again, ignore #1, friend #2.


I think you've excluded the middle here, (#1.5 perhaps) one who thinks that your code is worthless/dangerous and does not call you a loser.

It can be true that a piece of software is a poor replacement for an existing tool.

It can be true that recommending it as a replacement for that tool is dangerous.

You can make these judgements about a piece of software without an incident like this happening. What's important here, is how you behave once you've made these judgements.


> It can be true that recommending it as a replacement for that tool is dangerous.

Unless you're suggesting that NASA rewrite its rocket guidance subroutines in a brand-new interpreted language or something, it's probably not unequivocally "dangerous." (In that case, I would call the suggester a different word than "loser".) That's the whole point of open-source software: everyone can make their own judgments about what works better for them.

In the specific case of `replace`, if I want to know exactly what the command-line options do, exactly what order the files are being modified in, I can glance over 173 lines of javascript rather than search through the 4.3MB (uncompressed) of the sed source code. Sure, I suppose I'd have to include the Node.js source code to make it a fair comparison, but my point remains: choose the solution that makes the most sense to you.


I'm in the #1.5 category probably.

_But_ it is all about how it is written. Criticism is good when it is constructive, otherwise it is not far from just name calling, badgering and spewing of hate.

Other ways to respond could be "That's a cool idea. I like to use sed" or "checkout my python one-liner".

All those things you highlighted could be true, but that's still not a reason to offend someone.

It depends on who the author is:

* If an 8 year old wrote that, that would awesome and she would become an overnight internet celebrity.

* A Linus Torvalds wrote that -- everyone would become very worried that he is smoking something.

* Someone who is just learning to program -- it is awesome and they should be encouraged to do more of it

* A seasoned programmer -- they should still be encouraged but criticism should be more pronounced "Cool but sed usually works better, were you thinking of some specific feature?".


Yeah I mean it's OK to make judgements and think or believe whatever you want. Maybe even tell how a friend or two how silly something seems to you while hanging out. It's a different thing to being a dick to someone publicly on the internet for trying to contribute positively to open-source.


I agree with this mentality. Its best to just ignore the #1-types out there. Of course, that doesn't remove the sting. I don't use node, so this doesn't fit in my toolchain.

However, I wanted to commend the author on the nice simple interface. In particular, I like the highlighted output showing the changed lines in all files. This is one thing that sed -i doesn't do (although I guess you could cobble it together with sed's backup feature and diff).

Anyway, don't get discouraged by the haters!


>Again, ignore #1, friend #2.

"Forget the insults you receive and remember the compliments. And if you figure out how to do that, let me know"


I guess the point of the #1 is they may be trying to hit you with a clue. sometmes not in a most efficient way, hurted feeling stay in the way of learning.


Perhaps, but comments like "I cannot even make this stuff up" and "eyes bleeding!" are not constructive criticism, just pointless mockery.


First up a clickable link to the project: https://github.com/harthur/replace

---

When I see a project that reinvents the wheel I tend to think that the author needed a very particular wheel and decided to start with first principles. And even if it seems useless to me - open sourcing it lets me see how this wheel was created, and maybe learn something from it.

And of course sometimes someone reinvents `grep` as brilliantly as `ack` and I end up using it every day.


This is pretty cringeworthy. I know probably everyone has made an offhanded jab about someone else's software (I know I have) - but in these days of twitter and real-time notifications, we have to remember that the real person behind something is often just a tweet away.

I'll try to keep this in mind next time I take to twitter to unleash 140 characters on rage on something that someone has made and cares about.


I've been following 2 of the 3 guys in that twitter conversation for several years. The first thing I can say is that they both are big parts of the ruby community and generally represent it well.

With that said, this exchange really upsets me. I've noticed that there is definitely a sense of elitism among the guys that speak at many of the ruby conferences. I think a situation like this is simply a case of them forgetting that Twitter is public and that their personal message board isn't so personal after all.

Guys, this is bullying and it's fucking pathetic. It's not the first time, but it needs to be the last. I've at least seen Cory talk and the guy is definitely one of the good guys, but this puts him in really bad light. How much more effort would it have been to post a defect to the github account and informing of the issues?


And when you say that they are part of the Ruby community, it's sad, but I said to myself - why doesn't that surprise me. It's said that the community behind a really useful language has that type of reputation.

To tell you the truth, it's part of why I moved to python.


I take it you haven't seen @zeeg's tweets on the subject, then: https://twitter.com/zeeg

Sorry to disillusion you about the Python community.

Personally, part of the reason I stopped using Python heavily professionally in 2007 is because I was sick of hearing and reading Python web developers regularly disparage Ruby and the "Ruby community," a tradition carried on in comments like yours to this day.


Are you suggesting I was talking bad about the Ruby community?

I openly dislike Ruby (as a language), but I swear this project was written in Node, which I also dislike.

Oh, and I could care less which language something is written in, my simple, trollish tweet, was only based on the usability aspect.


Yeah, about trollish tweets... you might offend someone.


It's sad that the community behind a really useful language has that type of reputation.

Though not as sad as when intelligent people fall hook, line and sinker for unfair reputations formed and paraded by third parties displaying as much commonsense as those who used to stereotype others by race or gender in times past.


Many people here seem to be commenting on the quality of the code in question - they are clearly missing the point.

Others are offering advice on how to deal with negative criticism on the Internet. They, too, miss the point. The point of this post isn't to complain "people trashed my work and now I feel bad, make me feel better", it's a call to action - "as a community, we should be better than this". Of course there will always be trolls and negative comments on the Internet. Instead of just preparing ourselves to deal with them, we need to be proactive about creating a community where everyone feels welcome to share what they're working on, even novices who don't write perfect code. (my previous thoughts on the matter: http://news.ycombinator.com/item?id=4700490 )


  > Of course there will always be trolls and negative
  > comments on the Internet. Instead of just preparing
  > ourselves to deal with them, we need to be proactive
  > about creating a community where everyone feels welcome
  > to share what they're working on
"Instead of"?

Attempts to reduce the number of undesirable comments or people in a community are commendable, but do not let yourself become confused about how well they work. Washing hands is no substitute for vaccination; if you want to grow a better community, then its members need to be trained both in how to avoid giving offense and how to avoid taking it.


> Many people here seem to be commenting on the quality of the code in question - they are clearly missing the point.

i only see one comment responding to the code


This is pretty awful. Steve and Corey are both well-known in the Ruby community.

Steve is an instructor at gSchool in Denver, for example, which trains software engineers. It's bad enough that they're both respected in the community, but being a student is a vulnerable position. If Steve were my teacher and he reacted that way to a project I released, I'd be absolutely humiliated.

http://www.gschool.it/#instructors

I don't think encouraging participation in open source and being a good teacher are that different. A more productive response would've been to submit some issues or pull requests to Heather's project.


Steve Klabnik runs Hackety Hack (http://hackety.com/) which is supposed to encourage and teach new programmers, but this is the shit he says to other developers in the wild?

Nice.


For years I have been terrified about putting my code on Github for fear of rage and retribution from the programmer community. This is a real problem for us amateur coders who enjoy hacking but don't necessarily have the chops to go head-to-head with the serious guys.


Likewise. I finally gathered the courage to start open sourcing code recently, I figure that if the code I'm writing is shit then it's going to be shit whether it's on my hard drive or on github and the advantages of having code out there are worth the potential ridicule... but still I find myself prefacing everything with a disclaimer, "I was tired when I wrote this" or "This isn't the best code" just to give myself a get out if someone does decide to tear apart the quality of my code.


A completely agree here. Even though I get complimented at work about code quality, I just feel like the open source community is somehow "more serious". Like, what if I'm doing this whole coding thing completely wrong?


You shouldn't write those type of things. I mean, you can comment about potential problems in the code and whatnot, but don't disclaimer your code like that before anyone even complains about it.

Most of the "your code sucks" comments is based more around you didn't do things like they would have. Such as:

"You didn't use OO principles the way I interpret them so you suck."

"You used that library/framework/language that I hate so you suck."

"You're not coding in my *nix flavor with my choice of IDE so you suck."

"Your project does something I already do with this other project so you suck."

Rarely do I see actual constructive comments on how the person in question can get better. At this point I'd rather communicate with a bunch of nobodies and learn together than follow somebodies that ridicule someone for trying.


Don't let occurrences like these deter you from putting code out there. The truly great developers would applaud your efforts and probably give you a pointer or two. The faster you fail, the faster you improve.

Reminds me of an old school Jeff Atwood quote:

"There are a handful of programmers in the world capable of producing brilliant, perfect code. All the rest of us can do is keep making our software less shitty over time-- a process of continuous improvement."


After participating in these comments tonight, I decided to purposely post some of the worst garbage I could find in my home directory. That way, I get to control the fact that yes, I have bad code. They can't act like it's a surprise.

http://rachelbythebay.com/w/2013/01/23/crap/


I've seen way worse than that. I've probably written way worse than that. I wish I knew where to find it.


As soon as I put some of my code up on Github I started to worry that someone might actually find it. It can be a bit intimidating. I can only imagine what'll happen once I learn to contribute to something.


Dude, these people who tear code bases apart for lulz are not worth your time. If they can't cogently point out the flaws in a reasonable fashion, then they can go fart around on /b/ as far as you should care.

Sure, some employers might care... "new guy might get flamed online". Yeah... okay... do you want that shallow of an employer? :-)

If you want, put your code online and email me, I'll be happy to look at it and point out any obvious mistakes.

(I don't know why harthur reimplemented parts of sed. I don't really care. sed is hard to use, I wouldn't mind rewriting it myself).


In a way, it gets worse as you get better. Once people start thinking you're awesome, you start worrying that, if you make your code public, they'll realize how much you suck.


This is so true.


If you don't want it out there, trust me no one will care.

I imagine the other side. What if there is that one person 20 years from now that was looking for a piece of code and finally end up on your idea from 20 years prior.


It's also worth asking yourself, if some stranger on the Internet offered unsolicited criticism, then so what? Why even listen to something hateful and unhelpful?


I kind of expect more from Corey Haines, he's supposed to have a reasonable reputation according to people I know and trust. I'm supposed to be going to one of his 'Code Retreats' in Melbourne this year. I hope I don't get made fun of!

Good code seems to be whatever the majority of nodding heads agree upon, and rarely that is merit based. It seems to me that unfortunately most of the nodding heads are people who act like this.

I've been ridiculed for my code by people like this, even in situations whereby I've been trying to help solve their annoying problem (and in fact, did help solve their problem). What did I get back? Mostly condescension & ridicule, and no credit.

Anyway, if anyone wonders why valuable people run screaming from the software industry, it's people acting like this.


Why would you go to his code retreat? Seriously? I am stumped.

As far as I can tell he is just some guy who has engineered a healthy social media profile / following, and goes around beating his drum. Basically an agile-coach charlatan.

I suspect it is very likely you already know just as much, if not more, about software development.


To quote Mark Twain: "Keep away from people who try to belittle your ambitions. Small people always do that, but the really great make you feel that you, too, can become great."


At some point during my teenage years, my dad gave me the one of the most useful pieces of advice I've ever gotten: "the world is full of assholes, don't let 'em get you down, but don't put up with 'em, either."

Or, in this case, don't work with them, or recommend that anyone you know work with them, because while the world is indeed full of assholes, it's also full of enough awesome people that you should never have to put up with the assholes.


That's similar advice to my favorite of Murphy's laws,

"There is always one more arsehole then you counted on."


I was about to contribute to an OSS project run by one of the people making fun of the OP. Not anymore. I will not work with people who set out to humiliate others on "code quality" (whatever the fuck that means).


Does this make sense? Are there other many people that use that project? Does your contribution to it signify an endorsement of its maintainer? Have you already written the code? Is it fair to the other users of this project that you're withholding a contribution because of an idiotic remark by its maintainer? Would it be preferable to fork the project so that the maintainer can be somebody else? What if you create your own fork with your contribution and publish it? What if the other person who made fun of OP then merges your changes back into the original codebase?

I can't tell if this is an attempt at activism or an excuse to avoid doing something.


Here is why:

Ever since the passing of Mr. Swartz my stance has changed. I've realized that e-bullying is real and can have a negative impact on a person. Who knows in what kind of emotional condition can the person being bullied is? I'm not saying that this could drive someone to do something tragic. But it could push them further down. And I will not work or contribute with people who do that.

The person was bullied. I will not work with bullies. Open source or not.


Frankly, I think by now I've sort of got used to it. Its not just the case with Open source projects, This happens everywhere. I've been facing these sort of problems since I was a kid. Be the first guy to build a model from clay, or the one to write an essay, or the one to participate in the science exhibition. Nearly everyone will first find ways to crap on your work than find something positive about it.

After all these years, I just feel these are just ways a guy who doesn't work find a way to justify his inaction. Just make others work look bad, and then you can just go back relax and do nothing. Make your inaction look better than than the guys action.

People just don't get 90% of all success is just showing up thingy. Now coming to this project, a guy on twitter as shown on the blog says 'Ever wanted to make sed or grep worse?'- Oh! What does this guy think? Sed and grep are the best designed tools out there? Heck learning sed is a nightmare- the language is so terse it may take you months to make any significant headway learning it. There are like dozens of special cases you have to learn and handle.

Then why does sed win? It wins because the tool occupies space where there is no, or little competition. Sed shows up!!!

Everytime you see somebody produce a piece of work which is helpful in solving a problem think about why you couldn't have been the guy who could have done that, instead of finding ways to justify why you aren't have the guy who did that.

At the end, only ones who don't get laughed at are the ones who do nothing.


More important: why are you listening to what anyone on Twitter says? For that matter, why are you listening to what anyone on Hacker News says (assuming you read this)?

Personally, I have no idea what anyone might have said about any of my code on github on Twitter, blogs, or otherwise. No, scratch that, I remember a terrifying moment when I realized the link in a sentence along the lines of "who says Haskell isn't ready for the real world?" pointing to my serial port library in that language. Anyway, that's beside the point.

You should have a short list of people whose opinion matters. Hint: your family, a set of people whose character and abilities you respect, and anyone who has direct power over you (though if the third isn't a subset of the second, you might want to work on that, too). Random people on the Internet don't count, no matter how famous they may be in their sandbox.


It's bullying, plain and simple. There is no excuse for this kind of behavior, nor can I respect anyone who engages in it.

Even now I feel my blood boiling...


Which is funny because the guy pictured, Steve Kablink, has this sentence on his about me page:

> Most of my software development work is in teaching these days. I run classes with Jumpstart Lab, and make Hackety Hack

You'd think a "teacher" wouldn't act like this - but so arrogance goes.

With open source - your complaints are worth zero which is the exact same price you paid for the software.

Help others with pull requests/contributions - or shut the hell up.


Others have linked to this, but, as one of the people who was in the bad, I want to say I'm sorry. http://programmingtour.blogspot.com/2013/01/im-sorry.html


Good that you didn't double down.

Wouldn't want to be on the back end of a hacker news shit storm :)


Here are some of Heather Arthur's other projects on Github:

https://github.com/harthur/brain - neural network https://github.com/harthur/classifier - bayesian classifier https://github.com/harthur/clusterfck - clustering https://github.com/harthur/glossary - term extraction

You can see more here:

https://github.com/harthur?tab=repositories

Nice stuff.


I'm surprised no one mentioned it, but hey, there are people using windows out there where that can use this (instead of installing cygwin, or finding out what on earth is the equivalent of grep on windows command line)

I think it's just immature behavior to criticize like this and I'm happy to see the top voted comments here

Criticize in private, praise in public. Otherwise you are just a bully.


You know, reading the various devs' tweets, they use twitter in a way that is completely foreign to me. Is there anything these guys think that they don't tweet? ("Hey, who's picking me up from the hotel?" is not something I'd ever announce to the world at large.)

This incident shows a danger of working that way--one of these guys apparently had a rude little thought best kept private--and let's admit it, we all have those thoughts at one time or another. But because he tweets everything, that little passing thought was pushed to the world, which is not good for anyone involved.



> FWIW

FWIW, I personally think it's worth a lot. It's easy to be nasty on the internet and a lot harder to be nice.


> a lot harder to be nice

Until all eyes are on you, and you know they're calling for blood. Then it becomes very easy.


Not always. Don't underestimate the strength of pride (though in this case, over a tweet, you're probably right).


"though in this case, over a tweet, you're probably right"

Well, maybe not: https://twitter.com/zeeg/status/294305445521268736


Reverse misogyny. Had a man wrote a blog entry about crying due to 'boohoo comments' on the internet would get chastised out of the industry. A woman writes a blog entry about how her feelings get hurt and everyone with a set of swingers breaks down , puts on their big boy/high moral pants, and makes a grandiose apology (via published blog post, rather than private channels, because the fanbase must be informed lest we reduce our hits per month!)

Is this really a 250+ post thread about someone getting offended on the internet? Want to see an artist get offended about their work? Go check out deviant art.

Open code is inevitably peer reviewed. The development community since the mid 80s has been notorious relaxed, leisurely, casual. No suit, no tie culture. Are you really upset that you received a negative peer review in casual tongue?

Science has a similiar dilemma with peer review causing depression. Science and academia, however, do not have the same casual environment, however, and that is reflected in the peer review. Instead of "My eyes are bleeding", you receive things like "Das ist nicht nur nicht richtig, es ist nicht einmal falsch!" ("Not only is it not right, it's not even wrong!") Is that not rude?

Don't open up your code and you won't receive harsh sentiments from those that read it. Worked for MS.


Or, you know, be nice, constructive and positive and encourage people to open up their code.

Maybe someone's poorly written tool might save you a days work in the future.

Also, there's a difference between peer review and making fun of them/attacking them. If you can't see the difference, I wouldn't want to work with you.


The story isn't that someone got offended at constructive criticism. For starters, the criticism wasn't constructive or academic, and the criticized thing was just some little tool in a github repo, not an important physics paper, and the reviewers were just assholes, not brilliant assholes.

It was just bullying. And this is the story. It's true, of course, that a man would not have this recourse. He's expected to "man up". The legs of this story are that lots of people have this terrible attitude, almost everyone has seen it and it is hurting us a lot.


I get that. I understand the criticism that was offered was not constructive other than pointing out :

"Hey, look. sed does this too. Waste of time.".

My point in quoting Pauli was not to show you that academia stays far away from non-constructive criticism. Quite the opposite.

How does "You're not even wrong" help the author of the paper? It doesn't. It's an intentionally low blow meant to make the person reassess their position on the opinion they expounded upon. It's constructive in the fact that "maybe it'll knock some sense into them."

I, too, think the authors of the tweets acted in poor form. However, I have stepped back and looked at this for what it is, someone being upset about bullying on the internet. Bullying in a pseudo anonymous information exchange should not be surprising to anyone, nor should anyone take it so personally.

No boss is going to hire someone else because you got heckled on the internet, sorry. It'll be because you were lesser qualified than the other applicant.


I don't know Steve Klabnik or Corey Haines (or any of the other people mentioned in the post), but I just lost a lot of respect for them.

If I do come across them (in a forum, in person etc), I'll remember more about how they tend to make disparaging comments about people on the internet rather than any code on github.

Lastly, kudos to you for writing code, solving a problem and putting it out there. I think is great what you're doing and you should ignore non-constructive criticism.


First time I've come across them too but the irony of Steve Klabnik's post is incredible http://blog.steveklabnik.com/posts/2011-08-19-matz-is-nice-s...


David Cramer's response (via Twitter): "Are you mad that the Internet disagrees with you? Maybe get off the Internet?"

https://twitter.com/zeeg/status/294305445521268736


Douche is as douche does.


I got into an online argument with David Cramer years ago about something truly meaningless, but the notion that he is an asshole just stuck with me for some reason.

He seems like a terrible representative for Disqus. I wouldn't be surprised if a few people were turned off from working there when they discovered they would have to work with him.


Remember that time you disagreed with me and had to write an entire (factually incorrect) blog post about it?

I assume you like internet drama.



Well she wrote it in JS using Node, CLEARLY she was asking for it


If I weren't crying so hard right now I'd think about clapping. Too soon.


I'm so tired of this.

In honor of harthur's efforts, and to take a stand against bullying, I've decided to fork the project. I'm currently porting it to Python!

https://github.com/kennethreitz/replace

I encourage others to do the same in their respective languages :)


Thanks, Kenneth. Actually, I've already forked and used harthur's code several times in the past -- she's written some really cool machine learning stuff for JavaScript that is easy to read. I've used it as the basis for playing around with machine learning in Python and JavaScript, and last year I tried (unsuccessfully, I think) to use d3 to create a nice visualization of her implementation of the k-means algorithm[0].

My visualization turned out poorly (I've had a few suggestions on how to make it better that I need to integrate, and am still open to additional suggestions). However, that obviously had nothing to do with harthur's excellent clusterfck library that I used[1].

Really, when you look over harthur's github contributions, she seems like the ideal open source contributor. She uses permissive licensing, writes clean code (in my opinion), uses unit tests, documents a lot of her code, chooses cool projects, etc. These are features I'm striving to integrate into my own code as I try to transition into programming as a profession instead of just a hobby (and I'm slowly getting there).

0. http://www.ericbullington.com/articles/2012/01/31/kmeans-vis... 1. https://github.com/harthur/clusterfck


Nice! I posted a similar sentiment here:

http://news.ycombinator.com/item?id=5108181

Perl or PHP, because why not?


I've now taken a sudden interest in either forking or writing one of my own as a learning exercise...and also in reading up more on node.js (which I've been ignoring).


That's pretty infuriating. Learn to grow callous to it, laugh it off, and bury your head in the ground and keep pushing forward. You'll have assholes from every corner of the earth say demeaning things. But now I know Steve Klabnik is a dick, and Heather Arthur is a decent human being who's willing to put her work out there. Keep doing that and you'll be the happier person in the end.


  > Then I see these people’s follower count, and I sob
  > harder. I can’t help but think of potential future
  > employers that are no longer potential. My name and
  > avatar are part of its identity, and it’s just one step
  > for a slightly curious person to see the idiot behind
  > this code.
Oh come on now. Potential employers are not going to be crawling through your github on the off chance they can find a hastily-written script to laugh at. If they do claim that they won't hire you because you wrote this tool, they are lying to cover for some less socially-acceptable rejection cause.

As for why people are laughing at this project, it's likely because you reimplemented a time-tested tool (sed) in a flavor-of-the-week platform (node-js) without any obvious awareness of how silly that looks. If you put a quick explanation in the README, like "I wanted a 'sed' that used Javascript regex syntax", then I doubt anyone would make any such fuss.


> If you put a quick explanation in the README, like "I wanted a 'sed' that used Javascript regex syntax", then I doubt anyone would make any such fuss.

The second sentence of the readme is "It's similar to sed but there are a few differences"


  > Oh come on now. Potential employers are not going to
  > be crawling through your github on the off chance they
  > can find a hastily-written script to laugh at
No, they won't, but they do sometimes hire something new and worse than Checklist HR folks, Social Media for HR Researchers. At some point someone is going to hit an automated connection between "Heroes" and negative comments on other's work. It actually sounds like a "good" startup idea. Klout for hiring.


No one worth working for who's technical is going to not hire you because someone heckled your script on twitter.

A recruiter isn't going to pass you up either. Recruiters will spam the fuck out of anyone with a github follower.


The funny thing about companies with arbitrary automated no-hire filters in their hiring pipeline is that they tend to be places such a programmer wouldn't want to work at anyway.

Say there's some HR department out there silently dropping any candidate that doesn't have a LiveJournal account. Would you worry? Would you even care?


Don't really know. I did get turned down for an internship because my high school was in the same area code as the college I went to (whole state is one area code). I really did want to work there.


I hope the keyword is 'did' -- if the hiring process is that robotic and stupid imagine the rest.


It's not always that simple. In a big enough organization, there can easily be good parts and bad parts, with the bad parts worth tolerating, especially if the bad part is just an upfront cost like a dumb hiring process. I might put up with some annoying corporate HR crap if it meant I could work at someplace like Xerox PARC in its heyday.


It was a DOE national lab, so it still stings a bit. It is probably why I absolutely hate the phrase "fly-over state" and tend to think less of people using it. It is probably also why I have such a visceral reaction to this article http://news.ycombinator.com/item?id=5069195 and its author.


This is par for the course in the Rails community. Once some Rails devs get more experienced, they think it's ok to shit on everyone else.

Granted, not all are like that...but many are.

God forbid you should stumble into #RubyOnRails on IRC. Thank God for Stack Overflow!


This to me is very unfortunate. I'm an experienced Ruby and RubyOnRails developer, and I think that this is totally unacceptable. This is why the Python community flourishes (and I learned to code with Python!), and the Ruby community, which has unfortunately become equated to the Rails community, relatively languishes.

I also think it's pretty funny/awful/ridiculous to see Rails devs hating on JS code. (JS is difficult to write well, and is NO LESS FUBAR than your average 3+year old Rails app). As recently as Rails 2.x, Rails was using Prototype... how'd that work out? For fuck's sake, how much human decency does it take to be civilized and constructive?


Responses to Heather's post from a relatively well-known Python developer:

https://twitter.com/zeeg/status/294305445521268736

https://twitter.com/zeeg/status/294306974248607745

https://twitter.com/zeeg/status/294307486331187201

I guess it's just not all that black and white, is it?


Yeh...I have had brash remarks from #Ruby too and not to mention #PHP and other communities for other languages.

So I don't think this is exclusive to the Rails community.

But, what pisses me off so much - and disappoints me more, is that Ruby (and by extension Rails) is such a beautiful language that allows me to do so much with such clear, and elegant syntax - that I have an expectation that other Rails & Ruby developers would generally be pleasant and nice. Not dicks riding on their high horse because they are the tallest kids in their corner of the playground.

When, in the big scheme of things, they are just 3 feet tall.

This particular instance is even doubly disappointing because I love Hackety Hack and Shoes.rb (which both are made for beginners). Why on earth would I now dedicate some of my time, when I know the maintainer will probably be ridiculing my code behind my back? Now this has just confirmed it.

It's actually quite sad and disappointing. No amount of apologizing will make up for it - unfortunately.


#python is dominated by a toxic cabal as well, so that is unfortunate.


Seriously? I'm always on #python, and I find nothing but polite people there. :)


It used to be much worse.

It seems to have improved significantly over the past year. Not sure why.


The developer of Prototype had to handle also with a lot of criticism and there is his response: http://sstephenson.us/posts/you-are-not-your-code

"I have learned that in the open-source world, you are not your code. A critique of your project is not tantamount to a personal attack"


A quick scan of the project source doesn't suggest that "it makes my eyes bleed" was a fair criticism. It isn't going to cure cancer or solve deep problems, but who cares? The world is full of projects where people just snap a few cogs together and hit "Show HN" on their way to "... 3) Profit."

If you are going to put something in the public space, you have to be ready for any trolls in the vicinity to take a dump on it. It's not fair, but it's the economy of attention and identity at work.


"It makes my eyes bleed" is never fair criticism. It's vapid and meaningless and if I can implore just one person to stop saying it, I will feel like I have achieved something with my life.


Never say never. Imagine, say, a contact lens solution...


My wife actually did put in the contact lens deep cleaner into her eye instead of the regular saline drops. Her eyes didn't bleed, but we did get a tour of our neighborhood's lovely new Emergency Room.


I really like the easy to use approach of replace, and don't understand why every hackernews comment falls back to sed and grep. Free software is about choice, and this project is certainly another viable one. Thank you for open sourcing it!


Agreed. It actually works a lot like zmv in zsh[1].

I probably won't use it but only because my stack is mostly Ruby and I generally use Ruby or sed for this sort of thing.

[1] http://zshwiki.org/home/builtin/functions/zmv


Man I know how this feels. The very first piece of code I ever open-sourced (5 years ago) was put on a "Wall of Shame". Turned out though that the person doing this had never even looked at my code, they were just a petty, jealous person who saw something with a title that irked them. I don't claim to have great code, but I am happy to still be putting lots of open-source code out there, and I'm happy I didn't let that first asshole discourage me. Fortunately, the rest of the community saw that this guy was an asshole, and the "wall of shame" was quickly brought down, but it'd be really nice if we didn't let such petty assholes make it into a position where they can ridicule people in such a public and far-reaching way in the first place.


What's all the drama about? So what some famous people criticized your code. Get over it. They may disagree with it for whatever reason ultimately it's you who has to find the tool useful. Please don't whine about it just take it with a grain of salt they could be a million reasons they would say that.



Here's the Twitter discussion alluded to in the post:

https://twitter.com/harthvader/status/293829635823792128

Main justification is the nicer syntax. I agree it's nicer, but would approach it by wrapping sed, not re-implementing in Node.js from scratch.

I don't think that excuses the ridicule, though.


The maximist point of view is to wrap sed, yes. But what also came to my mind was what if he/she just wanted to only learn, I can think of no better way than to try to write it 'yourself' in the language of your choice, if only as a learning exercise.

All to often we in technology assume the maximist point of view, possibly completely discounting another dynamic point of view or some inspirational reasoning (of the originator).

*edit: spelling


Me neither. It's not as if klabnik was asked to use it. Plain old rude, in the name of defending no principle in particular.


How would you get sed to output the files and lines on which replacements happened?


How about using diff and sed -i?

  # This version is obviously unsafe
  verbose_sed() {
    sed -i.old -e "$1" "$2"
    diff -u "$2.old" "$2"
    rm "$2.old"
  }
  
  verbose_sed s/vim/emacs/g rant.txt
You could then use all the tools that we already have for working with patches: colordiff to colorize the output, diffstat for a summary of changes, patch -R for reverting the changes, and so on.

Of course, you're more likely to than not already using version control, which gives you all this and much more, even if you were to use vanilla find+sed.


I don't think rewriting as a wrapper around sed would be an improvement. That would put you in the business of translating one regexp syntax into another which is probably more error prone.


I don't care how "popular" these guys are, they are douchebags. This kind of bullshit behavior is stopping me from trying Ruby.


Which is kind of sad, since old ruby community even had MINSWAN motto (Matz Is Nice So We Are Nice). I don't know when and why everybody became so abrasive.


This makes me sad, as a Ruby dev. This does not represent all of us, although apparently it represents a lot of the higher-profile public-facing members of the "Ruby" (Rails) community.

There are lots of us aren't like this. I guess we will have to become more vocal.


  $> diff @coreyhaines-apology @steveklabnik-apology
  < grace
  ---
  > sorry if i made you upset
A side-by-side example we can all use to learn how to apologize better.

[1] http://programmingtour.blogspot.com/2013/01/im-sorry.html

[2] http://blog.steveklabnik.com/posts/2013-01-23-node


Seriously, i dont know what everyone is getting worked up about. Some wannabe smarty pants said something mean on the internets. How is that different than any other day?

Steve Klabnik: what exactly is his claim to fame [2]? Lets all mock him for reinventing the wheel with 'pomodoro'. "Messes with your hosts file" and run some crap ruby daemon on :80 so you can't browse the web for some number of minutes? WTF: it's called a proxy people or iptables. Why reinvent the wheel? OHHHH and a big no no here: shelling out to the system. LOL, the irony [1]. I need HIGH PERFORMANCE on everything I do including a local webserver. Gosh.

Corey Haines: huh? some software trainer who has written a well known anything? His github is less than inspiring.

Some other ruby people: big whoop. Lets see their githubs and then we can all point fingers.

[1] https://github.com/steveklabnik/pomodoro/blob/master/lib/pom... [2] https://github.com/steveklabnik/bring_back_snowman


I'm flagging this post, as it adds to the negativity cloud.


This seems like a nifty utility that lacks the learning curve of some classic Unix tools.

Granted, it duplicates stuff in sed and grep, but it looks like it would probably be useful to many people.

A project this reminded me of: http://betterthangrep.com/


Seeing this sort of negative behavior, both in groups online and off and coding and not, affected me greatly, even when I wasn't the target. On one hand, it gave me pause to consider and critique my own work, enhancing the final product. On the other hand, it made me go into over-perfectionist overdrive and too scared to release stuff lest "everyone" hates it. This fear, however irrational, has gripped me for many years. Stories, scripts and projects being left in folders partially because I wasn't sure where to go with them, but I believe in part that I was too scared to see it through and be rejected (The McFly effect, if you will.) I'm only now just coming to terms with it and learning how to, excusing the french, not give a fuck what others think. If I'm happy with it, that's a great start.

It's like with improv comedy: Denying the other person doesn't go anywhere and typically ruins the whole scene. Working with the other person in a positive light,though, goes miles and miles.


This is kind of saddening to see, but it is a crime that virtually every programmer has committed at one point or another in their careers. Let's be honest - in some cases it can be quite fun to do. The underlying problem is the ego, and the corresponding lack of objectivity that results.

From reading someone else's code - even glancing at it in some cases - one can infer a great many things. For example, if the indentation on some code is totally borked, most programmers will immediately be extremely doubtful about whether that code contains any interesting or useful ideas (though of course this is not always the case, counterexample being intentionally obfuscated code). In some cases, they will simply refuse to continue attempting to understand the code and dismiss it as useless. A similar thing can happen at the semantic level when the programmer detects a mismatch between the language/framework being used and the problem space; this dissonance is likely what is irking all of the people who are so childishly ridiculing your replace utility.

Sometimes when you're looking over someone else's code you spot some perceived inconsistencies/flaws/bugs. The crucially important part is what you do next. If you choose the route of publicly shaming them to stroke your own ego, then you have not only hurt yourself by appearing childish, insecure and unsociable, but you have also hurt their feelings. It's important to remain objective in these situations, and take the self out of the equation. If you HAVE to indulge yourself by tearing the code apart in a humorous manner then at least keep it between with your friends!

As I alluded before, I would guess that the reason people where poking fun at it was probably because there exist a lot of other utilities which have the same functionality and are readily available on most any system. Personally, I thought your code was interesting, and I thank you for choosing to make it public :).


> I can’t help but think of potential future employers that are no longer potential.

Remember that this also applies to the potential employers of the people making these remarks. I don't think employers like these kind of toxic comments and sometimes I think Twitter actually has some use for decent people in that it acts as a honeytrap for exposing certain tendencies in not-so-decent people that would otherwise go unnoticed due to the holier-than-thou aura these people create for themselves. "Bro, look at his code! Guys! Guys! Look!"


A tool like "replace" is actually very useful for someone like me.

Within the past year I've been learning OS X and the associated Unix environment (coming from a Windows background). At times I wonder how to do find/replace in the command line. So I look at sed. Glance over the man page -- what the heck? Google it; okay's so there's apparently different versions of sed, and OS X has something weird with -i since it's BSD sed instead of GNU sed... and oh look! It uses a different type of regular expressions than I've been using for the past 10 years. And, oh crap, I just accidentally overwrote my file because I typed in the command wrong.

The alternative for me is to open the Coffee REPL and get that crap done in seconds.

Yeah, I'm slowly picking up the Unix skillset (and Vim is invaluable after finally getting around to learning it), but I think people forget the sheer amount of memorization involved to navigate in a Unix environment.


This guy needs to stop being a pansy and grow some balls.

Oh noes! Someone on the internet doesn't like my work! My world is over!

What are you, a little girl? Nine, maybe ten years old. I'm seeing pigtails and a frilly skirt.

Get over it dude. It's impossible to make everyone happy. haters are going to hate. No need to make a big deal about it.


What are you, a little neckbearded basement dweller? There's probably little ten year olds girls ballerinas that could kick your wimpy ass.

Just, heads up, it was a girl that got wrecked on, and your comment is offensively sexist and, disregarding the situation, just generally inappropriately so.


I didn't realize it was a girl until after I made the post.

We should all feel sorry for her. Women are special creatures that must be protected and sheltered at all costs. How dare some men say anything bad about her.

Oh wait, they didn't say anything bad about her. They didn't even say anything bad about her code. They disliked her project. She even said most of the comments where positive. This is nothing more than attention whoring.

And you fell for it because she's a girl.

If you put something out there, people are going to hate and criticize it. Doesn't matter if you are a boy, girl, or three toed sloth. Just because she's a girl doesn't mean we should pay attention to someone who whines when a few people hate on the project. Nor does it make those haters terrible people. You don't hear Douglas Crockford crying every time someone criticizes him. And you don't get this upset at the developers who do criticize him.

It's sexist to treat her different because she's a girl. Everyone is criticized.


I hate to say this -- as an older person -- the only solution is to get a thicker skin, because people on occasion are going to be assholes to you. Even good people in a moment of snark. Even when they completely misunderstand what you did and that it is good. And worse, there are those who just tear down anything. It's just a fact of life. I suggest you read Feynman's "What do you care what other people think?" It helped me a lot.


Spot on, this does get easier as one gets older, but one thing that makes it harder is Twitter itself. The nature of Twitter seems to create a primary-school-like atmosphere because of the short format and asymmetrical following mechanism. When you don't have the bidirectional communication it creates an effect like young children or people with underdeveloped social skills where you don't see peoples reactions and have a poor sense of what's really going on around you.


Even if the tool wasn't as useful as the traditional tool users have liked, I think that the following was an interesting comment:

  I think that, at least hypothetically, this app won’t be 
  significantly faster written in C than in JavaScript. 
  It’s I/O bound, and in JS regular expressions get JITted
  to native code (which sed won’t even do!).

  The real slowdown here with our current JS 
  implementations will be overhead for creating and
  replacing-in strings. This app actually just gave me a 
  crazy idea for how we could optimize this kind of usage, 
  so I wanted to say thanks!
http://harthur.wordpress.com/2011/06/06/replace/#comment-776


Maybe it's cultural, but what was ridiculed was the project, not the person. Russians, for example, make a clear distinction between the two, so what the tweets said didn't shock me somehow.

I can totally understand how one can take it personally and I definitely think the apologies were necessary. Even though I am Russian, I would certainly apologize profusely if I had offended anybody for whatever reason and would be sincerely sorry.


The person was ridiculed, FWIW: "...but I don't want to build my app on top of others' code who are at this level of understanding..." is insulting the person, not the project.


I have to disagree, somewhat. It's about the person's skills (or lack thereof), not about the person. An insult to the person would be "you're ugly".

I can totally see WHY someone can get offended, and I am not saying it's OK to say those things. But in my culture this would not be a problem because of what I said above.


Reimplementing existing tools is a great way to learn and enhance your code fu. Hats off to the author. Haters gonna hate.


At my office, I would be very angry if I encounter your tool. That would mean that the guy who has brought it was too lazy to learn the proper way and makes me waste my time learning how to use a useless tool. Your tool has no advantage over standard unix tools, it is just limited to a reduced number of use cases.

This kind of tools does not favour improvement of skills or good practice. I think this is the cause of the strong reactions.

On the other hand, your program seems well coded and I may use it when I need to code something similar in javascript. Thank you for open sourcing it. I think you should update your README.md file in order to indicate the proper way of doing things and to discourage the use of it for any other purpose than learning.


I think you should update your README.md file in order to indicate the proper way of doing things and to discourage the use of it for any other purpose than learning.

Ack isn't a "standard unix tool" either. I use it all the time.

You're being a presumptuous asshole in telling her to discourage the use of it just because you don't like it. I get that you're trying to be nice. You're not succeeding. You're being the problem. Stop.


In my work I have always to go from one computer to another one (to analyse software problems). Sometimes I need to ask a developer to come on site to give a look to the behaviour of its code. It occurs very often that very good developers are completely lost when they arrive on a computer where all their marvellous customizations and shortcuts are missing.

Many developer are always on the same environment. They can use their own tailored tools and may not need many of the basic unix knowledge.

I think that good practices should be encouraged. The good practices improve the skill of people and reduce the costs at the society level. The basic knowledge of unix tool has an exponential rewarding effect (by learning a couple of new tips, you can solve many new needs). This tool facilitates the avoidance of these good practices.

I do not like people ignorance and I favour knowledge. I do not like losing time (except on HN) and I favour speed. I admit, this is a personal opinion.

We do not have much time to learn everything. I think the time spend learning "replace" should better be spend learning "sed". Try to use sed each time it is not longer than opening a text editor and doing a find and replace manually. This way you will not lose your skill.

Ack is not a basic tool you have chosen to avoid learning grep. All the basic options of grep are the same in ack. As a result you will not loose skill by using ack.


Which shell commands you use is a micro-detail. There is a surplus of shell commands, most of the features of which go unused. Meanwhile, some people are coding on Windows or an Apple platform and not using any of this. It really doesn't matter. This is nothing but justifying wanting people to do things the same way you do, without being able to explain why it is actually better.


Reread what I wrote. I have been moded down enough for giving my opinion about why this additional shell command can makes people angry. There are perhaps many young developers here that are fed-up listening to old ones telling them to learn basic unix way. I can understand them, but this is not a sufficient reason to reinvent the wheel without improvements, or to negate the obvious.


The so-called standard unix tools are just historical artefacts, there's nothing particularly special about them other than they were the first. sed is an arcane language which in my personal opinion is not worth learning (maybe it was for you), and for all but the most trivial tasks it's probably a better idea to use a proper language like Python. After all, the whole reason for Perl's existence was that sed/awk/sh were lacking.


I am a perl lover. I fully adhere to the idea that perl (or python or ruby or javascript) should be used instead of sed/awk/sh/grep/find each time we need to go beyond the basic usage of these commands.

I have never said that everybody should know the arcane parts of sed (http://uuner.doslash.org/forfun/sedtris.sed). The unix tools work best when they are combined together (with pipes). The basic usage of sed is very useful to combine unix commands. Knowing the basics of standard unix tools has always been a time saver for me. Here is an example of a command that I may need in some unusual cases:

for i in $(awk '/PWP/{print $1}' machines) ; do

echo $i; rsh $i df . ; done

In my case, it does not worth being a script, because I may not have the same need before a month or two. Without unix tools, this would be a pain in the ass.



As the lead developer for Cryptocat, this sure rung a bell for me.


There's something to be said about encouraging people to use crypto software that might not be well-written, though. To me, it's fine to write whatever you want in any language you want, but if you write an application and market it as "communicate securely and anonymously", or any kind of software that could put people's lives at risk, really--like Tor--you should be confident it is secure, i.e. that you know how to get it right. You are literally putting people's lives at risk, not just writing software that might be buggy, or which some people might not find useful.

IMO, the "lol, look at this, pathetic" for using node.js is inexcusable (regardless of what your opinion about node.js, and for the record, mine isn't favorable), but "X application has serious security holes in their software that could put you at risk. Don't use it" is not. For example, I don't consider this "bullying": http://www.schneier.com/blog/archives/2012/08/cryptocat.html

All this being said, I'm glad you powered through (https://blog.crypto.cat/2012/08/moving-to-a-browser-app-mode...) and solved the issues. OTR is awesome, and most of the critics have come around, AFAICT. Many others don't listen to this kind of feedback, and so deserve the critique all the more.


Oh absolutely. As Schneier noted in that blog post, we did solve the issues that were presented to us, switched to a signed browser plugin, OTR, got a full audit, and so on. But other than the handful of awesome and helpful critique, man were people assholes on Twitter.

I stand by Cryptocat being a usable privacy tool today, and I think we were quite responsible in our development process. There's always media hype making us look like something we're not (a magic bullet for activists and other people in danger to solve all their problems,) but that's why we have warnings everywhere on our website and inside the app itself.


Yeah, don't get me wrong. People who have nothing to add can go disappear.


Thanks, man.


There are a few open source projects which I would be willing to ridicule. In general the projects have traction, a significant history, and horrible code which never gets more than marginally better over more than a decade. It is one thing to be starting out. It is something else to decline self-improvement.

The problem though is this (and I have been on the receiving end of very harsh criticism of people I respected, some of which was shown correct over time), that there are often problems with critics jumping to conclusions and at the same time not being very detailed. Thus a response like these tweets can only be a "gut reaction" and never really very helpful to anyone. There is no time involved trying to grok the code. There is no opportunity to discuss what potential tradeoffs have been made or why. These two things need to be corrected.

I don't think folks should criticize code without trying to work with it and understand the API's. I don't think folks should leave a critique like "that's the old 1990's way of doing things" or "that code sucks." It is much better to get something like "So I see a few problems with the code... and ...."

In fact the few times I have gotten the latter (publishing code and getting responses like "I see some important concurrency issues there. This isn't safe to run on production.") I have been happy with the panning because I could fix the problems. But that's a far cry from what the article is referring to and it is, unfortunately a lot less common, IMO.


Although I don't see anything particularly wrong with that script and why people are laughing at it, she needs to be less sensitive and not take it personally. After all, publishing open-source code is a very public act and makes you a very easy target for criticism. Imagine if the Linux kernel devs cried every time Linus went on one of his abusive rants. Not that I'm particularly defending this abusive behaviour, but you have to be realistic and realise that it happens.


Someone's going to cry over this? I would have thought going through normal ridiculing in middle school and high school would have toughened someone's skin enough. And why are you even paying attention to the great twitter circle-jerk?


I wonder if the amount of ridicule correlates with the fact that the author is a woman?


It looks fine to me, I would actually use something like this internally for employees who can't regex. Except the node.js part, but that doesn't make it any less useful, I respect that other people use other tools.

The part that I see some may disagree with, is when these apps are posted in public repository indexes (npm). I feel a usefulness filter should be applied. That may be at the heart of the comments. Not that it was posted publicly, but that it was included with a generic name in a public repository (https://npmjs.org/package/replace), now it has the potential to be annoying to some users. The way these guys disagreed was just, ugh.

I write all sorts of cool little networking utilities for my company, but they were not ever intended for an end user, but could be used or adapted by someone else very quickly. My code doesn't leave my company (probably shouldn't, I'd get torn up just like this, I know it). If it did, I would just not want it in a repository.


I just wanted to point out that the code (I know, it's not about the code) here is perfectly fine JavaScript, much, much better than tons of JS I saw in the wild. "eyes bleed"? What the heck? Have these guys never seen truly bad code? And if it's really just about language war...

Look, I understand that one can prefer one language over another, but trashing the code someone already written (meaning you won't be forced to write this thing in this language if the need be) is so short-sighted, so closed-minded that I can't find proper words to describe it.

I almost refuse to believe that this is the kind of people who are the "stars" of communities - I really thought that to be really good with one language you need to know and respect many others and I thought that being a "star" involves being being good in the language you want to champion. I guess I was just deluded and we're choosing those who yell the loudest as our representatives. Whatever happened to meritocracy?


This seems like a totally reasonable way to deal with criticism.

Also, "I can’t help but think of potential future employers that are no longer potential." because some guy called Steve Klabnik and his wannabe follower Corey Haines who wants to suck up to him say your code sucks?

Don't take yourself so seriously please.


First of all, I don't think it matters whether a man or a woman wrote the code. I for one didn't know when I read the link, until I saw this discussion.

There are several aspects to this. The obvious one is that anything you put out there is going to get criticisms. Look at Barack Obama being called a socialist muslim atheist, who attended Rev. Wright's church for 20 years. The point is, if you step up, not everyone will like you.

Now, being denounced by people who are well-respected and with a big following can hurt. Then again, I doubt it's very permanent. If this is the ONLY thing you've ever done, then you should just do more things.

If you are that sensitive about something, don't release it under your own name. Invent a handle just for this project. Kind of like a limited liability company. The art of the pseudonym goes back hundreds of years.

Also keep in mind the culture. Unfortunately in my opinion, the coder culture is full of elitist snark against noobs who are too visible. Maybe because it's so male. I have seen far worse reactions to people's code on IRC, especially some assholes in EFNet chatrooms. Freenode seems a bit nicer and well-behaved. But saying ridiculously quirky offensive things in response to code is something coders do to each other all the time. It's just the way many of them speak. I personally don't, and I find it extremely annoying, and I wish it would go away, but it's the reality.

Now as far as open source ... I remember releasing what I considered to be a very impressive (at the time) framework, http://phponpie.com , and although I got pretty positive responses http://news.ycombinator.com/item?id=1682933, and constructive criticism, it didn't really take off. I tried a bit of self-promotion and it didn't pay off either. So to me, releasing open source is kind of a lot like releasing any product ... if people don't really want it, then you're putting in a lot of effort for almost no return. Think about product-market fit in open source, just like anywhere else.


Those people are arseholes, but sobbing? There's no sobbing in business (to paraphrase Tom Hanks).


This code is better than 90% of the code I've seen. Why? It shipped.


It strikes me as the OP is a new-fangled node.js programmer who unwittingly stepped into shell-script land and felt the judgmental wrath of those who dwell there.

This post has a lot of conversation which I take to mean it touched a nerve with a lot of people as it did me. I grew up when computer nerds were not cool and a lot of guys dealt with it by being self-righteous, condescending assholes. I thought those days were behind us now that computer guys and gals are off getting rich and running the world. But clearly the need to feel superior still exists in some communities. It bums me out to see people who otherwise do good work with such a mean-spirited attitude.


People will criticize your work, good or bad, can't take every comment on twitter to heart.


The fact that these are "big deal" developers on some pretty important projects is the problem.

Also the fact that Mr. Haines is always promoting improving ones craft by writing code makes his comments even worse.

I feel that this comment on being a dick by jbrennan to be pretty decent:

"Next time you feel like mocking another developer for his or her lack of skills in a certain area, stop yourself. Talk to the person and explain to them why you think something they are doing is incorrect or how it could be done better. This way, you don’t come off as a jerk, and the other developer learns something new and improves. And I’d be surprised if you didn’t learn something from the experience, too."


Developer elitism at it again. The dev community really needs to lose this trait.


I can't find any reasons to tweet stuff like that. Pretty sad to see that the mentality of some "popular" developer is.


Yeah, if they really had to get off on criticizing other's code, why not use IM or email? To do it on such a public place as twitter is kind of cruel.


I always cringe when i see a blog post along the lines of

"A great way to do X in unix"

because it is almost always followed by the true unix gurus coming on and schooling the poster.

literally, people: assume any unix script you post, no matter how trivial, must meet the standards of a mathematical proof to Fermat's Last Theorem.

and i must confess, i look down on bloggers that blithely post a unix script. Not because of their lack of Unix foo, but rather the shear naivete of posting it (and the ignorance of the fact that the grey wizards will come out of their tower and pound you for anything less than perfection)


You have been ridiculed by a RoR core team member.. that is pretty awesome.


Inorite? A Rails core developer dissing someone for gratuitious use of Node.js. Now I've seen it all.

This project https://github.com/harthur/replace is some of the least sucky code you're likely to see in a month of reading Javascript.


who's a rails core team member?

klabnik isn't: http://rubyonrails.org/core



That second tweet still makes him look like an enormous douche. You're right about the communication skills.


Fuck it, ship it.

At least you're contributing to the world and bettering yourself.


And we wonder why the programmer geek/nerd/shut-in stereotype or whatever sticks. We fucking step all over eachother as a chance to look better. "Oh, look, someone wrote a helper function that does something I already know how to do."

What's the benefit of calling that person out?

Seriously. Answer that question before you take to a twitter mob.

People through this thread argue whether its worth the time, but if it took Heather one hour to write it, the function paid for itself once she used it for an hour of work that would otherwise be spent crawing man pages.

Hell, she says it was written a few years ago. Every piece of code I wrote two/three/four years ago can be looked at and often makes me cringe. You learn in time but that doesn't mean you should vanquish your mistakes. Grow from them, show them proudly as a statement of where you were and where you've come from. Whether you've evolved to a better programmer or not if that single function proved useful to you at one point it means that just one single person out there needed it. Does it make you wrong for not knowing/finding the tools it mimics? Maybe, but without someone beside her in the first place how should she have known. Perhaps taking to twitter with a knife for someone's back is a better start?


Very disappointed with the people that made these statements, they should know better.

Kicking other peoples puppy is never cool, people forget where they started.

Some times you have to take this sort of crap on the chin and keep hacking away, the best thing you can do in situations like is just ignore them.

I think in this case they have realised how stupid their statements where and are hopefully truly sorry for the hurt they have caused.

Also a note to those with many followers, don't be a dick.


It's astonishing how somebody's earnest hard work, put out in the world for all to see and benefit from, draws so many unmitigated assholes out of the woodwork.

Is it jealousy at quickly and elegantly producing something simple and useful?

protip: here's how to recognize you made a mistake and humbly apologize http://programmingtour.blogspot.com/2013/01/im-sorry.html Good on Corey.

here's how to do the opposite http://justcramer.com/2013/01/24/being-wrong-on-the-internet...

http://blog.steveklabnik.com/posts/2013-01-23-node https://twitter.com/steveklabnik/status/294302391279435776 https://twitter.com/steveklabnik/status/294302539510337536

https://twitter.com/zeeg/status/294307568019464192


1.) Open Source is a meritocracy intentionally designed to counter the never-ending threat of software homogenization that profit motives lure us into embracing, not a soapbox for fleeting quandaries about morality and "social change" (whatever the hell that means for the week). Apples and oranges. Mountains and molehills.

2.) Open Source is not some cool kid's club where people who understand what a semi-colon can do try their hand at avoiding the recession. Even if coders did not make the money they make, THEY WOULD STILL BE CODING BECAUSE IT'S ABOUT TRICKING FUNDAMENTAL PARTICLES INTO DOING MATH FOR YOU. IT'S FUCKING AWESOME SO PUT UP OR SHUT UP.

3.) You code... you put it out there... and you have, literally, -ZERO- idea what is going to happen. People might like it, people might hate it.

Now this is the important part to my final point:

---IT IS NOT YOUR PLACE TO CONTROL OR FILTER THOSE RESPONSES---

So you throw some code out there and people don't like it? You get mocked by some asshole? And? What, did you expect civility and ponies and rainbows? What fantasy model of human interaction are you relying on as the core of such assumptions?

Nay, sentient being. It is your place to ADAPT to those responses.

So... in short....

There is a BLAME option in version control, so point out the flaws in her code or shut up. So there's that.

Now as per the frothy mob trying to turn Open Source into some anti-bullying kumbaya because they watch too much Rachel Maddow...

There is -not- a SHAME option in version control, so either understand what problem Open Source is trying to solve (promoting software heterogeneity) or go back to the service sector where people are forced to be nice.


"---IT IS NOT YOUR PLACE TO CONTROL OR FILTER THOSE RESPONSES---"

One could equally well argue that it's not your place to control or filter criticisms of those responses. You're essentially positing that the majority of people here are out of line for saying "don't be a dick". That seems contradictory to me.


Childish usage of a primitive understanding of dialectics isn't going to deter me. You'll have to do better than that.

This is me ADAPTING to your response. Not filtering it out. Not telling you to never again say those big, mean, nasty words to me. Not running the internet to summon white knights to my ever beck and call because I want to win some points that don't matter anywhere.

This is me, leading by example, how to ADAPT to your response.


The point is that you challenged my contribution.

And I didn't filter it out.

Nor did I tell you to stop challenging me.

I adapted.

It's a simple concept.


I have an application I've been working on for about 5 years. I started it as a way to learn desktop and object oriented programming, and it's now grown to something like 10,000 lines of code. There have been long periods of 6 months or more when I've not touched it, then gone back in and get started again, as a result the code base is a bit of a mess. The coding style is a bit haphazard and it includes a fair sprinkling of ugly hacks.

But by and large it works and would make a decent alpha release. There are a few bits of functionality that need to be made more robust, which I'm working on now, and when that's done I'm going to bite the bullet and load it into Github. I've implemented a plugin system so users can customize it, and tried to do my best to make that part of it as consistent and clean as possible.

I do worry that uploading this thing could cut both ways. I'd like it to get some use, but I'm very aware of it's flaws. I wonder home many projects never get released because the authors are worried about this kind of reaction.


Because of this post I learned a little bit about node.js and may want get into.

See how that works. And she has other interesting projects as well.


harthur, your work is awesome.


So here is a thing I've learnt as an artist: never offer unsolicited critique of other people's work. It makes you look like an asshole.

If someone WANTS crit, I will ask them if they really, really want it, and give them the caveat that I am probably going to rip them a new one. For my best artist buddies, I don't bother with the preface. They know how to detach themselves from their art.

And sometimes, yeah, I come across something so amazingly badly made that it becomes a thing of wonder. When I want to share that, I don't do it in public. I use private, limited channels. Email, private forum, locked Twitter account, whatever. Come to think of it I really tend to just say "holy cow look at this" rather than being super specific.

Tearing other people's stuff down in public makes you look like an asshole, period. Especially when you are tearing down the work of people less skilled and/or well-known. It also makes you look pretty insecure.


Okay, I upvoted this story for the sake of 'missing kindness', in general on the Internet.

But after having understood, the whole story. What replace does is that, basically it is a good small utility for the author of the post to replace some content from a lot of files, also recursively going through directories. And the author happened to make it depend on nodejs.

In defense of these folks, who made nasty comments: they appeared to have made so, in the context of this nodeJS-based-replace, attempting to replace the sed/awk/grep and unix scripting.

To any long time unix user, any quick hack to replace the said commands, does indeed appear to be falling short. And also a bit of a why would you need to do such a thing?.

Honestly, they should have been just empathetic enough to understand a non-unix user, hacking a quick utility, with the tools she is familiar with (nodeJS and javascript) to come up with something useful for self and friends.

edit: rephrase


Github is not a beauty pageant. We do not write code for the people to evaluate them aesthetically. What we do, however, is to learn and teach. What we did to solve that problem and if there are others, they may use our solution as a step to solving their similar problems or better, they may offer a better solution.

What did these tweets add to the so-called "eye bleeding" code? What did they teach? What did we learn from all of these?

If I was in Heather's shoes, I would feel anxious whenever I sync to my public repo in Github. Or anxious whenever I code, worry whether this code is "beautiful" enough. And, folks, no one has any right to make a person feel like this.

I don't mean "no there shouldn't be any criticism on github" on the contrary, if you have something constructive to say, go ahead and shoot. I would not make a repo public if I don't want to see my mistakes, improvement starts with realizing what a mistake is.


I'm amazed someone hasn't said "well that escalated quickly".

On topic, I've never really released code due to being scared of peer-disapproval, and also paranoid from the public display of potential attack vectors I haven't seen. I don't think that I will ever open source a live project due to these issues.

You should never say "that's bad code" without giving a reason why, and or showing how to make the code better. It's like walking out of a new release block buster movie and saying in a louder than normal voice "well that movie was bad". Anyone that can hear is going to start questioning, "what movie?", "why was it bad?", and instantly they are going to start wondering if the next 3 hours of their life is going to be wasted.

Basically I put this down to a generation of self absorbed twats that like to hear their own voice, and feel all warm and fuzzy inside when ever they grunt something "amusing" to their minions.


It is an unfortunate fact that this sector of the world has a higher proportion of absolute assholes than other sectors. Egos are extremely fragile, cognitive dissonance is high, arrogance is the norm.

I'd say don't let it get to you, but that'd be dishonest. It'll get to you. The thing is you can't stop. That's the hard part.


This topic is so hot in the community it's hard resisting the urge to weigh in. That being said I don't think I can add much to the particular direction the current conversation is going.

But given that I gave in to the urge to comment I do want to say this: Good job Heather! Keep up the coding and continue to have fun doing what you're doing. Solve the problems you see fit to be solved.

My guess is that you have a pretty good support network and you'll brush this whole thing off soon enough. However the next time you are one key-stroke away from submitting another project to GitHub, and you are given pause due to this whole fiasco, I say charge forward and submit. I look forward to seeing your contribution to the community. Just as I look forward to any contribution from anyone across the globe.


I agree with the other comments here. It reminded me, unfortunately, that I did something like that once:

http://thoughts.davisjeff.com/2007/11/17/700-queries-for-one...

I can rationalize it in a few different ways, I'm sure. But the bottom line is that, if it's open source software, the correct approach is to either offer constructive criticism directly to the developers, or just not say anything without being directly prompted (e.g. "should we use this software").

I can see exceptions for major projects with a large developer base. You still need to keep it constructive, but I don't necessarily think you have a responsibility to join the mailing list for everything you want to complain about.


I wish the guys involved would submit pull requests to amend what they thought was so bad. It has a better educational and apologetic value.

It also shows the kind of respect people should get; if you don't like the code you're seeing on Github, improve it and submit a pull request - why not?


Submitting pull requests is for code you actually consider worthwhile/useful. These guys didn't seem to think it even has a reason to exist, so why would they try to improve it? It'd be like saying, "Well, if you don't like my toothbrush for ducks, why don't you tell me how to improve it?"


I meant after they have apologized. Instead of saying 'sorry' in word and that they didn't really mean it, say it in a pull request teaching the person offended something of value.

Further, I think they shape of the code was referred to as 'eye bleeding'. Regardless of if you're building something worthwhile, they could have fixed the eye hurting code and explain why that is a more correct way.


I don't do much JavaScript or Node development but her projects look cool. As frustrating as this must have been for Heather, I hope that in the long run she might get some value from the publicity.

I was going to comment on the twits (misspelling intentional) but decided to stay positive.


This is a cultural problem. I don't see any reason to believe that this is because she's a she. This kind of horrible arrogant douchebag attitude is just an epidemic. If you are a guy, and especially if you are nobody known, you do not have anything like this recourse.


I replied to @steveklabnik's tweet saying (https://twitter.com/hardikr/status/293819210965082113)

    "There's also a search command. It's like grep, but with replace's syntax, and slower!" Wow - I'm sold!
If it was not clear, I was just kidding - and I apologize if my tweet and caused her any sort of distress. I'm just a novice in the open-source world, and I really respect harthur for her contributions to open-source. I was just "smiling" about Javascript's use to replicate grep. In fact, it is my Github everyone should be laughing at - it is filled with small useless scripts, and really terrible code.


Thank you Heather! I could never be bothered to remember the commands for the swiss knife that is sed to do something as simple as this. Why I love this:

- js syntax for regular expressions is what I'm most familiar with - defaultignore is very helpful - completely cross-platform - can be used directly from my other node projects that need to search and replace files - it's something i'd never be bothered to write because looking up sed syntax takes less time - so thank you for taking the time to do it and open source it!

Don't get me wrong - sed's great cause it's so powerful. Bash is powerful too. But I'm not a fan of either. Software should make our lives easier, not force as to learn cryptic commands to get simple things done. Compare "sed --help" to "replace --help". What will the future generation prefer when they need to do a basic search/replace task? The route of least resistance of course.

Making simple tasks simple is what real innovation is about. I don't consider myself a poor developer, I know a handful of languages, I'm just not a linux geek because I believe that interfaces should come first. I'm a developer / designer and I love simple and elegant solutions to every-day problems. Your module is exactly that. The reason some "experts" are up in arms is because it challenges the status quo. You no longer need to be a linux wizard to search and replace files. Hell - you don't even need linux. And the simplicity and approach of Node is what makes it possible. As Steve Klabnik said - this is actually their way of showing how much they hate node. And hate is a powerful word for "being afraid". And I'd be too if I dedicated a good chunk of my life to becoming a Ruby expert. "Ever wanted to make sed or grep worse?". Hahaha. I guess Apple I was also worse than the all-powerful mainframes of its day. That's probably exactly what the IBM guys said. Buy a PC that doesn't come with a screen? That does only a fraction of what IBM PCs do? Ever wanted to make an IBM PC worse? :) When the experts are afraid - that's when you know the Node movement is on to something.

PS Already almost 400 people have starred your project - I think that's saying something. Would be interesting to know the number of installs :)


Klabnik is the first to fight for rights etc, now he's doing exactly the opposite. He's trying to rise his own status by decreasing others'.

I wonder if all his fights aren't just a means to justify his own weaknesses and need to feel superior.


The criticism is so stupid too. Just because there's another tool out there already that can accomplish the same thing, does that mean no programmer should try to do the same thing again ever? How else do people learn?

And if she wants some of her work online to show potential employers or just to share, whats wrong with that? People should just mind their own business, and not be assholes.

If you don't like an open source project, make the same thing yourself, and make a post about how it improves on the older one. Don't tear someone down for not being as "smart" as you.


I don't understand, not the critics, not the project.

Why insult something that someone obviously put a lot of care into?

The code is nicely formatted and clear. I can see how it works. Props to harthur for making something easy to read and then sharing it on Github. Both readable code and sharing should be encouraged.

I don't really get why someone would want to implement text processing utilities in node.js. It seems to be a bit heavy on the overhead.

Might someone re-implement harthur's user interface (which a bunch of people seem to like) in c, and submit it to the GNU Coreutils project?


You know the Gmail extension that delay your mail, or the one that ask you at 2am if you really want to send that (drunk) text ? They should implement that in Twitter.

(note: I avoid Twitter as much as I can)


I see absolutely nothing wrong with this approach of writing your own tools. If a person feels that it's better, why ridicule it? Noone is forcing you to use it. If you feel it's not for you, that's fine.

On the other hand, some people are advocating this approach as a way to improve your programming skills: http://www.rodrigoalvesvieira.com/copy-unix/


So, I've felt the same way about uploading my own work-in-progress code to GitHub, but I use it as an antitode to perfectionism / procrastination. It's almost a form of militant pragmatism.

I've worked at some quite successful small companies, and they all share the property that you really don't want to examine the code too closely. The sausage is inevitably somewhat disgusting on close examination.


Steve Jobs' response:

"By the way, what have you done that's so great? Do you create anything, or just criticize others work and belittle their motivations?"


This is a lot what it feels like to blog about something technical, and then have someone swoop in and question not just your article, but your parentage and your IQ. It hurts a lot that people can't be constructive with their criticism, but I hope that Heather continues posting open source projects. Haters 'gonna hate, you just can't let them bring you down.


I've followed 2 of those individuals on twitter in the past. Note the tense.

I found CH to be particularly tiresome, all show and little substance. Also very much prone to contradictions, he doesn't seem to realize that people remember things. I haven't met him in person, but I imagine he talks quite a lot at a loud volume.


This blog makes an extremely good point. The industry we work in is very competitive and it's easy to get into the habit of making snarky comments about other people's code, even if you're actually not a jerk in real life. It's always good to remember that you should avoid doing this as often as possible.


Similar thing happened to me when I wrote a nodejs abstraction in GWT: https://twitter.com/jdub/status/25537683967180800. Gotta shrug off the haters when it comes to showing projects like this. It is the internet after all.


I never understood such gloating on open source communities. If you can change it for good, why gloat, why complain. There's obviously many reason to rage when you see bad code on commercial and privative stuff, but on open? Dammit, fork it, change it, contribute.

It was a bad behavior and people should understand it.


The disturbing thing is I never expected such a behavior/ being an accidental asshole (as he has later confessed) from a reputable online identity like @steveklabnik, a contributor to http://thechangelog.com besides many things


If their criticisms aren't constructive, they're wasting your time. Don't let them. Ignore them if that's all they have to say. I don't care if it's your mom or your boss or Jeff Besos or Obama, wasting a person's time is an insult to that person.


This just verifies my experience that Corey Haines is a fake.

His cult of personality is defined by lots of high-fives, 'that's awesome', 'i am such a positive person' statements.

So, he like to pretend he is really positive, nice, friendly... but this event shows that is all fake.


I've forked your repository and tried to offer some helpful insights: https://github.com/xmlblog/replace/blob/master/replace.js

I hope you find this useful in some small way.


Now that's a feature I'd like to see on github: an asshole filter.

What really bothers me is that, like me, I'd say a lot of those people learn daily from the work of others on the internet. What about giving something back? What about doing something to add?


(I copied this from another HN posting)

I was one of the people who made a comment about this. I'm also assuming the reason I was pulled into this is because people much more important than me said similar things.

I'm not going to defend that I think attempting to replace sed/grep is a bad idea (especially not in 140 characters), but I will defend people's opinions.

Everyone has one, most of them you won't agree with. Whether they're nice or not. I'm generally not a nice person, at least online, that's my choice. That said, especially with this being the internet, you have to deal with others opinions.

While some people may go above and beyond (even myself sometimes) and actually be very mean with their opinion, that doesn't change the fact that they're entitled to it. If you don't like it, ignore it. If you can't ignore it, then you won't survive.

The fact that people somehow managed to turn this into the continuous drama debate about gender is just pathetic.


> While some people may go above and beyond (even myself sometimes) and actually be very mean with their opinion, that doesn't change the fact that they're entitled to it. If you don't like it, ignore it. If you can't ignore it, then you won't survive.

In other words, if someone says something nasty, you have no right to say anything about it. Because the nasty person has an opinion, and it's their right. Great logic!


Doubling down on "well, hurr, I'm an asshole and that's what I do" is sick.

Act like a decent human being.


oh my god - people will always throw shit - often for no apparent reason at all. In fact - I would take it as a compliment. If you do great things, and shit come your way, it means you're successful. Don't let it get to you. Ignore it.


harthur, if it's any help, I immediately `npm install pg replace`'ed. I love your tool's simplicity, for common scenarios, compared to the more common alternatives. Without all this drama, I wouldn't have come across it!


Just starred your project on github. Thanks for bringing it to my attention.


Chris Dickinson's response to this whole ordeal is very much worth the read: https://gist.github.com/02cbd380b7b3b1df62b5


The truth is that there are a whole bunch of morons out there with petty little opinions and with no real achievements of themselves. They call the people Trolls (with a capital T). Ignore them.


They are still trolls even if they have a twitter following or have made some money.


@Author: Everyone has a right to say and have an opinion. Learn to accept people's reactions and hopefully you will understand why they said what they said. In other words, stop being a pussy!


sucks to be on the receiving end of some nasty/uncivil comments. On the other hand, you are now the person that re-wrote sed. That's pretty awesome.


I'm curious : what is the use case for this utility ? If I look at the README, it says :

> Modifies files when matches are found

Just like sed's -i option (except that -i allows you to specify a backup extension just in case)

> Recursive search on directories with -r

I usually use find with sed, so it's not so much a problem (and it actually allows to filter the files by extension, exclude directories, etc, which is pretty handy)

> Uses JavaScript syntax for regular expressions and replacement strings

I'm not sure that it's an advantage :)

So, is there something that I missed ?


Yeah you missed the point of the article.

It's not about the usefulness of the project, it's about why does notorious developers like steveklabnik (rails core team) and dcramer (lots of django related projects) are publicly bashing this project without any reason.

It's rude and childish.


Wow--I was unaware of the fact that the commenting dudes were devs on actual important projects.

This reminds me of the time James Cameron got on youtube and started posting mocking comments on videos with under 100 views.

Oh, that's right, he never did that. Because it would be ridiculous, and would make him look like a petty bully.


That's pretty clever! I like that one...


And a summary of that attitude: https://twitter.com/steveklabnik/status/293831920872194050

Why would anyone want to work with Steve?


klabnik isn't in rails core: http://rubyonrails.org/core


The tool is simpler than sed because it misses a lot of stuff that sed actually does.

That's what you and the people mocking this project have missed.

Well, there's also the old idea of "if you don't have anything nice to say, don't say it." Or the idea of constructive criticism. Or the idea of contributing useful patches to the project.

So yes, there is something you and the armchair experts missed: software doesn't exist in a vacuum, and the people behind the software might have some emotional investment in their work.

As for the original project author, it bears mentioning that if you can't handle ridicule, don't appear in public. Someone, somewhere, will find a reason to mock you. It might be your choice of language, your formatting style, your_use_of_long_variable_names, UseOfCamelCase, too much/too little abstraction of methods, the colour of your hair, your choice of footwear, too much/too little hair, or that your name isn't common.

Mocking people has never led to things getting better.


I see your point, but I slightly disagree. It could be worthy to kindly say that there is a 'standard' way to do it, since the author may not be aware of find or sed. And if they are, some readers may not.


She mentions sed in the readme. She knows about it, and has informed potential users as well.


"the people behind the software might have some emotional investment in their work."

If you are coding to relieve an unresolved emotional tension that just has no other outlet instead of solving an actual problem, you are in the wrong industry. Go be the first Jackson Pollock programmer.


I disagree, slightly. Mockery is sometimes the only way to make the powerful, oblivious or powerfully oblivious pay attention. I agree that it is not a reasonable tool against someone who isn't hurting anyone.


For example, Alan Cox mocking Fedora. Maybe not that nice, but Fedora is a big boy and can take care of itself. It's not bullying. And there is more at stake than someone else's github repo being unappealing.


Or downvoting. I guess mockery, /and/ downvoting.


$ find ./ -type f -exec sed -i 's/ugly/beautiful/g' {} \;

vs

$ replace 'ugly' 'beautiful' . -r

I can definitely see the value here


One of the approaches has been used by tens of thousands of users over decades and the other by a handful over a few months.

I know which approach I would choose.


I'm sure many people who have had to put up with the atrocity of sed over decades would love this tool... the author obviously knows about sed and found it lacking.

Regardless, though, it's a tool she found useful, even if you personally don't. So what? The appropriate response is "Oh cool, I try to use sed. It has arcane syntax and portability issues, but it's a lowest common denominator that I can expect to find on all the systems I work on."


I don't think a critique of the code in question is especially relevant to the main point of the article, i.e. the practice of mocking open-source projects.

Debating the technical merits of this particular project can't really address that.


Not one she specifically mentioned (or possibly thought of) but it runs on windows without Cygwin.

Edit: using the proper gender pronoun would help.


Yet it appears to require node.js?

Six of one, half a dozen of the other


It is possible to run a version of SED on Windows without Cygwin:

http://www.zeusedit.com/zforum/viewtopic.php?p=2683


I've never configured Node on Windows, but apparently it requires Cygwin [1]

    Currently, you must use cygwin to install node. To do so, follow these steps:
[1] http://howtonode.org/how-to-install-nodejs



*She


find + sed complaints were somewhat anticipated:

http://harthur.wordpress.com/2011/06/06/replace/


Yes, you are missing something. The features of his utility is not the point.


Well, if someone says "So wrong that it doesn’t even need to be explained", I assume that saying some of the reasons which would lead to the bad reviews is relevant.

However, I agree that it doesn't address the second point of the article which was the useless rudeness. But developers are (helas) known to be very rude people. That's not the first article talking about it.


The problem is that being abusive and belittling to others is harmful to the open source community, especially when it revolves around someone who has gone and contributed to the community actual working code.


It's wheel reinvention - same idea, different UI. But that's not always a terrible thing in programming; in fact it describes most of our software.


Also, I think the concept could probably be done with sed and whatever bash scripts.

But the code didn't look that bad. It is Javascript after all.


850+ votes, 480+ comments and counting. Who is going to write that easy to use, 'properly written' shell wrapper around find/sed?



XKCD has the answer. http://xkcd.com/1053/


a girl?

does that make a difference?

(honest question)


Better shit code that gets the job done than beautiful code that gets nothing done


I spent a summer once writing a substandard 'ls' command because I liked doing it.


this is why i am afraid to open source my own personal projects. this fear.


Isn't the whole node.js ecosystem subject to this criticism?


One nit: I'm not seeing an open source license in the repo. This is what would keep me from using or caring about this code snippet or start caring about how the developer was being treated.

Is there one and am I just missing it?


dude, unix is serious.... oh, wait a minute...

Never mind.

"Everybody gets a Trophy!!!!!"


The Unix weenies strike again.


No good deed goes unpunished.


The open source zealots have been like this for years. 5 or 6 years ago, I forked a project and started charging for it. I was completely within my rights to do so as I followed the license (GNU) specifically and also gave out the full source code.

This didn't stop the death threats, taunts, and aggression I got from the general community. This and things like the recent word press theme debacle have put a bad taste in my mouth when it comes to open source.


"Then I sob harder. I can’t help but think of potential future employers that are no longer potential."

As an employer, I expect there to be criticism associated with a person's code. Criticism isn't a black mark.

But sobbing in reaction to criticism? Getting all upset about mild criticism from a-hole strangers on twitter? That's a black mark.


Who else here really doesn't enjoy using sed, awk, grep, and xargs?

I try to use ack whenever I can avoid grep or find, personally. I wish there were better replacements for the other tools and that they were widely available (possibly as portable libraries).


big shots tend to forget they are just humans and make mistakes. like all of us.




Join us for AI Startup School this June 16-17 in San Francisco!

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: