Oh boy I need one of these

Just saw this posted on Boing Boing. SO much cooler than a segway, and is that nuclear sticker for real?! If so it would never need recharging :)
03:17 AM, 31 Oct 2006 by Mark Aufflick Permalink | Comments (0)
Automatic copy from X11.app to MacOS Clipboard
This has bugged me for a long lONG time. I have been doing a bit of unix coding on my laptop this weekend and it finally got to me. There MUST be a way I thought.
A lot of people suggest autocutsel but all that does is synchronise the X11 CLIPBOARD buffer (or PRIMARY buffer) with the selection buffer. I'm sure this solves issues with some X11 apps that only use one or the other and X11.app may get confused. But that's not what I'm talking about.
I'm talking about:
- make a selection in emacs, yank a line, do whatever you want that "copies" a piece of text to the "clipboard" (for suitably vague meanings of those terms)
- switch to a MacOS app
- paste in the text copied in step 1.
(if (eq window-system 'x) (progn (defun paste-to-osx (text &optional push) (progn (let ((process-connection-type nil)) ; use pipe (let ((proc (start-process "pbcopy" "*Messages*" "pbcopy"))) (process-send-string proc text) (process-send-eof proc))))) (setq interprogram-cut-function 'paste-to-osx)))Update: After reviewing this entry on my front page it occurred to me how unlikely it is that anyone has ever hacked up a lisp code fragment directly after some visual basic! At least the foray into a little visual basic hasn't rotted my coding brain :)
11:26 AM, 29 Oct 2006 by Mark Aufflick Permalink | Comments (0)
Setting Outlook Categories with VBA
Open up the vba editor (Tools->Macro->Visual Basic Editor). Add a new module and paste the following code in (edit to suit).
Then to add the sub as a toolbar button customise the toolbar in the normal way and choose the 'Macros' category in the left pane - all your applicable macros will appear in the right pane. You can just drag it to your toolbar.
If the button seems to do nothing your outlook security settings may not be allowing macros. See Office Macro Security Settings.
Public Sub TagArchived() Dim objOutlook As Outlook.Application Dim objInspector As Outlook.Inspector Dim strDateTime As String ' Instantiate an Outlook Application object. Set objOutlook = CreateObject("Outlook.Application") ' The ActiveInspector is the currently open item. Set objExplorer = objOutlook.ActiveExplorer ' Check and see if anything is open. If Not objExplorer Is Nothing Then' Get the current item. Dim arySelection As Object Set arySelection = objExplorer.Selection For x = 1 To arySelection.Count strCats = arySelection.Item(x).Categories If Not strCats = ""Then strCats = strCats & ","End If strCats = strCats & "archived" arySelection.Item(x).Categories = strCats arySelection.Item(x).Save Next x Else' Show error message with only the OK button. MsgBox "No explorer is open", vbOKOnly End If' Set all objects equal to Nothing to destroy them and ' release the memory and resources they take. Set objOutlook = Nothing Set objExplorer = Nothing End Sub
06:10 AM, 27 Oct 2006 by Mark Aufflick Permalink | Comments (12)
How to do tagging in Outlook
After struggling for some time to find a good filing solution I just realised that it wasn't possible. Too many messages belonged in multiple folders at once.
I had another issue which was a humungous inbox, and an 'archive' folder to keep the inbox in check. But where is that email I want? Is it in the inbox, the archive folder, or some other folder?
Categories =~ Tags
What I wanted was tagging. So I hunted around Outlooks functionality and found Categories. Now this does mostly what I want. But it's so hard to get too - I have to right click messages to get that option? First solution: add a categories toolbar button which you can find in the "Edit" section when you customise the toolbar. I renamed it to 'Cats...' to save pixels. (MS KB article on customising toolbars).
Archiving
Then I wanted a way to 'archive' messages. It turns out that I can just tag messages with a category 'archived' and add a filter to the regular 'view' to exclude all messages with that category.
Filtered views
In addition I can set up other 'views' to show a subset of commonly viewed tags. To get easy access to those different views, add the views menu to a toolbar - you'll find a widget called "current view" in the 'view' section. You can also add a 'filter' button for ad-hoc changing what categories to filter by. (Somewhat useless MS article on using filters)
Ok great, but do I really want to click categories, then click archived, then click ok, every time I want to archive an email? I get hundreds of emails!
One great thing about MS Office apps is that nearly everything is exposed as a vba api. Sure, they are often bad api's, but you can do nearly anything with enough trickery. In the next post I'll include some vba code that will let you make a toolbar button for 'archiving' emails.
Update: The post (Setting Outlook Categories with VBA)
Automatic Tagging
If you used to have rules to file messages automatically - don't worry, because rules wizard understands categories and you can auto apply categories instead of filing. You can even add a chosen tag and choose to auto-archive or not (just like Gmail) by adding (or not) the 'archived' tag.
A neat feature of Outlook categories is that they persist when you reply/forward messages (within an MS Exchange network). If I dig out an old email that I have archived, forward it to someone with comments, and then they reply - all my categories are still there on their reply. Thats actually really useful, except that the 'archived' category means it disappears in my regular filtered inbox view. To counteract that we need some vba code that is triggered when new messages are delivered that will strip the archived cat. I'm too lazy to write that in vba (which has horrendous string manipulation support) so I just strip all categories on inbound emails. Instructions on how to do that in a followup post.
Reducing the clutter
Phew! We're nearly in email nirvana. But my screen is still full of junk that is redundant, wasting space, and distracting me. First I don't want any headers in my preview pane (right click in the grey background of the reading pane and un-tick "header information"). Then I want only one row of toolbar buttons (remove anything you don't want). I also reduced the number of list columns to a minimum (and added the categories column of course).
I also want to (usually) hide the navigation pane on the left - since I no longer need to constantly switch folders. But sometimes I want to switch between sent mail and the inbox (where all my email is - tagged or not) and also the calendar. So I made a toolbar with 6 buttons. Here are the toolbar command category/commands i have:
go/Inbox (assigned a custom icon) : Go/Sent Items (shortened name) : Go/Calendar : View/Bottom : View/Off
So my total toolbar looks like:
TODO: make this post more intelligable and add more screenshots!
06:04 AM, 27 Oct 2006 by Mark Aufflick Permalink | Comments (2)
War on Folate
It seems that the war on moisture has now been upgraded to a war on everything your body needs.Australian icon Vegemite is now being searched for by US customs authorities who could be doing more useful things, like targeting dead terrorists.
Now I can understand the US authorities not wanting Vegemite to enter their shores, because it tastes absolutely foul. But that's not their complaint.
No, their complaint is that it's good for you.
[Vegemite] contains folate, which under a technicality, America allows to be added only to breads and cereals.
That's right. That water soluble vitamin B that the US Government's National Institute of Health says you should get 500ug per day of and that helps prevent birth defects and may help prevent cancer and heart disease. It's so good for you that the FDA even requires that Folate be added to bread and other cerials.
10:27 PM, 23 Oct 2006 by Mark Aufflick Permalink | Comments (0)
Oracle. So awesome and yet so lame.
Ok, with that disclaimer out of the way, why is it so darn hard to get going. First of all it requires a relinking step, with a particular gcc, if you want to use it on OSX 10.4 (see these excellent tips). Second of all, you need to set up a bazillion and one users and environment variables before you even think about running the (ugly) Java gui installer (see these pretty good instructions).
So I have it kindof working, but can never quite login via sqlplus the way I imagine i should. All sorts of incantations result in the following cryptic message:
ERROR:
ORA-12162: TNS:net service name is incorrectly specified
I'm pretty sure the tnsnames.ora file is all sorted, so after the 20th try, I search the web. Thankfully Burleson Consulting has this excellent tip:
The error message ORA-12162 "TNS:net service name is incorrectly specified", is very misleading.It suggests that there is a problem with the tnsnames.ora file contents, but in reality the message [snip] results from improperly setting your ORACLE_SID value.
So there it is. Tripped up by yet another environment variable. What is it with these enterprise software people and their beloved environment variables?!
07:41 PM, 17 Oct 2006 by Mark Aufflick Permalink | Comments (0)
Hiring Programmers who won't make you say WTF!
Thus, the theory is that people who apply for jobs from this network will be somewhat pre-filtered.
Another job site. Great. Just what the world needs.
I think, actually, that what we're seeing is a move to specialisation in job referrals. Instead of bulk job sites trawl-fishing the global pool of developers, we're seeing a move to niche and network based job sites. Sites like LinkedIn are being very effective at providing candidates with pre-existing personal recommendations. Sites like jobs.perl.com have been providing domain specific candidates to employers in the know for years.
If you're in the hiring market you could do worse than try out The HiddenNetwork. During the Beta period posting is free! The site and their advertising will use geolocation to provide location sensitive jobs to candidates. And in a refreshing change from the control exerted by other job sites, candidates will contact you directly.
Disclaimer: I will recieve a referral bonus for anyone who takes out a job ad from the links above to The HiddenNetwork.
10:50 PM, 14 Oct 2006 by Mark Aufflick Permalink | Comments (0)
Life imitates Art as Montoya takes third at Talladega
The Colombian had to pit under caution several times to have his car fixed, but he was able to remain on the lead lap, despite falling back to 31st.The race was restarted on lap 45, and Montoya charged through the field to make his way up to 11th by lap 54.
"It's pretty nice. In F1 you go to the back and you stay in the back," Montoya added. "You can be two seconds a lap quicker than any other car, and you're still not going to pass. I think I passed probably 40 cars today easily. It was outrageous!" (autosport.com)
Cool!
In the end he finished third - very respectable for nearly his first time in a NASCAR car.
02:08 AM, 14 Oct 2006 by Mark Aufflick Permalink | Comments (0)
Good test coverage (by curling your right bicep)
Most of his comments could almost have been direct quotes from his (excellent) new book Practices of an Agile Developer but one answer about testing really caught my ears. In response to a question about how to know that your writing the right sort of tests in your test driven development, Andy gave the following mnemonic:
Right BICEPRight - are the results right
B - Boundary conditions
I - Inverse relationships
C - Cross check results (with other sources/methods)
E - Error conditions
P - Performance
I love simple mental tools like that. I'll certainly be mentally checking my right bicep when I write tests from now on. Previously I'd only been checking out my right bicep in the shower after the gym...
10:48 PM, 11 Oct 2006 by Mark Aufflick Permalink | Comments (0)
Simple /var/log/secure analysis
I turned on the intrusion filter on my firewall, so we'll see how that goes. Hopefully it won't impede real connections to my cvs etc.
For completeness I thought I'd add the ip address to the blacklist in my firewall. I saw a sea of attempted connections in my /var/log/secure log and came up with this very shell simple script to sift hack attempts out from bad typing days by either myself or my clients. In case it's useful for anyone I thought I'd blog it:
for ip in `awk '/Illegal user/ {print $10}' /var/log/secure |sort -u`; do echo "$ip : "`grep -c $ip /var/log/secure`; done
It makes some pretty wild assumptions but it did the trick for me. It gives output like:
202.136.62.130 : 16 210.0.204.27 : 762 211.137.76.105 : 887 218.247.185.214 : 29 ???.133.81.251 : 4 ??.143.0.183 : 4 61.187.8.54 : 329 ??.205.204.190 : 5I whacked it in a root cron file so I'll get a report each day. (Note I anonymized the low count ip's because I assume that it's me or a client just typing our usernames poorly.)
12:36 PM, 09 Oct 2006 by Mark Aufflick Permalink | Comments (4)
Magic Mug Cake
I don't know about you, but I love shopping in large supermarkets. The variety of wacky and interesting junk you can find there seems limitless. Many are worth browsing but occasionally one jumps aout and grabs you and you *have* to buy it.
So it was with the Magic Mug Cake! Pour the sachet into a mug, mix in an egg, microwave for 90 seconds, add your favourite topping for more fun - it just doesn't get much better than that! I was intrigued by this product. Only slightly less than the Folgers self-heating instant coffee that I bought from a supermarket in San Francisco last year. How does such a large amount of cake come from such a small sachet and only an egg? They're right - it must be magic!
Now the instructions are for a 660w microwave oven, so I figured that my mighty 1100w microwave should be dialed down to 60% and run for the same time.
With 10 seconds to go it was so far so good. As you can see on the left the cake was just peeking over the top of the mug - *magic*! As soon as the heat stopped, however, it sank right back down. It looked way to moist so I figured it needed some more time. After another 30 seconds it looked cooked - but not quite what the picture showed:
Thinking about the process, I think you must need the microwave power and time just right. I imagine that the process involves the cake bubbling up to it's maximum volume and then being 'snap-cooked' into that size/shape. Because I didn't let it run quite long/hot enough the first time the opportunity was lost.
Kath asked me how it tasted. "Just like cake" I said. "Yes, just like cake" she dubiously replied...
05:29 AM, 08 Oct 2006 by Mark Aufflick Permalink | Comments (0)
The creative programmer
Paul Graham is one of my favourite IT writers. Not that he's the best or the most insightful (although he is floating near the top) but because he combines programming with other creative pursuits. That's the way I think it should be. He also invests in the education of others and the support of their ideas.
Probably my favourite programmer (and also a good friend) Lars Pind is similar. He likes to write. He plays at least one musical instrument on a regular basis. He is aprolificphotographer. He's never afraid to debate his approach to programming or life. He programs fast and furious, but with a degree of elegance and insight that, I believe, couldn't come without all of the above.
It's qualities like these that I always look for when interviewing potential employees (or employers), but rarely find.
What do you think? Can you be a good programmer without being creative? Can someone be truly creative and maintain/nurture that creativity without a variety of creative outputs?
Another question to a certain section of the developer audience: How do you manage the peculiar balance of creativity; logic; and a perfectionistic need for symmetry and alignment that comes with programming excellence?
PS: This wasn't supposed to be a Paul Graham/Lars Pind love fest, but so be it!
Footnote: On a totally unrelated use of creativity, a study by Indiana Universtiy shows that (on some selected topics), The Daily Show is as substantive as regular news broadcasts!
09:56 PM, 05 Oct 2006 by Mark Aufflick Permalink | Comments (2)
Cool keyboard hardware
But there are two new must haves. Firstly, I have been looking for a good seperated keyboard. As much as I love the concave layout of my Kinesis, I really wish I could separate the two halves further. I also hate having to rehome after using the mouse. I used to love the nipple input on IBM Thinkpads for that very reason.
Last century scientists split the atom. This
century Ari Zagnoev split the keyboard.-- Australian PC World
The other accessory is this so cute it hurts USB powered hamster wheel. It turns at a rate relative to your current typing rate!
Unfortunately of the two, the hamster wheel is the one already in production...
"Ari Zagnoev" <info@combimouse.com> wrote: >Hi Mark > >Thank you for your interest. > >Unfortunately at the moment we only have a few hand made prototypes. > >Ari
08:41 PM, 05 Oct 2006 by Mark Aufflick Permalink | Comments (0)
LinkedIn.com redesign communicates less with more
- When reading someone's profile, the recommendations are not clearly distinct from the user generated profile. I didn't notice them when I skimmed someone's profile. I also think that placing them at the bottom (rather than inline) reduces the impact that they make.
in the headline box of someone's profile, I see: "profile", which means the profile telling me about the person; "connections" which means the connections that that person has (again - information about the person); and "recommendations" which I assumed meant recommendations for that person (ie. more information about that person). Instead it is recommendations that that person has made about others - which reverses the meaning of the other two tabs. Not only that, but when I did click it, the design doesn't make it clear that it is the other until I am part way into reading it.
The new design is subtle and clean, and more information is available, but it actually makes the information less self evident. In HCI terms, the design lacks what is known as affordance where the function of an object (in this case a link) is intuitively known by it's characteristics. In the case of (1) it's the visual characteristics (traditional affordance). In the case of (2) it's what I would call the "affordance of proximity" (which may or may not be a phrase already in use - I'm sure it is).
In my notes for this blog I jotted down "quote Edward Tufte, but I can't find anything appropriate, and I've gone a bit off Jakob Nielsen lately.
04:19 AM, 05 Oct 2006 by Mark Aufflick Permalink | Comments (0)
Archive
| October 2006 | ||||||
| S | M | T | W | T | F | S |
| 1 | 2 | 3 | 4 | 5 | 6 | 7 |
| 8 | 9 | 10 | 11 | 12 | 13 | 14 |
| 15 | 16 | 17 | 18 | 19 | 20 | 21 |
| 22 | 23 | 24 | 25 | 26 | 27 | 28 |
| 29 | 30 | 31 | ||||
March 2012
February 2012
November 2011
October 2011
April 2011
March 2011
January 2011
November 2010
October 2010
September 2010
August 2010
July 2010
June 2010
May 2010
April 2010
March 2010
February 2010
January 2010
October 2009
September 2009
August 2009
July 2009
June 2009
May 2009
April 2009
February 2009
January 2009
December 2008
November 2008
October 2008
September 2008
August 2008
July 2008
June 2008
May 2008
March 2008
February 2008
January 2008
December 2007
November 2007
October 2007
September 2007
August 2007
July 2007
June 2007
May 2007
April 2007
March 2007
February 2007
January 2007
December 2006
November 2006
October 2006
September 2006
August 2006
July 2006
June 2006
May 2006
April 2006
March 2006
February 2006
January 2006
December 2005
November 2005
October 2005
September 2005
August 2005
July 2005
June 2005
May 2005
April 2005
March 2005
February 2005
January 2005
December 2004
November 2004
October 2004
September 2004
August 2004
July 2004
June 2004
May 2004
April 2004
March 2004
February 2004
January 2004
December 2003
November 2003
October 2003
September 2003
August 2003
Blog Categories
software (40)..cocoa (21)
..heads up 'tunes (5)
..ruby (6)
..lisp (4)
..perl (4)
..openacs (1)
mac (21)
embedded (2)
..microprocessor (2)
..avr (1)
electronics (3)
design (1)
photography (26)
..black and white (6)
..A day in Sydney (18)
..The Daily Shoot (6)
food (2)
Book Review (2)
Notifications
Request notifications








