This is pretty much exactly what my cat does every morning.[kml_flashembed movie="http://www.youtube.com/v/GmwqpHsMExg" height="425" width="355" /]
I never thought I’d say this, but um…I’m running…um…Linux. (again)
Last week, I needed to get an aging PHP app running on my laptop for a project. It uses a lot of hard includes and requires and is pretty finicky about where it lives and where other things live in relation to it. I tried working directly off the server, but that’s pretty painful if you’ve fallen head over heels in love with Eclipse and PDT the way I have.
I tried very, very hard to get the app working under windows using Apache Friends XAMPP, which I use to develop Zend Framework apps. No dice. It would have required rewriting half the app to get it to work. What I really needed was some way to mirror the server’s environment but still have a usable computer. I thought about using VMWare Server and all, but then we’re back to essentially non-local development and transferring files around and such. I don’t need a server, I need a desktop that can pretend to be one.
Being an avid Slashdot reader, I knew that the fine folks over at Ubuntu were readying their next release. Before I go any further, I should tell you that I am no stranger to linux or unix in general. I was loading mp3s on to my Diamond Rio using Slackware before iTunes was a brushed metal twinkle in the eye of Steve Jobs. I’ve been using BSD variants on web servers since I knew what web servers were. When OSX came out, it became really hard to justify continued desktop Linux use, as I could have a stable usable unix development platform AND run Photoshop and Reason. It was also around that time that I realized I would rather spend my time using computers to do useful things instead of say…recompiling the kernel so my wireless network card would work.
When I needed to edit video faster than I could on the fastest mac around, I switched from Final Cut Pro to Avid and from mac to Windows. While I’ve got no love for The Empire, XP is…well…okay. It’s not great, but it’s fast and stable enough that I can deal with it, and I know its flaws well enough to keep it in check. The problem now is that XP is really starting to show it’s age and I am not, under any circumstances, installing Vista. F@#k that thing.
But I digress. The point of this story is that I decided to give Ubuntu 7.10 a whirl on my laptop. The first (and very nice) thing I noticed is that if you pop the CD in a windows machine, it gives you the option to boot off of it and see how it works on your particular hardware. I was pretty shocked at how easily it determined what hardware I had and grabbed all the drivers for it right out of the box. I decided to back up my Windows XP install and go for broke.
The install took hardly any time at all, and before long I was up and running. If you’ve got a machine with nothing on it, installation is a literal no brainer, it’s like twelve clicks and you’re done. No drive partitioning, no compiling video card drivers into your kernel, nothing. It just works. The interface is very OSX like, in that things are in sensible places and work like you’d think they would.
Pretty much every time I tried to do something that I was sure wasn’t going to work, it did. Burn a DVD? Check. Connect to my Exchange server? Not a problem. (Evolution Mail can see Exchange through OWA.) I could even connect to my office VPN using a GUI that was actually better than the one Cisco gives you. What started as something I was doing because I needed to get a squirrely PHP app working had turned into something else entirely. I had installed desktop linux, and other than the fact that it worked really well, I hardly noticed the difference.
There’s a few things I still need Windows for, like games, music production, etc. My Windows XP desktop isn’t going anywhere until I can do those things under linux. That would be a great day, but I think we all know that’s not going to happen. It doesn’t matter, though. I don’t have any problem working on one machine and doing fun stuff on another. The one PC app I really needed and couldn’t live without was Photoshop, but I had that running under Wine in five minutes.
As for the actual development setup, which was ostensibly the point of all this, that could not be better. I installed Zend Core as my LAMP stack, which despite popular perception (and the perception given to you by the Zend people) is free. Sure, you can pay for updates and such, but if you just want to use it, go to town. It’s way easier than installing Apache, MySQL and PHP separately, plus it comes with a nice little web based GUI and a debugger that hooks right into Eclipse PDT. I was doing Visual Studio style debugging withing five minutes of having the software installed.
I was originally thinking that the next time I could afford to, I’d buy one of those new MacBooks to develop on. I don’t think I’ll be doing that any more.
Posted in PDT, eclipse, linux, ubuntu |
No Comments »
Zend Con 07 Update
I’m attending a session on extending PHP. Man, it’s been a long time since I’ve blown the dust of my C knowledge. I do not miss memory allocation. While I may never need to develop my own extension, it’s really edifying to hear how PHP maps userland things to the underlying C from the people who developed it.
Posted in moblog |
No Comments »
Google Blackout?
Someone recently pointed me to the rather ominous sounding Google Blackout. The site has a black background and huge white numbers that count down. Some quick math reveals that the number is what appears to be the number of seconds until January 1st, 2008.
What’s also curious is that if you turn off JavaScript and refresh the page, the countdown is replaced with “37* 25′ 38″, -122* 5′ 57″, which would appear to be GPS coordinates. Coordinates for what, you ask? You guessed it: Google Headquarters.
A WHOIS comes up empty. It’s private registered through Dreamhost.
I did notice that the default RSS feed for the page seems to be pointing at http://feeds.technorati.com/search/Google, but I doubt highly that Technorati has anything to do with it.
So…what is this? A cheap P.R. stunt? Some crazy-ass A.R.G? Terrorism? Who knows? I’ll update if I figure anything else out.
Posted in Updates, arg, google, google blackout |
1 Comment »
The most useful function you will ever use in the Zend Framework
Zend_Debug::dump() is a really handy part of the framework that simply dumps the contents of whatever you give it to print_r and wraps it in <pre></pre>.
I got tired of typing it out every time, so I added the following shorthand functions to my bootstrap file. (The only acceptable use of a function in a bootstrap, in my mind.)
-
-
require_once("Zend/Debug.php"); // next time we’re going to talk about __autoload()
-
-
/**
-
* dd is a shorthand function for "dump and die". It takes whatever you give it and
-
* spits it to d(), then dies. Useful for debugging.
-
*/
-
-
function dd($val){
-
d($val);
-
}
-
-
/**
-
* This is so I don’t have to keep typing Zend_Debug::dump($whatever);
-
*/
-
function d($val){
-
Zend_Debug::dump($val);
-
}
Posted in Zend_Debug, zend, zend framework |
2 Comments »