Showing posts with label misc. Show all posts
Showing posts with label misc. Show all posts

Friday, 4 July 2008

Full disclosure: Bought off with a ReSharper licence

In the interest of full disclosure, I recently got sent a free ReSharper 4.0 Personal Licence from JetBrains. I really don't know why. The explanation in the email I received was very generic: "for donating so much of your time... whether in the form of plugin development, quality verifying, promoting or educating about ReSharper".

I emailed them back and asked why I got included in the list for a free licence, but haven't received a response. All I've done for ReSharper/JetBrains is left them a comment or two, downloaded the R# 4.0 nightlies and maybe even tried to submit one of those automated bug submission thingoes (which I think failed due to the proxy at my work). I have blogged a couple of times on ReSharper, although never anything high-traffic. So I'm at a loss to explain why.

I haven't used the licence yet (was hoping to find out why I got it first), but I guess you can probably disregard anything positive I've ever said about R# now I'm owned by them after being sent free swag. In fact, just assume from now on that I have absolutely no integrity whatsoever. Luckily astute readers are already way ahead of me on that... :)

And no, I can't give it to you instead because the licence is non-transferable :P

Tuesday, 29 April 2008

When Vista won't read a Microsoft DVD...

WARNING: Fluff piece ahead!

I recently attended the Microsoft Heroes Happen {2008} launch event for VS 2008, Windows 2008 and SQL Server 2008 in Sydney. All attendees received a "launch pack" of Microsoft software, which included a promotional, 90-day trial of Visual Studio 2008 Team System.

I chucked the DVD in the drive of my home PC and Vista asked me what I wanted to do with the blank disc.

DVD not recognised in Vista

Great, so I managed to get a faulty disc, right? Well, on a whim I fired up my Ubuntu 8.04 VM and tried reading the disc:

DVD read fine in Gnome

So to install my promotional Microsoft software on Microsoft Vista I had to rely on Linux. :-) Turns out it was just a driver issue with Vista from either a recent update or software installation, fixed by removing and replacing the DVD device in Device Manager, but I still found it mildly amusing. While not qualifying as ironic, it probably meets the Alanis-definition :-)

Wednesday, 12 March 2008

Tweaking your Blogger blog

A non-programming post today. Here is a collection of miscellaneous tweaks I have used on my Blogger blog, just in case I need to find them again. Some of them may require certain Blogger options enabled (like archiving etc). I haven't changed much from the defaults, so if something does not seem to work you might want to check your options and see if that accounts for the difference.

Warning: back up your template before making any changes to it!!! As with all my content, all tweaks here are completely without warranty, and may destroy your blog and/or the universe as we know it. You have been warned. :-)

Tracking visits

There are lots of statistics providers out there. I use Google Analytics. It is easy to setup. Once you have signed up you will be given a snippet of JavaScript code to include on all pages you want tracked on your site. For basic Blogger blogs like mine, this just means editing your template and pasting the tracking code just before the closing </body> tag.

The Analytics terms of use also require you to include an easily accessible Privacy Policy on your site. I did this by creating a new post called "Privacy Policy", and adding an HTML footer to my blog (Dashboard -> Layout -> Page Elements) to include a link to the policy.

Tracking feed readers

Sign up to Feedburner and you can track how many people subscribe to your RSS/ATOM feed. It can also do some tricks around formatting your feed. You can then re-point you Blogger feed to your new feed address: Dashboard -> Settings -> Site Feed and enter the feed address in the Post Feed Redirect URL field. Also a good idea to throw a purdy feed icon and subscribe link on one of your sidebar widgets.

Sensible search engine indexing

I found that searching my blog using Google commonly displayed results from my archive pages. This means that the post I was searching for appeared somewhere amongst my 15 other posts for that archived month.

To fix this I added some META tags to my Blogger template to give search engines some hints about my content. In the <HEAD /> of my template I added the following:

<b:if cond='data:blog.pageType == "archive"'>
  <meta content='noindex,follow' name='robots'/>
</b:if>
<b:if cond='data:blog.pageType == "index"'>
  <b:if cond='data:blog.url != data:blog.homepageUrl'>
    <meta content='noindex,follow' name='robots'/>
  </b:if>
</b:if> 

The first META tag tells robots not to include archive pages in their index, but to follow all links on the page (which go to the full post at its permanent address). The next is optional, and does a similar thing for index pages of your blog.

Since Googlebot has made a few rounds with the new META tags, I have a much easier time finding my own content, and as a side benefit have noticed a lot more visitors coming from search engines (some of whom I've even been able to help!).

Adding pages to your blog

Unlike Wordpress et al. Blogger doesn't provide additional pages for your site (well, not if you aren't using the FTP option). If I need to add pages I tend to write a new post with an appropriate title and use its permalink (see Privacy Policy or Search Results). Downside is that these go out on your feed :( (although you can work around this by changing the post's date to a long time ago, or a galaxy far, far away). Lucky for me I don't have any readers :).

Custom search results

Now that I've got my blog well indexed with my shiny new META tags, and know how to add pages to my blog, I want to add a search page that is a bit more advanced than the out-of-the-box Blogger search (which is still good, but doesn't abbreviate post content by default, and also makes finding older posts difficult).

My approach was to use a Google Customer Search Engine (CSE). I created one just for my blog, and added davesquared.blogspot.com/*/*/*.html as the only site and URL pattern for which results would be returned (this pattern will depend on your permalink format -- it works for mine!).

CSE provides a custom, Google-hosted search page for your search engine, but also provides some neat ways of embedding the search results within your site, including a nifty AJAX popup (see the Code link on your search engine's Control Panel). I found the nifty AJAX popup annoying, and ideally wanted something that should work everywhere, so instead I decided to put the search box in a widget on my sidebar, and have it post back to a Search Results page I created (see previous tweak on adding pages).

First to create the search input I added an HTML/JS Page Element to my sidebar, then added a slightly modified version of the code Google provides to host results on a non-Google page using an IFRAME. The modifications are to try and support browsers with javascript turned off, or without javascript support.

<!-- Google CSE Search Box Begins  -->
<form id="searchbox_(your_unique_search_engine_code)" action="http://www.google.com/cse" onsubmit="davesquared_submitSearchBoxWidget()">
  <input value="(your_unique_search_engine_code)" name="cx" type="hidden"/>
  <input value="" name="cof" type="hidden"/>
  <input style="font-size: 0.9em" name="q" size="20" type="text"/>
  <input style="font-size: 0.9em" value="Search" name="sa" type="submit"/>
</form>
<!-- Google CSE Search Box Ends -->
<script type="text/javascript">
function davesquared_submitSearchBoxWidget() {
  var searchBox = document.getElementById("searchbox_(your_unique_search_engine_code)");
  searchBox.action = "http://davesquared.blogspot.com/2008/01/search.html";
  searchBox.cof.value="FORID:11";
}
</script>

You need to change the (your_unique_search_engine_code) to the one provided by the CSE code sample (it looks something like 12312983712387129:asdfjkh23jh). You also need to change the searchBox.action line in the JS function to point to your own page for hosting the results. I've left mine in as a sample. Finally, you might want to change the JS function names so they don't say davesquared :-). The idea behind this is that if JS isn't enabled, a normal post request will be to the Google-hosted version of the search engine. It isn't nicely integrated with your site, but at least it works for non-JS toting users. If JS is enabled, it will update the search box to post to the results page on your own site.

Lastly, you need to add a bit of code to your search results page (http://davesquared.blogspot.com/2008/01/search.html for me). Again, you can get this code from your custom search engine's control panel.

<!-- Google Search Result Snippet Begins -->
<div id="results_(your_unique_search_engine_code)"></div>
<script type="text/javascript">
  var googleSearchIframeName = "results_(your_unique_search_engine_code)";
  var googleSearchFormName = "searchbox_(your_unique_search_engine_code)";
  var googleSearchFrameWidth = 600;
  var googleSearchFrameborder = 0;
  var googleSearchDomain = "www.google.com";
  var googleSearchPath = "/cse";
</script>
<script type="text/javascript" src="http://www.google.com/afsonline/show_afs_search.js"></script>
<!-- Google Search Result Snippet Ends -->

And that's it! Bit of work, but I find it invaluable for helping me trawl through my drivel to find some useful information. :-)

Line breaks

Basic one, but one I stuffed up when first starting out. Blogger can automatically insert <br/> breaks whenever you add a new line. This makes things easy if you never have markup in your posts. I always have markup in my posts, and commonly compose in Notepad++ and plain HTML. It can also make things difficult if you publish from a client like Windows Live Writer. You can turn off this auto-line break behaviour by Dashboard -> Settings -> Formatting and changing the Convert line breaks option. Be aware that this can stuff up your older posts a bit if you were relying on the previous behaviour.

Dotnetkicker

An ex-colleague of mine (I forced him to subscribe to my blog before leaving) submitted one of my posts to DotNetKicks. No I didn't force him that time, only found out when Analytics said I actually had some visitors :-). I did like the idea of putting a counter on the post itself so I could see if anyone voted for it, and also to make it easier on anyone that feels a post is worth submitting. You can manually put the code on each post, but it is fairly easy to add to your post template.

Go into Dashboard -> Layout -> Edit HTML, and make sure you tick Expand Widget Templates. First thing I did was to create an "includable" item (just chucked it between other <b:includable/> definitions, before <b:includable id='feedLinks' />).

<b:includable id='dotnetkicker'>
  <div>
    <a expr:href='"http://www.dotnetkicks.com/kick/?url=" + data:post.url + "&amp;title=" + data:post.title'>
     <img alt='kick it on DotNetKicks.com' border='0' expr:src='"http://www.dotnetkicks.com/Services/Images/KickItImageGenerator.ashx?url=" + data:post.url' style='border:none;'/>
    </a>
  </div>
</b:includable>

Note that this can stuff up if you have unusual characters in your data:post.title, so watch out for that.

The next step is to include the includable in the post itself. In <b:includable id='post' var='post' />, find where you want to put the kicker and include it like this: <b:include data='post' name='dotnetkicker'/>. I put mine after the data:post.body. End result was this:

...
<div class='post-body'>
  <p><data:post.body/></p>
  <b:include data='post' name='dotnetkicker'/>
  <div style='clear: both;'/> <!-- clear for photos floats -->
</div>
...

Highlight your own comments

I like on some blogs how the author's comments are display in a slightly different style, so you can quickly skim through the author's responses to feedback. This tweak might depend on what base template you use, but it should be fairly easy to apply the basic approach. First, add a style to your template (Dashboard -> Layout -> Edit HTML):

dd.comment-by-author {
  background: #F3F3F3;
}

You'll obviously need to customise the style to fit with your own blog. Next, in the <b:includable id='comments' var='post'/> code, find the loop that renders the comments (<b:loop values='data:post.comments' var='comment'>) and update it to include the following condition (changes emphasised):

<b:if cond='data:comment.author == data:post.author'>
  <dd class='comment-body comment-by-author'>
    <p><data:comment.body/></p>
  </dd>
<b:else/>
  <dd class='comment-body'>
    <b:if cond='data:comment.isDeleted'>
      <span class='deleted-comment'><data:comment.body/></span>
    <b:else/>
      <p><data:comment.body/></p>
    </b:if>
  </dd>
</b:if>

This selectively applies the comment-by-author style to comments (I couldn't find a nice way to do it using an expression (expr) on the DD class attribute).

Fixing standard comments link

When viewing stories on the front page of your blog there is generally an "x comments" link. I always expect this to go off to the full post and jump to an anchor at the comments section. Instead, by default, it takes you to Blogger's dorky comment submission form. This displays the comments in a fairly unfriendly format, and is hosted at www.blogger.com, rather than integrated into your blog's look and feel.

This is easy to fix by jumping into your template again (Dashboard -> Layout -> Edit HTML, make sure Expand Widget Templates is checked). Look for code that looks similar to the following an change the link to that shown emphasised below:

<b:if cond='data:blog.pageType != "item"'>
  <b:if cond='data:post.allowComments'>
    <a alt='View any comments left on this post' class='comment-link' 
      expr:href='data:post.url + "#comments"'>
      <b:if cond='data:post.numComments == 1'>
        1 <data:top.commentLabel/>
      <b:else/>
        <data:post.numComments/> <data:top.commentLabelPlural/>
      </b:if>
    </a>
  </b:if>
</b:if>

This makes the link go straight to the full post and jumps to the comments section. Readers can then go off to the dorky Blogger form to post a comment if they want, otherwise they can read the comments and scroll up to read the full story if they like. Down side is potentially one extra click if readers want to leave a comment, but to me this behaviour is closer to my expectations when reading posts. If the extra click worries you, you could always add a direct "Post a comment" link to the original Blogger form.

Previous posts

Here's a couple of previous posts that relate to Blogger tweaks:

Hope this helps!

Monday, 19 November 2007

Happy anniversary to me!

I just realised I have been blogging for a year. I wasn't sure what to expect when I started, but I have ended up really enjoying it, pumping out 189 posts to date, some of which are hopefully not pure drivel. I thought I'd post a quick summary to celebrate in a moment of self-indulgence. :-)

When I started blogging my main purpose was to just store some information that I found in other blogs. Basically just more advanced bookmarks. Once I started I noticed there were other benefits, so I have revised my motivations a bit. 

My main purpose for blogging has shifted to using it as a personal tool for learning. I find by explaining concepts I am learning or using to an imagined audience I get a much better understanding of the concepts. There is a big difference between being able to apply a concept and being able to explain it. My secondary purpose is related to my original purpose, to record information that I might need later. And my final hope is that some of that information will be useful to some other developers out there that stumble across my blog.

Since counting stats in August (I reset the stats then) I have had around a thousand visitors stumble across my little patch of the Internet which is nice, as I haven't been promoting it or anything. I toyed with the idea of submitting stuff to DotNetKicks, but when it comes down to it I am really just blogging for me. If someone finds something they need in here via Google then great! I hope you found something that helped!

My most viewed posts to date are:

Over the next year I'm hoping to really improve the technical articles in my blog. I am getting to do loads of development in my current role that gives me lots of opportunities for learning/blogging, as well as getting a bit more free time to research and experiment now that my eldest daughter is heading off to "big school" and probably won't want her old man hanging around embarrassing her anymore ;-).

To all my former colleagues that I forced to subscribe, looks like you'll have to put up with at least another 12 months of nonsense being spewed from my feed. And don't even think about unsubscribing -- I know where you work! :-)

Thursday, 15 November 2007

The Illustrated Catalog Of ACME Products

Somehow* I ended up here:

The ORIGINAL Illustrated Catalog Of ACME Products

Great site for all your ACME product needs. Ah, the memories :-) 

* Reading jdn's post on the ALTNETCONF list for acquiring a Bellware translator, which referenced the Wikipedia article which linked to the catalog.

Wednesday, 17 October 2007

I had a nightmare like this once...

From TheDailyWTF:

"...a basic Access application shared by tens of thousands of employees..."

I get cold sweats and shakes just thinking about it. :)

Friday, 12 October 2007

Fight the Bull!

I used to have fun with this tool ages ago:

Fight the Bull - Download Bullfighter

Originally developed by Deloitte Consulting, it is a plug-in for Office that picks up any bull^H^H^H annoying business jargon you have used. I remembered it while desperately searching for the correct spelling of the word "remediated", then I suddenly realised that this was a stupid thing to write when I meant "fixed" (go easy on me, I have been writing documents for management consumption over the last day or two). 

Try running it over the following sentence:

As a Centre of Excellence, we will leverage new paradigms, synergise economies of scale and provide vertical and horizontal-alignment between stakeholders.

Bullfighter comes up with some classic suggestions and comments (stakeholders? Did you mean: vampire slayers?). It is really fun to run over official communication from management types ;-)

Granted, there are times and places for different communication styles, including jargon, but it is fun to have a laugh at some of the ridiculous terminology we come up with in pursuit of a dollar/pound/euro/yen etc.

Friday, 28 September 2007

The art of structured procrastination

I found this funny: Structured Procrastination (linked via Brian Marick's blog). If you want to get the gist of the article, just put off reading it by finding something productive to work on :-).

In fact this kind of reminds me of TDD. You can procrastinate on the big problems by implementing all the little tests for the features and behaviour you understand well. As you do this you end up discovering parts of the big problems that are easy to solve, or at least learning more about the requirements and are better placed to solve the big problems. By the time you get to tackling the big problems you find that there aren't any left -- they have been reduced to fairly simple tasks. You have actually been fairly effectively applying a divide and conquer strategy.

The procrastination thing also ties in quite well with the "lazy programmer" concept.

Yes, I am quite aware of the irony of this post. :-)

Tuesday, 25 September 2007

Go the Cats in 2007!


Hoping to end the 44 year drought on Saturday :-). Was great to have Sydney get up in 2005, but in their absence would be fantastic to have the family team win the flag in 2007.

We now return you to your regular geek broadcats, er, broadcast...

UPDATE: We won by a record-breaking 119 points! 24.19 (163) to 6.8 (44).

Image sourced from here. Rights owned by GFC. Fair use here I reckon ;)

Thursday, 6 September 2007

Refactoring your life?

Non-techie link for the day. The Zenhabits blog has 72 ideas to simplify your life that are at least worth a skim and at best a good starting point for refactoring your life to a simpler, happier existence :).

I've always found the parallels between some software practices and life slightly amusing. For example: prioritising the simplest thing that will work as in TDD can also be helpful for sorting out complicated issues in your life.  The link to the Zenhabits post was found courtesy of Kevin at the Scribesonic blog.

Monday, 20 August 2007

First impressions of Vista

I installed Vista Home Premium edition on my PC. Here is my rationale for doing so and my first impressions. Disclaimer: I am generally pretty biased against Microsoft OSes (as you can probably tell from my first heading :-)).

Rationalising insane actions

Why on earth did I do that? Well, truth be told I'd be quite happy running Linux, but my wife can't (read: won't try :P) get used to it, and also needs MS Word for work. That left me with lots of dual booting which quickly got tiresome. I did try running WinXP in a VM from Linux, but had some problems which I can't recall at the moment. I know that using the proprietary NVidia driver did make my Linux install a bit unstable (never had a crash with my old RedHat 5.2, or 6.x installations from years back, so one or two crashes in a fortnight was quite a shock).

I did really enjoy running in Linux and keeping a basic level of knowledge of bash scripting, basic Linux workings, doing some Java coding with Eclipse and playing around with Mono, but I also figured that I should focus on honing my .NET skills. It is my day job after all. Not that I intend to neglect the other stuff -- to me it is essential to keep learning as much as possible and exposing myself to different viewpoints and technologies, so I'll be setting up an Ubuntu 7.10 VM ASAP.

So why not stick with Windows XP, especially in light of the fairly mediocre press (understatement alert) Vista has received? (The shop owner muttered "Vista is a dog" as I brought out the plastic to pay for it, and I had similar reports from a couple of the technical staff at work too, not to mention loads of negative reviews and blog posts). Well, main reason was I had WinXP Home edition, which does not let you control NTFS permissions. I wanted to lock down my family photos like I do in Linux, so that no one can delete or edit them without the correct privileges. Last thing I want is losing 5 years worth of memories when my 4 year old gets bored with playing Dora the Explorer and decides to play Windows Explorer. Other reason is I figured I should get with the times and not use 6 year old technology :) (um, how much of Vista was rewritten again? :$) So Vista it was -- and I'm actually quite impressed.

Performance

Even on my fairly basic system (AMD Athlon 64 3500+, 1GB RAM shared with on-board NVidia graphics), it runs surprising well (Aero Glass, letting Windows adjust special effects as it sees fit). It occasionally has a brief pause for thought, but in general everything comes up very snappily. Definitely does not seem any slower than XP, and in most cases seems to respond faster. I should mention that I am using the very precise, scientific, SI-recognised "seem" unit of measure, as in "it seems faster". This was probably my biggest concern based on the hearsay.

Aero Glass

The Aero Glass theme and desktop manager offers a nice look-and-feel, a decent level of colour customisation (although as always the UI customisation options are pretty minimal), and the eyecandy animations and translucency and helpful and purdy respectively.

I have traditionally despised eyecandy, but since discovering and subsequently enjoying Compiz and Compiz Fusion (formerly Compiz, Compiz-Quinn, Beryl) for months I have revised my hatred for such resource-intensive frivolities to exclude the following circumstances:

  1. When it gives helpful feedback cues to the user (animated minimise, focus or "requires attention" cues, new window mapped etc.)
  2. When it doesn't sap every inch of strength from my PC (off-loading windowing operations to the graphics card and taking the burden off my poor CPU)
  3. When it just looks too cool to ignore :-)

Compiz does seem more responsive and less resource intensive that Aero (returning to my scientific "seem" measure again), and also does loads more, but Aero does look great and works nicely and simply out-of-the-box. The Win+Tab to use the Flip 3D application switching is awesome (it meets all three of my criteria for sparing it from my eyecandy hatred :-) ).

Other nice stuff

Windows Explorer is much more useful now. I always ended up turning off the metadata and "common tasks" views in XP, but it is all integrated really nicely in the new Explorer. It reminds me a lot of GNOME's Nautilus (or does Nautilus remind me of Vista's Explorer?), but with more integrated information and nicer widgets. The location bar has a breadcrumb trail showing the folder hierarchy above the current folder which makes navigating very easy, but also automatically switches to standard input mode when you want to type in a path (which I would love to see in Nautilus). The folder treeview on the left automatically scrolls horizontally to fit in your current folder, but I am currently finding this a bit distracting. Most of these improvements flow through to the common dialogs (open, save etc.)

The search feature in the Start Menu is great (although I have been using Launchy for so long which is much better again IMHO). The "All Programs" link now works in a more "folder browser" way which I am having a bit of trouble adjusting to, as I can no longer quickly run the mouse over a hierarchy to find my application, but to be honest I think I will probably stick to using search or Launchy (the former option is probably what they intended).

The file structure in Vista is simplified. For example, by default you now have C:\Users instead of C:\Documents and Settings, and you can actually navigate the folder without being bombarded with loads of superfluous directories. One good example given in Derek's post is that music is stored in C:\Users\MyUsername\Music rather than C:\Documents and Settings\MyUsername\My Documents\My Music. I like that (very Unix-ey :-) ).

The UAC is really helpful. I haven't found it intrusive at all, and really appreciate it after enjoying Ubuntu's similar gksudo for so long.

I also noticed that Vista went into hibernation after being idle for ages. This is not much of a feature on its own, but the nice surprise was that it actually came back to life when I pushed the power button! It fired up very quickly and resumed my previous session nicely. Previous efforts to use stand by/hibernation with Windows 2000 and XP on my laptop were generally greeted by an error screen (after a long wait) saying it could not resume, and then a reboot.

Finally, Windows Update is really nicely integrated into Vista. You get a very nice few of the updates available (including device driver updates and optional updates), as well as a log of what updates you have installed or are pending installation.

It's not all beer and Skittles...

My main complaint with Vista so far is that it occasionally comes tantalisingly close to having a great feature, only to trip at the final hurdle. One example is storing user data. You can move all 11 or so known folders (or junctions or whatever they are) like Documents, Music, Pictures etc. for each user to a second hard drive by right-clicking, going to properties and changing the location (similar to moving My Documents in XP). Unfortunately it seems nearly impossible to do this for the whole Users directory without going to an unattended deployment. <rant> How hard would it be to just move the functionality up one notch and be able to mount the folder where ever you want it? It is crazy that I can't easily drop my home directory on a second drive or partition. I've been doing it on Linux for more than a decade! </rant>

Little things like that, which should be easy but aren't, really tend to tarnish my opinions of many MS offerings (had very similar experiences through 3 generations of SharePoint too). As an aside, it is also one of the reasons I love Linux -- you very rarely get stuck with something like this that you can't change, and if something really annoys you, you generally have the option of firing up emacs or similar and fixing it yourself (unless emacs itself annoys you, in which case you are stuffed, or worse -- stuck with VI! I kid! I kid! :-P ).

The apparently pervasive DRM embedded in Vista is something I object to in principle, but in reality won't really affect me as I don't use my PC to play DVDs or anything (so I don't have to worry about my PC not approving of my choice of hardware and downgrading video output or such nonsense).

As a minor hiccup, after installation and the first load of patches from Windows Update my machine froze during the obligatory system restart. Not the best start to the build, but haven't had any problems since (it was related to a driver update -- maybe the same gremlin that occasionally attacked my Linux box).

The sidebar and gadgets lasted about 15 seconds before being turned off. Took a while to load and didn't really do much for me. Who sits at their PC watching photos scroll past on their sidebar anyway? Isn't that what screen savers are for? :-) I am sure there is a legitimate use for this stuff, but I'll keep my RAM and CPU for things like loading apps thanks.

Verdict

I am pleasantly surprised by my experience with Vista so far. While I can understand a number of the criticisms leveled at it (such as, it took 6 years and this is it?), it seems Vista itself is a nice OS when evaluated on merit rather than on the amount of innovation or similar it brings to desktop computing. I am definitely not going to miss Windows XP. True, I still need to install Office and Orcas on it, and actually use it for a bit :-), but I am honestly surprised by how much I don't immediately hate it ;-)

Friday, 17 August 2007

dpreview.com: Digital camera reviews and news

I always forget the name of and link to the Digital Photography Review site. It always seems to have fantastically detailed reviews of all things digital camera-related (although the navigation is easy-to-miss: there is a page selector at the top of each review and a "Next" link in the Actions section at the very bottom). Don't know about any biases/conflicts of interest they may have, but they seem to be very objective in my experience.

Friday, 3 August 2007

Excluding your own visits from Analytics reports

It is easy to exclude your own visits to your Analytics-tracked site when you have a static IP -- you can just filter out all requests from there. It becomes a bit less straight forward when you have a dynamic IP, or on a large network that maps to a single public IP or IP block (say, at work).

It turns out you can use some built-in Urchin functionality to set a cookie on your browser, which you can then use to filter out your own visits. Google also has some help with this, but the former link is much clearer and more complete.

Because I did not want to setup a specific page to do this (as suggested in the article), I just use FireBug to execute the following JavaScript in the context of my site, which will set a cookie that expires in 20 years or so:

__utmSetVar("no_report");

, where "no_report" is the pattern you are filtering by in Analytics. The process for defining a filter is outlined here, and you need to configure it like this:

Filter Type: Custom filter > Exclude
Filter Field: User Defined
Filter Pattern: no_report
Case Sensitive: No

Update 2008-02-04: This post was originally published to work with the old Analytics tracking code. Since then Google Analytics introduced a new version of the tracking code. Instead of __utmSetVar(), the equivalent for the new code is pageTracker._setVar('no_report');. I ended up saving javascript:pageTracker._setVar('no_report'); as a bookmark.

Tuesday, 31 July 2007

Moving on... to programmier pastures

I am leaving my current place of employment as part of my constant effort to become a better developer. Part of Jeremy's tips on becoming a better developer include talking to and learning from (and with) other like-minded developers, which my current role just cannot offer.

My role was increasingly moving away from development (see screenshot below) and focusing more on higher-level aspects of technology, such as planning MOSS deployment and standards for zero-code MOSS-based applications. My new role is more development focused, and the people I have met in the team seem to share a lot of my goals in terms of improving development techniques and investing in good code.

I have been with my current employer for over 5 years, during which time I have gained two wonderful daughters and lost my wonderful Mum to cancer, so it has been a constant through both joyous and devastating times. I have also worked with some great people (I have to say that, two of them make up 100% of my blog audience after forcing them to subscribe ;-) Hi gents!). I definitely would not have stayed for this long if it were not for the fantastic personalities I have worked with (including the "brotherhood of the chilli-drenched doner kebabs", to paraphrase a line in Jeremy's post). I have definitely learned a lot here, including a lot of self-taught technical stuff, but also on the non-technical side of things from my manager and colleagues. 

As much as I'll miss the people, the fast laptop and the 22" wide screen display, I am really looking forward to more code and more developer peers. I start in early August.

So once I start contributing to an OSS project or three then I'll have covered all 6 of Jeremy's points. I wonder if he offers a guarantee with his "steps to success" program? :-)

Friday, 20 July 2007

Note to self: Learn Go

I always pretty keen on self improvement. Mladen wrote that part of his efforts to become a better developer would include playing more chess. In one of the comments, Lee Richardson suggested trying Go instead. Under the heading of "Cognitive benefits", the Wikipedia article on Go suggests:

The game purportedly increases usage of both hemispheres of the brain, in contrast to other games (such as Chess), which are primarily "right or left brain" games, and it also may reinforce the neurological connection between the hemispheres. This multi-dimensional play is supposedly the result of the combining of pure numerical calculation and an intuitive spatial awareness.

I like little mental exercises (sudoku, logic puzzles, Reversi/Othello, programming :)). Especially ones I can do (chess not really falling into this category, arguably not programming either ;)). So I'm going to see how I go with Go. :)

Saturday, 14 July 2007

Scott Adams' guide to writing funny

Scott Adams (of Dilbert fame) has a post on Writing Funny. I read some of this in one of his books (I find most of his work strangely amusing, although most of my colleagues don't. Maybe they just have taste). I'm just marking the article here in case I ever want to try being amusing in future.

Thursday, 12 July 2007

Privacy Policy

I have started to use Google Analytics on this site. Part of the Terms of Use is to include a privacy policy with adequate information on the use of Analytics for the site. So here is my privacy policy, which is quoted directly from Section 8.1 of the Terms of Use. I'll update this post if there are any changes.

This website uses Google Analytics, a web analytics service provided by Google, Inc. (“Google”). Google Analytics uses “cookies”, which are text files placed on your computer, to help the website analyze how users use the site. The information generated by the cookie about your use of the website (including your IP address) will be transmitted to and stored by Google on servers in the United States . Google will use this information for the purpose of evaluating your use of the website, compiling reports on website activity for website operators and providing other services relating to website activity and internet usage. Google may also transfer this information to third parties where required to do so by law, or where such third parties process the information on Google's behalf. Google will not associate your IP address with any other data held by Google. You may refuse the use of cookies by selecting the appropriate settings on your browser, however please note that if you do this you may not be able to use the full functionality of this website. By using this website, you consent to the processing of data about you by Google in the manner and for the purposes set out above.

Monday, 9 July 2007

The joy of pessimism

Great quote on my iGoogle homepage today:

The nice part about being a pessimist is that you are constantly being either proven right or pleasantly surprised. -- George F. Will (US editor, commentator, and columnist)
Amen George :-)

Thursday, 5 July 2007

Jeremy's technical reading list

Jeremy Miller has posted the technical books that have most influenced him. I have read a heap of technical books, but to be honest most of the best stuff I find is online.

I think the best technical book I have ever read is K & R's "The C Programming Language" -- it is succinct, nice to read and provides the reader with a great understanding of one of the most influential programming languages to ever grace a computer :)

The Blogger WorkShop: Creating a Blogger Template

Nice series of tutorials on Blogger templates.