Thursday, June 11, 2009

Now what ?

Well. Now I am on a 3 week weekend, a vacation if you like.

The big question is, did I take my MacBook Pro or my trusty Acer with me ?

Well I was tempted to take both. But the extra weight and then have one of the computers just sitting around collecting dust is not my thing. I picked the Mac. It was actually a simple decision. It is the computer I trust. I don't trust Windows. It can break anytime. I could get a virus anytime, and finally because Windows 7 is just Windows. But for the first time in 25 years it actually works. Doesn't say it is better than Mac OS X, just that Windows 7 is the best Windows ever.

I knew what I needed for the vacation. MySQL, PHP, CakePHP, mail and a good browser. I have everything of this on the Windows machine. I bought e-texteditor and all.

But it all comes down to DOS. I hate c:\Program Files and these kind of paths. I hate it. I don't like to have c and d and e drives. I can get cmd to work and behave, but it is no Terminal.app. I really like working in Bash shell, CTRL-A and CTRL-E and all these shortcuts actually make everything work better and nicer. Being able to split the screen and use 'screen' among other things is just the difference.

Many people think that since I am a "mac person" I always like the Mac and such. But that is not the case. I never liked the old System 9 and older. The machines crashed a lot, didn't multitask, did not have terminal. I have always liked NeXTSTEP ever since I first saw it and worked on it. I just wished I knew more back then.

I really like my Mac, Textmate, coda and all my other apps. Now I look forward to a clean Intel future with my Mac. But I will now be able to use Windows 7 machines without getting really mad and annoyed. I could work on a PC for a long periods of time if I needed to but nothing comes close to my Mac(s).

Thursday, June 4, 2009

Windows 7

Ok, as everyone knows ever since 2003 I have been using a Mac, and Linux before that and barely used Windows since 2000. I am doing all my work on a Mac and liking it. I hate working on XP and dislike it quite much to work on Vista. But since I have a quad core machine that runs Windows I use it to play games and do some heavy crunching. I like this computer.

I listen to Leo Laporte and his This Week In Tech and Mac Break Weekly. There he has been saying all these nice things about Windows 7. I mean, why ? It is still Windows, right ? One thing more than anything else that did catch me, was that he said it was snappy on these small crappy netbooks, and it just so happens that I have an old Dell D600 that I use as an e-book reader. This machine has P4 Mobile 1.7 GHz cpu and 2 GB memory. So I copy all my pdf books to the machine and use it to read on.

This machine worked quite ok with Ubuntu 8.04 but once I upgraded to ubuntu 9 it failed miserably. Becamse slow and buggy and later refused to boot. So I went to www.microsoft.com/windows7 and got myself a copy, I mean what is the harm since I had to re-install the machine anyway.

Remarkably the machine came back to life, and works great. I had to do go to Dell and get two drivers, 1 for the wifi card and one for the touchpad. It does go to 100% cpu load quite frequently, but given the limited usage I have for it it is ok. So then I took out my Acer Travelmate 8210, a Dual Core 2 cpu with 2 GB memory and large disk and re-installed it with Windows 7, clean.

Wow. This machine ran Vista and ran it well, but this is amazing. Windows 7 actually changes your working habits and streamlines your work to the point that it is actually a pleasure to use, I mean it, not joking. So I decided to take a journey and decide how useful it actually was. Was this just first time crush which fades away ? How actually is windows 7 usable for a Mac(aholic) for a stretch of time, doing actual work. Well in short, I am ashamed of saying, but I almost don't miss my Mac. If my Mac died right now, I am not sure I would buy a new one. I mean, I can get a quad core laptop and the new penryn i7 laptop, running windows 7 for quite a good price. I always liked using Mac OS X and never bought the machines just because they looked pretty.

So this is what I did, quite a longer story.

I installed xampp, Apache, php, perl and mysql for Windows. Installed openssh for Windows (not cygwin). Changed the font in 'cmd' to Consolas 9 points. Installed vim and fossil source code management. Went out and bought e-texteditor changed the default font to Consolas. E-texteditor is almost a clone of Textmate on the Mac. Another Danish guy who makes it, who is actually a friend of the Textmate author. Wonderful editor (both).

Then I installed Cakephp on the machine inside the xampp. Changed some of the default paths on the system (Environmental variables), so I can run mysql, cake, php, perl, fossil and vi straight from 'cmd'.

I then created from scratch, a to do list manager, full crud (edit, delete, create and all that) for the list. Had different views, MySQL and all. I made sure to set e-texteditor to UTF-8 (unicode) and use unix linefeeds (only \n and not \r\n).

The only minus to the whole experience is with the location of the <> button. It is on the right, and on European keyboards it is always next to the left shift, before Z. Nope, not on the Acer. Well i just swallowed and learnt to use it, not to like it though.

But the end result amazed me. I actually liked the experience. I liked developing on Windows. Now what is happening to me ? I have actually quit working for companies because they made me use Windows, and that was the big reason, and I am not joking.

Now what is it actually that I like so much about Windows 7. Well can't really say. The new Aero look and task bar is awesome. There is nothing in your face, there has in a week never been a dialog or yellow bubble saying something to me. I just can work totally focused on the machine and for example if someone starts talking to me on MSN, it just blinks a small icon on the left hand side on the screen, barely visible unless you actually look there. When I download a file, the download progress is displayed on the small browser icon and then fades away. Nothing to bother you.

When I want to do something. I just press the Windows button, type in 'cmd' and I am in command line. If I have to do anything else I just press the windows button and type in what I want. Want to change environmental variables, just type enviro and it pops up. Want to set the sound, well just type in sound. The search is really good. The new control panel does not have a Classic view, finally. I like the new look especially since the search works great.

I think I will have myself locked up now, the men in the white clothes are coming. Seeja...

Friday, March 20, 2009

Star Wars

Not until after reading the blog of CAMBLR did I figure out why I hated the new Star Wars movies but liked about the old one's.

Remember, the new movies happen BEFORE the old ones. They are about Luke and Leia's parents. They are about Darth Wader as a teenager. I always thought it was because they have so much more and better technology in the past than they did in the future. But that was not it.

What really impressed me about the old one, was just how real it was. Everything is as close to normal as you can have it with flying space ships and robots. Everything looks used. Yup, you read me right. Nothing in the old Star Wars movies is never used before brand new. The space ships don't look like mirrors with impeccable paint job. The bar, the fortress, the millenium falcon all look dirty. There is even dust in the air, when the light shows through a window at Lukes home and in the bar in Mos Eisley is dusty and dirty. The roads are not paved, and everything looks like it has been there for years and years.

Counter that with the city where the replic is run from and the the jedi house. Everything is spotless and shining. The office of Palpatine and others are impeccable.

I know these are the big cities, New York vs Timbuktu, but New York is not spotless.

And I always thought I detested the new movies because of Yar Yar Binks, how silly of me :) Although George Lucas should really have released a version 1.5 of the first movie with Yar Yar deleted out. This character does nothing for the movies and is only really really boring and the scene where his accidentally wins a battle with the robots in the first one, should not have been in the movie at all. And Hayden Christiansen should not be allowed to call him self an actor

Wednesday, March 11, 2009

Fossil version control system

For the last few years I have been using subversion. I can't say that I have been much of a power user as I have never actually branched a live project or done tags. All I have been doing is working in the trunk. Well these are strange words, tags, branches and trunk. Working in the trunk is that I work on live code and if I mess up I need to go back to my last commit change. This can be all of a few minutes or if I have been working with no internet (what ? how is that possible? ) I might loose more than a days worth of work. This is because subversion is a remote system, so if you need to checkin code you need to have a network relationship with your subversion server.

Also in subversion, branching is very expensive. How expensive ? 100 % more expensive. It makes a full copy of your code repository for every single branch you make. What are branches you might ask ? Well to put it simply, branching is where you have a full source and you might want to test out a new grid object in your project instead of your current grid. If you don't branch, you just go ahead and change your code all over the place and once you are done you might do a checkin if you like the result. If you don't like the result you just revert your code to the earlier checkin. Quite simple and this is why you have to use version control system. This is how I used to work. What keeps happening is that for the release version, people might report a bug, and bugs get top priority over everything else. So all my changes are either copied out of the repository or just deleted and I check out the earlier version, fix the bug and release a new version. Then I copy the development files back into the tree or start from scratch. WAIT A SEC HERE. Did I not just waste a few hours of changing the grids and have to start again ? Or what is even worse, I might have overwritten my bug fix with my testing. Now I have to remember to fix the bug as well.

Well this is just like playing chess. I need to keep a lot of info in my head, while speaking to my wife or kids or answering e-mail while typing away on my gtalk or msn account. I will admit it. I make mistakes. I have released a version with a bug I had fixed earlier. But never again.

Let me explain branches in short. What would be a much better way of working is this. I checkout the code, and when I want to try to change grids in my application I create a branch called "changing_grids". Then do my work there. Now if I get a bug report, I just commit my changes on the branch, checkout (change to) the master branch, fix the bug. Now you might think I just checkout my "changing_grids" branch, and you would be half right. What I might do before is to merge the master branch into "changing_grids" first, so my bug fixes go into my testing, and then I checkout my branch. This way, no time is lost, and I have full story of everything. And the best is, if I actually succeed in changing my grid to something else, and I like the result, I can merge the "changing_grid" into the master, compile and release. Now this is what I call work flow.

The above scenario is quite possible with subversion, but you can not do this while being offline, and you have to merge quite a lot of files, all this really takes some time, and wastes disk space.

I have been looking at GIT, git means idiot in the queens english and Linus Torvalds says it is named after him self. Pretty funny. I must admit that I really gained huge admiration on Linus for writing git in just 3-4 days and going live with it on the Linux Kernel. Thats just cool.

Git works offline, meaning I can do what ever I feel like with my code repository. I can branch, delete and change everything as often I like, and I can commit every single change I do and once I am online I can push all my changes to my central server. Best of all, GIT is cheap, I mean if I change 1 class in my project, the repository only increases by how much I changed. Creating branches only takes a fraction of a second, merging branches is really really fast, and everything is happening on my local computer so it is even faster.

What is the downside then ? Well, git is more complicated than subversion, a whole lot more. But if you just stick to the basics you will be much happier and doing branches and tags as if there was no tomorrow. Once you start doing branches your workflow changes dramatically, and there is no turning back.

Now as I am "growing up" as a software developer, I am finding out that I started doing things wrong in the beginning. I made the whole development directory structure a single subversion repository. This is the right way of doing things back then. But I am finding out that I should be doing one repository on each project, and one for icons and pictures and so forth. But setting up a subversion server is hard, and time consuming.

By using git or other distributed version controls, it is so easy to do new "servers" as I am not doing any webdav magic or any other configurations and restarting services. By using git I only need ssh to communicate with a central repository (note as I don't call it a server).

Now I can work 100% locally and only push changes centrally as I see fit, mostly for backup purposes and to keep my 2 development machines in sync.

But what about the title there ? Fossil version control ?

In walks Dr. Richard Hipp, creator of SQLite. He creates many projects and needed his own repository system and did not find it so he just created his own, just like Linus. But unlike Linus, Dr. Hipp he is not maintaing the Linux Kernel, with probably hundreds of millions of lines of code and tens of thousands active users. Gits biggest problem is that it is made for big projects, and even though it works great for smaller ones it shows its rather complex features rather quickly. Most messages are not helpful, and most commands are complex, and installing Git is rather complex and prone to fail, even on Linux. As I don't use Windows at all (well as much as I can) then that git really doesn't work on windows is not a failure in my books, but having over 130 git commands and only using less than 10 is weird, and fossil is just 1 binary file (one, that is it). There is no gui frontend to speak of. The repository is stored as a SQLite database. SQLite is really fast database and unless by act of god you can not corrupt the database as it is totally ACID compliant and never writes data to the database unless it is verified that it is written.

Fossil, the name is just wrong as it makes it almost impossible to find on google, has everything that Git has. It works locally, offline. Branching is cheap, merging is simple, administrating it is simple. But there is more. Fossil has built in Trac system, wiki and user accesses.

The Trac system is where you keep bugs reported, and history of the source. The wiki system could be like a manual system, where everything is explained and user access with password authentication will control if other users besides yourself can checkout code, edit the wiki, create and edit tickets in the trac system and more. These features are not in git, or any other version control system I am aware of. Fossil is really fast system, secure and easy to work with.

Give it a try, it is free, and if you go to the website that hosts the whole project, you might notice that Dr. Hipp eats his own dog food. The whole web site actually is a fossil site. Did I forget to mention that fossil has a built in web server, where you have access to tickets, wiki and other tools ? Well it does. So now I will create many many projects using fossil.

To download Fossil just go here : http://www.fossil-scm.org/index.html/doc/tip/www/index.wiki

There you will find more information, and keep in mind that site is a fossil repository

Monday, November 10, 2008

What makes the iPhone such a success ?

I can't say I know the whole story, but here are some things as to why the iPhone is now bigger than Sony Ericsson.

First and foremost simple menus. If I want to change the ring tone on the iPhone I do this :

Settings -> Sounds and click on ring tone. How simple is this ? Everything regarding sounds, alerts, incoming e-mail and everything else is there, two clicks.

Everything is this easy. The iPhone does not try to put an equal sign between e-mail and sms, since they are not the same. Two different applications handling each one, and the sms application is an excellent sms app, and the mail application is a fully blown e-mail client. Why does Nokia think this is the same thing ? Trying to squeeze e-mail into a sub folder in sms ?

One other reason. Quite a big reason. Apple makes 2 gadgets. The iPod Touch and the iPhone. Lets leave the original iPod out of this. If Nokia or Sony Ericsson tried to market a symbian music player how would they do it ? They would take an existing phone and rip out the camera, rip out the phone and network and call it a day, well they do just that. Sony Ericsson actually makes a Walkman that is exactly like their telephone, shares a name and is located in the same shops next to their phones. I am sure there are people who bought it and thought it was a phone. Worst part of this is, their music player is not a good one.

Apple takes a different approach. The iPod touch and iPhone are NOT the same. They don't even share the same look, the same screen, the same hardware and they have different motherboards and they actually look different. The iPod Touch had better screen than the iPhone 2G, the iPhone had adjustable volume keys on the side. The iPod had a normal jack system to plug headphones and the iPhone did not. iPhone 3G is closer to the touch now.

They shared two things. The operating system and they shared the iPod application. Yes the iPod is just an application on the iPhone and iPod touch. This is a real computer running a real operating system called NeXTSTEP, ehh, sorry Open Step, ehh sorry, OS X. This is truly remarkable. Why isn't Apple saving a fortune on design cost by using the same hardware for the iPod touch and iPhone ? Because they are different, it is that simple. Totally two different marketing. One is for people who want a small portable music player that can do games and stuff, the other one is a phone that actually can do music. I own both. I both own an iPod touch and iPhone. I never wanted to buy the iPhone until I had tried every other phone out there, so now my great iPod touch is on my gadget shelf, sleeping it seems.

The iPhone and the iPod touch are truly remarkable gadgets. They seem to share quite a bit, but all they do share are some "bits", some software. This does cost somewhat more to make in the beginning, but the results are just that much better.

p.s. Buying the iPhone is surprisingly easy. You just buy it with the cheapest subscription. Then you call the operator and cancel the deal, pay some termination fee and restore the phone on iTunes. Now you can use any card you want, and this is trouble free, no jailbreak, no hacking, no measure that is deemed to stop working after a while.

GSM Phone update

Well, I did give the E71 two whole weeks in use as my only phone, I almost got used to the kinks in the phone. Hardware wise the phone is quite good, but the trouble starts as soon as you turn it on. It takes a long time to send an sms, and a phone with a full keyboard should be quicker. It really takes a real long time sending e-mail, why ? This is a multitasking phone, meaning it can run tasks in the background. I don't care how long it actually takes to send an sms/email, but I don't want to wait almost 1 minute before I can put my phone back in my pocket.

Lets not forget that the E71 phone is quite powerful computer, it is 390 MHz computer, doesn't sound like much does it ? Go back 5 years, people still had their Pentium II running at 333-450 MHz, but they had like 4-16 MB of memory and 2-4 GB hard disk, running WIndows 95/98/2000, using Microsoft Office and outlook and everything else, this phone has almost 200 MB memory and much more space to store things. It is not running a full version of Windows 95/98, it is running a really tiny operating system called Symbian.

The E71 and N95 and N73, don't kid your self thinking otherwise, this is the exact same phone with a different look. If you don't like one Symbian (S60) Nokia phone, you are not going to like the other one. Nokia makes hundreds of different looking phones with different quality camera, but thats it, they are all the same.

In the end of the year 2008, why is it hard to make a better phone than we used to have in 2002 ? In 6 years Nokia has gone from making bad phones to even worse. How hard is it to make a decent phone ? You have the iPhone out now for almost 2 years, how hard is it to use that one as a goal ? Quite hard if you are Nokia, only reason Nokia is still selling quite a lot is because their phones are literally free. They come with a contract and don't cost much, practically free.

The solution for Nokia is not spending more good money to fix something that they haven't been able to do in many years.

Instead of making a gazillion different looking types of phones that are all identical, try this out. There are quite a few really good operating systems out there that actually work on the ARM processor with no troubles. ARM is in Playstation Portable (PSP), it is in Nintendo Gameboy, it was(is) used in a british workstation manufacturer called Acorn. They made computers called Archimedes (ARC) and RiscPC. These computers were able to do incredible stuff, even today. They were fully multitasking in 1987, they boot from ROM, they already have quite a lot of software, games, network and books. This is up for grabs now. Pretty cheap actually.

You also have the Amiga OS, and ATARI ST tos. Both have endless amount of games, good software and tried and tested operating system. Both can easily run on ARM cpu.

All these 3 operating systems only use a few hundred kilobytes for them selves, they are all incredibly fast. All of them can multitask (Amiga since 1985). All of them have hundreds of people who know how to program for it. The all have compilers for any language you want.

SMS, the actual phone it self, contacts, e-mail and every other function on a phone is just an application. Why not use one of these operating systems ? I can not think of any. Only thing is that some "fat cat" is sitting high up at Nokia / Sony-Ericsson and trying to fight out a company battle and staying with Symbian. Symbian was an ok system in 1990, let it die, please !!!

In the beginning I said I almost got used to the phone, but it was just so bad I don't have words to describe it. I gave up. After testing every other phone out there I gave up. I bought myself a 16GB iPhone. Now this is a great phone, and it just does everything I want it to do, and does a great job. Sure it can't send mms and contacts as sms. I don't do this that often, and it did not always work in the past, so these features I don't miss, and Apple is going to fix this, I know they will.

Friday, October 10, 2008

Nokia E71

I have now owned my Sony Ericsson W880i for close to 18 months, that is a record, don't think I have ever had a phone last more than 1 year before I throw it out. The SE W800i (SE from now on) is different. One of the main reasons why I have kept that for so long is that I have not seen any better phone yet.

My phones need to take a lot of beating. I send a lot of sms every day, I look at my e-mail and go to certain web sites like to find the next bus home and gmail. My SE has done me quite well, and frankly is quite good. I just had started to panic, was I getting so old that I was getting complaisant ? Was I the old guy talking about vinyl records sounding better (who cares, the music matters). Was I the one still talking about how the games on the Commodore 64 totally beat todays games ? As for the games, they were great, but they don't age well.

Nope. There is just no phone that is clearly better than the old W880i. Sure there are higher prices phones from SE with better camera, but since I own a fantastic camera (12 MP) I only need it to take good instant photos and the W880i does so quite well.

Then you might ask, why switch ? if I find a better answer than "just because" or "duh, I needed to because of ... will get back to you on that", I will let you know.

Last year I got my hands on Nokia N73, I detest that phone. Any N73 phone that is not being recycled into jewelry right now should be. Every 3-4 weeks I get a Nokia N95 phone as a 24/7 on call phone. Good screen on that phone, but that is it. Louse keyboard, awful refresh rate, and even I could design better looking icons. The guy who designed the menus is a drunk, an alcoholic crack smoking idiot who should be designing cross word puzzles or any board games, not phones. I need to go at least 3 levels down to change my ring tone, if I can ever find that option again (still wondering why almost everyone with a Nokia phone has the same ring tone?, those that did change it only did it once and they also have the same ringtone).

Both Nokia and SE make these music phones, they are to be these really swell awesome players, still not as good as a 5 year old ipod. Just to name one thing, why is it difficult to know where you were last time when you listen to audiobook or podcast ? These things are hours and hours long, I don't want to know where I was last time, if I did that I could just as well read the book and not listen to it. Just this one feature is making me look like an idiot.

Why ? When I listen to music/podcast/audiobook on my iphone, I can't hear my phone. So I am the complete moron half a sleep on my twice a day hour long bus ride with earphones on and NOT ANSWERING his phone, making it ring out two or three times.

I would get an iPhone in a heart beat if Steve Jobs would want to sell it to me. Unfortunately he does not want to sell me the only phone that is actually better than my W880i. I do not want to do business with Netcom. I have nothing against Netcom, except I don't want to do business with them. I am happy where I am. I know I can get an iPhone and cancel the deal and pay some sum and get the phone, but for 5.400 norwegian kroner I can buy myself another server, or a fully loaded laptop with 13-15" screen, 250GB disk drive, DVD burner, 4 GB memory and so forth. So paying 5.400 for a phone is out of the question, at least up front, I don't mind paying 200 norwegian kr a month which include free minutes, and smses and free calls to my wife.

So I got myself an Nokia E71. Why did I get Nokia since I really think their other phones are so bad they should be melted into jewelry ? I thought it had this fantastic e-mail support since it is supposed to beat the Blackberry RIM/perl whatever and it has a full keyboard.

First impression, I like it. New look of the menus, still the same crack smoking vodka induced messed up menu system, but much faster overall than the N95. I have not tested to see if there is a better audio book support.
I can recommend the phone, I have ssh terminal client on it that works, I actually logged into my solaris box and created a new zone using just my phone, which is totally cool. Fonts are nice, not great but nice.

Only problem I see so far is that it takes 2 seconds from clicking on reply to sms/email until I can start typing, and it takes quite some time to actually send the mail.

I will see if switching the memory card will do anything.

Conclusion so far (will/might change). My W880i is better phone but I will keep the E71 for some time longer due to larger screen and ssh client and it doesn't hurt that the phone actually works and syncs with no problems or extra cost with my Mac.

I might change back, but not today.

Nokia, if you want to hire me to redesign your phones and make them so much better, contact me.