Feed aggregator

Identical Comparison Hint

Starred Items - Tue, 01/24/2012 - 11:18

Hi everybody! Today we would like to introduce you some of our new hints. This one is called Identical Comparisons and checks whether you use more strict identical comparison instead of simple equal comparison. If not it suggests you to change it to identical one.

If you don't know what is the difference between identical and equal comparisons, you can read it in official PHP manual.

And because we know, that sometimes there is a use case when you should use just equal comparison, this hint is row sensitive. It means that well known hint bulb will appear only if you are on the row with comparison. So no yellow warning triangle will scream on you ;) This hint just wants to help you :)

But there is just another advantage of this hint. It can change your "==" sign to "===" as you certainly expected, but it can detect the type of the right hand side variable and make a type cast for you too!

That's all for today and as usual, please test it and if you find something strange, don't hesitate to file a new issue (component php, subcomponent Editor). Thanks.

Ondrej Brejla

2011 by the numbers

Starred Items - Mon, 01/16/2012 - 15:46
2011 was an exciting year in the Eclipse community.  From my corner of the Eclipse universe, he's what it looked like:


One book chapter, many thanks



I contributed a chapter on Eclipse to the Architecture of Open Source Applications in 2010 and the book was published in May 2011.  Thanks to Amy Brown and Greg Wilson, for their long hours editing and providing feedback to the authors of this book.  It's a great read!  When Greg first approached me about writing this chapter, my immediate thought was "How hard could it be? I live and breathe Eclipse all day".  It was much more difficult that I imagined but in the process I learned a tremendous amount and am a better committer for the experience.  Many thanks to DJ Houghton and John Arthorne for reviewing my drafts and providing valuable feedback. A special thanks to Jeff McAffer who I interviewed about the decision to switch to OSGi in 3.0 and Steve Northover for his suggestions to make the SWT section into something more pixel perfect.  Merci Olivier Thomann for answering my many compiler questions,  and Boris Bokowski and Paul Webster for their thorough discussions with me regarding the modelled workbench and dependency injection in 4.x.  Also, thanks to Mike Wilson to allow me the flexibility in my job to spend some time at work working on this chapter.  I'm excited to see that Amy and Greg are now editing a second volume of this book.

Six milestones, many release candidates, two service releases, and one coordinated release, four streams, thousands of builds, millions of tests
No rest for the committers.

143 bug fixes
I closed about 143 bugs in the releng bucket in the past year.  That doesn't seem like much really.  I'd have liked to solve more.  The largest issues implemented from a releng perspective were shared licenses, code coverage, and the largest work item, the Git migration.

42 Git repos 
The Equinox and Eclipse projects migrated all their repos to Git.  We now have about 42 Git repos.  This involved a tremendous amount of work on the part of the Eclipse team as a whole.  There were many whiteboard drawings and detailed discussions about the migration process with John, Paul and a Mr. Gheorghe.  There was no Ringo.  Thank you Paul for all the huge amount of testing, script writing, and migration of all the ui and e4 repos. Thanks John for your work many sage suggestions on our Git migration, as well as your suggestion to implement the git flow method to simplify our development and build processes.  Thanks Andrew Niefer for migrating many of the Equinox and PDE repos, Bogdan Gheorghe for your work with SWT, and Oliver Thomann for testing JDT Core repos.  Thanks Tom Watson for your Git advice, having already climbed the Git learning curve while working on the OSGi Alliance repositories.  To Dani Megert and Markus Keller, your always fine attention to detail and pointing out areas that could be improved is appreciated. Paul is giving a talk about our migration at EclipseCon 2012 called Let's Git this Party Started.  I'm sure it will be insightful and entertaining.

One EclipseCon, two talks, one castle, many great people
I was privileged to attend EclipseCon Europe in Ludwidsberg this past November and present two talks.  I thoroughly enjoyed preparing these talks, and even more presenting them.  On the Wednesday morning, I talked about our Git Migration, and that evening I gave a talk with John Kellerman about history of Eclipse over the past 10 years.  After the second talk, a few people came up to me and said that the talk was so good that it should have been a keynote.  That was very fantastic to hear because we really put a huge amount of effort into that presentation.  I also had a lot of fun talking to people at our booth where we had posted many pictures of the Eclipse family from over the years. The Saturday after the conference Simon Kaegi, Eric Moffatt and I visited Heidelberg castle.  Canada scores very low on the castle index so this was a treat.   


You can't buy Eclipse magazines or giant pretzels at train stations in Canada either. I was impressed.



19 blog posts
I didn't have much time to write blogs posts this year.  The most popular one I wrote this year was about smashing open source stereotypes.




I'm never sure how popular a blog post will when I write them. It's always a surprise.  The comparison of Mozilla and Eclipse build infrastructure I wrote last year still holds the record for most popular (it ended up on reddit).


One marathon, many kilometers of training
How is running related to release engineering?  Running keeps me sane when release engineering gets crazy :-)  Preparing for the Ottawa marathon in May means that you have to start training at the end of January.  Running through snow, ice, wind and rain teaches you there isn't really anything you can't do when you are willing put in a lot of hard work to reach your goal.  And when you reach that goal, there's a lot of joy, because you know that you have conquered all the obstacles in your path and emerged victorious.

My sneakers after a 19K training run through deep slushOpen source is really a huge team effort and I had a lot of fun in the Eclipse community in 2011.

Who knows what 2012 will bring?

Legendary Grumman test pilot Bob Smyth dies at 84

Starred Items - Wed, 01/11/2012 - 11:35

I received word this morning of the passing of legendary Grumman test pilot Robert "Bob" Smyth. Smyth, 84, was responsible for an extraordinary contribution to civil and military aeronautics and astronautics.
After leaving the US Navy as a pilot in the Grumman F8F Bearcat, Vought F4U Corsair and McDonnell F2H Banshee and de Havilland 112 Venom, Smyth joined Grumman Aircraft Engineering in 1955. Smyth served as assistant project pilot of the Gulfstream I, consulting pilot and astronaut liaison to NASA on the Lunar Excursion Module during the Apollo program.
Smyth was at the controls for the first flights of the Grumman A2F (later the A-6A Intruder) and captured the experience in 2001, writing:Now, the real purpose of a first flight is to make a successful landing. There is a tremendous level of interest at this point. Hundreds of people have worked long hours for months to reach this point; a large part of the company's future is tied to the airplane's success; and the customer is anxious to see what he's buying. All this creates a great deal of pressure on all concerned. One person has it within his power to bring instant relief to all hands: the lucky guy who gets to make the first flight.His career spanned an extraordinary variety of aircraft, being the first to fly the Gullfstream II and as chief Grumman test pilot, flew the F-14A for the first time in 1970. Smyth left Grumman and joined Gulfstream Aerospace in 1981 and retired as vice president of flight operations in 1993.
Smyth spoke to the Smithsonian's National Air and Space Museum in 2007, discussing his incredible career and his indelible contribution to aerospace in the video above.
Smyth passed away yesterday at his home in Florida and is survived by his wife, Sally, and two sons, Robert and Andy.

Building Social Software for the Anti-Social

Starred Items - Mon, 12/19/2011 - 07:31

In November, I delivered the keynote presentation at Øredev 2011. It was the second and probably final presentation in the series I call Building Social Software for the Anti-Social.

I've spent almost four years thinking about the Q&A format, and these two presentations are the culmination of that line of thought. In them I present ten "scary ideas", ideas which are counterintuitive for most folks. These are the building blocks we used to construct Stack Overflow, and by extension, Server Fault, Super User, and the rest of the Stack Exchange network.

  1. Radically lower the bar for participation.
  2. Trusting (some of) your users.
  3. Life is the world’s biggest MMORPG.
  4. Bad stuff happens.
  5. Love trumps money.
  6. Rules can be fun and social.
  7. All modern website design is game design.
  8. Thoughtful game design creates sustainable communities.
  9. The community isn’t always right.
  10. Some moderation required.

It's not the same experience as attending the actual live presentation, of course, but you can certainly get the gist of it by viewing the slides for these two presentations online:

The Øredev organizers hired ImageThink to draw each presentation on a whiteboard live on stage as it was presented. I was skeptical that this would work, but the whiteboard visualizations came out great for all the presentations. Here's the two whiteboard drawings ImageThink created during my presentation. (Yes, they had two artists on stage "live whiteboarding", one on the left side, and one on the right side.)


It's not a bad approximation of what was covered. If you're curious about live whiteboard visualizations, ImageThink posted a great set of links on their blog that I highly recommend.

After four years, we've mostly figured out what works and what doesn't work for our particular brand of low noise, high signal Q&A at Stack Exchange. But the title Social Software for the Anti-Social is only partially tongue in cheek. If you want to learn anything online, you have to design your software to refocus and redirect people's natural social group impulses, and that's what these presentations attempt to explain. I hope you enjoy them!

Update: Part II is now available as a full talk, with audio and video courtesy of GitHub. Watch it now!

[advertisement] What's your next career move? Stack Overflow Careers has the best job listings from great companies, whether you're looking for opportunities at a startup or Fortune 500. You can search our job listings or create a profile and let employers find you.

(author unknown)

Gifts for Geeks, 2011 Edition

Starred Items - Tue, 12/13/2011 - 04:12

Between founding Stack Overflow (and later, running Stack Exchange) and having a child, I haven't had much time to blog about the holidays for a few years now. The last Gifts for Geeks I did was in 2008. Those recommendations are still as valid as ever, but I just couldn't muster the enthusiasm to do it every year.

I've also come to realize, especially after having a child, that the goal in life is not to own a lot of "stuff", but rather, to free yourself from everything except that which is essential, and that which you love.

I'm still working on this, and I probably will be until I die. That said, there are a few essential things I think any self respecting geek should have, things I use all the time and I truly love – and I feel it's my responsibility to let my fellow geeks, and the spouses and significant others of geeks, know about them. Otherwise you might end up with yet another WiFi Detecting Shirt as a gift this year, and that'd just be … sad, for everyone involved. So consider this a public service, and feel free to share this post, lest you show up to work in January and find yourself and all your coworkers wearing Wifi Detecting Shirts.

As I wrote in What's On Your Utility Belt? I've been carrying LED flashlights since 2005, and just in that time the average LED flashlight has gone from bright, to very bright, to amazingly bright, to ridiculously blinding laser-like bright. You can thank Haitz's Law for that:

[Haitz's Law] states that every decade, the cost per lumen (unit of useful light emitted) falls by a factor of 10, the amount of light generated per LED package increases by a factor of 20, for a given wavelength (color) of light. It is considered the LED counterpart to Moore's law, which states that the number of transistors in a given integrated circuit doubles every 18 to 24 months. Both laws rely on the process optimization of the production of semiconductor devices.

Or, as I like to call it, "why you will be regularly blinded by flashlights for the rest of your natural life." But on the plus side, it also means that today even inexpensive LED flashlights are plenty bright for all but the most niche applications. You no longer have to pay a big premium to get one that's usefully bright. LED lights are so awesome, in fact, that I own and recommend no less than three form factors:

  1. Fenix HL21 ($35)

    If you do any kind of DIY work at all, at some point you're going to want a focused light exactly where you are looking. If you can get over the "hey, I have this lamp strapped to my head and I look like a dork" factor, headlamps are ridiculously convenient. I had a much less bright (~40 lumens) headlamp and switching to this 90 lumen HL21 was a major improvement. I use this thing all the time. Looking cool is overrated.

  2. Fenix E21 ($35)

    The E21 is much smaller than your typical full-size flashlight but it is every bit as bright as those giant police-baton like Maglites. It runs off two ubiquitous AA batteries, and has a pleasingly simple design, with an obvious switch in the rear and only two configurable light levels: low (48 lumens) and high (150 lumens). This is a flashlight you could buy your parents without baffling them. We own three, and each of our cars has one in the glove box. This is, in my opinion, what LED lights were meant to be.

  3. Fenix LD01R4 ($40)

    The latest revision of the LD01 is the proverbial Every Day Carry; a compact single AAA flashlight. As long as you have your keys with you, you'll never without a reliable, bright enough light. Twist the cap to balance between runtime and light output; the three modes are 85 lumens for 1 hour, 28 lumens for 3.5 hours, and 9 lumens for 11 hours. Pretty incredible from a single AAA battery! Oh, and I recommend a lithium AAA battery because they run longer and are 1/3 lighter than other types of batteries. Normally I wouldn't care, but the reduced weight is surprisingly noticeable in something you'll have in your pocket all the time.

All these LED lights have one thing in common: batteries. It's unavoidable. Because you're a responsible geek, of course you use modern rechargeable battery technology. And as I wrote in Adventures in Rechargeable Batteries, sophisticated battery chargers are like geek catnip.

This is the LaCrosse BC1000 ($60), and it's a ton of fun to mess around with. Also, it recharges batteries. It might seem a little spendy, but it can do miraculous things like bring old nearly-dead rechargeable batteries back to life. And it comes with a bunch of actually useful accessories in the box:

  • Nylon carrying bag
  • 4 AA and 4 AAA rechargeable NiMH batteries
  • 4 C size battery adapters
  • 4 D size battery adapters

Yep, you can simulate C and D cells by putting the AA and AAA batteries inside the shells. The only battery type not represented here is the 9 volt. I own two of these LaCrosse chargers, and given the stupid number of AA and AAA powered devices in the house I'm thinking of buying a third. If you're a geek, you almost certainly have 99 battery problems, but armed with this baby, recharging ain't one. And don't forget the low self-discharge NiMH batteries, while you're at it.

Ah, the dremel. I think this Canadian forumgoer expressed it best:

It truly is hard for me to express the joy I feel when I am forced to break out the dremel; the last resort, the "Trojan Horse" of tools. In a dark place when all other tools abandon me and leave me heartbroken, the dremel always provides a loving shoulder to help complete my tasks. The dremel is a very selfless tool, he/she has no purpose to which they cling, yet is always willing to assist its fellow tools in completing theirs...

Drill strip a screw? The dremel can help... The jigsaw leave some nasty edges? dremel can restore them. I like to think of the dremel as the Jesus of tools.

They say Jesus performed many miracles and although it's not thoroughly documented, I believe his first miracle was, in fact, the dremel blueprint (he was a carpenter after all). The good Lord presented me with an image in a dream... I would like to share it.

If you don't own a dremel, I'm sorry, but I'm going to have to ask you to turn in your geek card. The dremel is truly the swiss army knife of DIY projects. Any DIY project.

I use my Dremel about once every few months, mostly for things that I probably shouldn't even be attempting. But that's the beauty of the Dremel. It doesn't judge; it just helps you get s**t done, by any means necessary. I don't recommend buying a big Dremel kit to start, because it's hard to tell which accessories you'll actually want or need until you begin using this insanely versatile tool. I suggest starting with the entry-level high power Dremel kit ($90).

Finally, I have to put in a mention for an updated version of what is probably the most frequently used thing on my keychain, with the biggest bang for the gram other than my front door key -- the Leatherman Squirt PS4 ($24).

That's right, you no longer have to face the terrible existential conundrum of choosing between pliers or scissors. The new PS4 model now includes both pliers and scissors. This is nothing less than a Christmas miracle, people! (Oh yeah, and get this awesome tiny carabiner to attach it to your keychain so you can easily detach it when you need to bust it out.)

So that's it this year. Nothing extravagant. Nothing too expensive. No frills. Just essential stuff I love and use regularly. I hope you, or someone you love, will love them too.

[advertisement] What's your next career move? Stack Overflow Careers has the best job listings from great companies, whether you're looking for opportunities at a startup or Fortune 500. You can search our job listings or create a profile and let employers find you.

(author unknown)

The Gingrich-Huntsman 'Debate'

Starred Items - Mon, 12/12/2011 - 23:52
I put "debate" in quotes because this was more like a well-mannered talk show with two guests. Archived video on this site. Here's the significant point:

This was the first GOP debate of the four million we've had so far where the real winner was not Barack Obama. All the preceding debates have highlighted the very elements the Republican party would not like to bring into the general-election campaign: Fractiousness among the candidates; extreme, half-baked ("9-9-9"), or under-informed positions from many of them; sound-bite sloganeering from all of them; and barely any time to make a concerted case against Obama apart from saying that he's awful.

This time there were two informed-sounding adults talking in complete thought-sequences -- even to the point of dullness, which is not bad compared to the preceding craziness. And they offered thoughts that they simply could not have developed, or that would have been batted away with slogans, in the "normal" crowded-house debate with its 30- or 60-second segments. For instance, both of them explained why the defense budget really had to go down. Or the realities of what can be expected with Pakistan and Afghanistan. The ways in which China is both rival and partner, etc. Because they both knew they'd be able to make their points, there wasn't the desperation for air time that had made performers in all the other debates act as if they have to blurt out their attack-lines and applause-points whenever they have a chance.

I didn't agree with a lot of what I heard. Among other things: in this and the previous Republican debate, all the candidates have essentially said they would franchise out decision-making in the Middle East to the government of Israel, in a way that would seem bizarre if we were talking about delegating decisions to the UK or France in Europe, or to Japan or South Korea in East Asia. Still, this was the only debate that was overall a win for the Republicans.

On Newt Gingrich: Stephen Budiansky has a very penetrating assessment of why Gingrich sounds the way he does. To summarize, he talks the way people who know nothing about academics or intellectuals think academics and intellectuals would talk. Or, as Andrew Sullivan put it more bluntly, he sounds like "A Dumb Person's Idea of a Smart Person." When reading that item I couldn't help thinking about the Martin-Aykroyd "Wild and Crazy Guys" routines on SNL, showing what Eastern Europeans of the Communist era thought that hep-cats from the U.S. would sound like.



Congrats to Huntsman, Gingrich, the St. Anselm's organizers, and the Republican party on this event.


TIP: Stable history navigation using Eclipse toolbar

Starred Items - Sat, 12/10/2011 - 14:26
Eclipse has a nice location history navigation toolbar. By repeatedly clicking on the history toolbar buttons you can quickly navigate to the locations the cursor/focus was at in various editors that are open. Unfortunately, out of the box, the position of the history navigation toolbar buttons is not stable if you have files of varying types open in the editor area. That is because the toolbar contributed by various editors are shown and hidden as the focused editor changes. These editor contributed toolbars (shown in blue rectangle below), when shown, are inserted to the left of history navigation toolbar. The following two screenshots demonstrates the behavior.


Fortunately there is a way to fix this behavior. It is possible to to drag the editor toolbar to the right-most side of the toolbar strip like shown in the following screenshot:


With this adjustment the history navigation toolbar remains in same place making it easier to use.
You may have to unlock the toolbars to see the drag handles as shown in the screenshot below:

I think this should be the default location of editor toolbars in Eclipse. Just filed this enhancement.
Such small adjustments makes the tool more productive.

A Fascinating Chinese View of the Occupy Movement

Starred Items - Fri, 12/09/2011 - 00:42
(See update below.) For an essay that says interesting things about America, and even more interesting ones about China, please check out a new dispatch at China Geeks. It is a translation, by Alec Ash, of a Chinese essay by Wu Yun called "Let's 'Occupy Chang'An Avenue.' " To get the joke you mainly need to know that Chang'An -- "Eternal Peace" -- Avenue runs between Tiananmen Square and the Forbidden City in Beijing, so it is shorthand for the Chinese locus of combined political/financial power.

More later on the background of the essay. A few highlights: Initially much of the Chinese media portrayed the Occupy movement as yet another sign of America's decadence and imminent collapse. The author disagrees:
Democracy clearly has its flaws, but OWS shows not the defects of democracy but its advantages. That protestors do not "go missing" [as they have this year in China] is thanks to the benefits of democracy, and the lack of violent conflict or loss of social order is an example of its accomplishments. The US government has not condemned nor suppressed, but rather sympathised* with the movement, nor have the crowds challenged the legitimacy of the government or the democratic system itself. Rather, OWS is happening precisely within that democratic framework.

In other words: we must change our perspective and see this demonstration as a rational expression of democracy, and the normal activity of a healthy society rather than the upheaval of it....
The essay even has an unexpected answer to the standard left critique that Obama economic policy went too soft on the bankers:
After the subprime mortgage crisis, the US government had no choice but to bail out the banks - if they hadn't, the consequences would have been even more disastrous. Some say the bailout was in collusion with financial oligarchs, but we have no cause for complacency because the Chinese economic stimulus cost us just as dear. The difference is: how much money we paid out and where and how it was used was not approved by Congress, let alone made accountable to the Chinese taxpayer. 
And, the world round, essays about foreign events are often platforms for talking about one's home country. Sure enough:
Just because China has no demonstrations like this, it doesn't mean it has no problems...

On Wall Street, angry young men protest the market monopoly of a few capitalist bigwigs, condemning these oligarchical as predators of the economy. Unfortunately, China's oligarchical establishment far outdoes America's. The state-owned enterprises that monopolise the Chinese market are for the most part controlled by so-called "princelings" and their relatives. Publicly-owned enterprises nominally belong to the people but in reality, besides raising consumer prices as they like, they have no connection with the people whatsoever....

Financial supervision may be weak in America, but at least the public can protest and Obama can do something about it. In China, the bad debts of banks and levels of corruption among regulators and executives are so dreadful that we daren't make them public. The inequality gap may be large in America but it pales in comparison to China's. [JF: Surprising to most people outside China, but true. As is the next sentence.] America may have scant social security but China has virtually no social security at all.
A view in China and America of protest as a sign of social health would be encouraging about both countries and about their ability to deal with each other. For the opposite view by Chinese officialdom, as I saw it earlier this year in Beijing, see this article. But check out this new one.
__
* Update: A Chinese reader wrote to correct to an earlier version of this translated sentence. Previously it said "has not condemned, suppressed, nor sympathised with the movement."



Podcast – Iran and that “RQ-170″

Starred Items - Thu, 12/08/2011 - 16:23

We focus on commercial programs, but occasionally a non-commercial aerospace story comes along  that is fascinating. The video from Iran appears to show a US made UAV that its says it captured. Indeed the language they used is that an Iranian military “electronic warfare unit” brought down the aircraft on December 4. What NATO has admitted is that it lost a UAV, but they have not admitted what type of UAV.

While looking at the Iranian TV footage, we have a short conversation with G2Solution’s Research Director and UAV expert Ron Streans. The conversation by definition is speculative, but it is educated speculation. Have the Iranian’s managed to crack the US’ UAV control systems? Is this really what it seems? If it is what the Iranians say, then we are dealing with a serious situation.

Play the podcast.

Syndicate content