chuyeow's pings
Sort By:
Now that’s how you get a Dungeons and Dragons fan to read your spam:Laurana’s in Qualinesti now, attending the funeral of her father and also trying to arrange an agreement with that stiff-necked brother of hers, Porthios, and the Knights of Solamnia.
Not too long ago a couple of the Ubuntu Dapper Drake (6.06 LTS) VPSs we use abruptly became inaccessible. These VPSs were NIS clients that suddenly could no longer connect to the NIS master. Great. And as far as I could tell I didn’t do anything to those servers. I even managed to replicate the problem on another similar VPS (that was still accessble) simply by …
So there’s this big Leopard thing that’s the talk of Mac town (well, that and Safari) with all the new features being revealed (officially, at least, to the general public) at WWDC 2007.Some of the features are pretty cool, most of them are mundane. For me, I am really looking forward to:the new Finder - Finder sucks so bad as a file system interface. I use Path …
Today’s (un)feature covers the oft-abused and misunderstood with_scope method. The excellent err.the_blog had a post on how you should be using with_scope (yes, only use it in your ActiveRecord models, not in your controllers or filters). Yes that blog post may have been written a long time back but it’s still applicable to Rails 2.0.With ...
Rails Metal has been available on Rails since version 2.3 – it’s old news. But if you haven’t used it or heard about it, you can find out more about Rails Metal on the RoR weblog and on Jesse Newland’s blog.So anyway, I am one of those laggards and only wrote a Rails Metal piece ...
I don’t think I need to explain how concatenating your 5 stylesheets and 12 JavaScript files into single files each makes your webpages load faster. Unless you’re using multiple asset hosts (Rails 2 allows for multiple asset hosts), then it becomes tricky to say for sure which method is better, but I digress.There’re a bunch ...
If you’ve tried to output JSON from your Rails applications before, you’d probably have noticed how inadequate it all seems. Let’s look at the kind of output (pretty-printed for easier reading) you get from calling to_json on your typical User model:{ attributes: { id: 1, name: "Konata", ...
I’ve been using Autotest (part of the ZenTest package) while testing my Rails applications and never thought of asking for more. After all, getting my tests (well, specs actually) run automatically whenever I make a relevant change and having diff-level granularity on which tests Autotest re-runs is pretty damn useful enough. That is, until I came across this RSpec and …
It was a few weeks later than planned, but finally (actually, about 3 days ago), we‘re up on the News.com.au Travel section.No thanks to a CSS bug in IE6, we were delayed by a week. The last thing we expected was a CSS bug hanging IE6 but yeah, well, it was. At least now my conscience is clear - everything works nicely in IE6, IE7, Firefox, Safari and Opera.
If you’re on edge Rails and are having problems starting script/console, it may be caused by spaces in your Rails working directory (see ticket 7955: Console environment load broken when RAILS_ROOT contains spaces). Basically the lack of quoting on RAILS_ROOT causes console.rb to pass incorrect paths to IRB (it gets split on the spaces in your directory path).Just in …
For those of you who use the excellent Railscasts TextMate theme and want to replicate the theme in Xcode, you can grab my version from Github. This is what it looks like:Save it into ~/Library/Applicatio n Support/Xcode/Color Themes/, restart Xcode, and open its Preferences. You will be able to pick the Railscasts Color Theme in the ...
Pardon the self-promoting cross-linking: Toilets and Linux evangelism (or what we use to build Bezurk) is an entry I just posted on the brand new Bezurk Blog about how the toilet is a good place to spread the word. If you’ve found other neat ways to use the free Ubuntu stickers (or even the Apple stickers that comes with iPods), do post it!
After upgrading my girlfriend’s iPhone 3G to OS 3.0 recently, I noticed that the iPhone’s battery was getting depleted really quickly. I’d left it overnight with Wifi, 3G, Bluetooth, Push Notifications all off, and the battery went from 80% to a jaw-dropping OMGWTFBBQ 10%.I attributed it to the recent jailbreak (I’ve already removed the jailbreak ...
Doing GROUP BYs in ActiveRecord has always been tricky. There’s a lot of “magic” in ActiveRecord and room for untested edge cases. Thankfully, Rails also has a squadron of eagle-eyed contributors who are on hand to fix unforeseen errors.For example, if you wanted to do this:class Click < ActiveRecord::Base belongs_to :site # site_id ...
As of Curb 0.3.7, Curb comes with slightly better cookie support that makes it more “curl-like”.It probably sounds like shameless self-promotion that I’m blogging about these changes since I’d contributed them. Well, yeah that’s true, but I’m also doing so because I doubt these changes will ever be made known since Curb doesn’t …
After 5 long years of using the same old blog theme, which I’d handcrafted from scratch way back in 2004, I’ve finally got down to refreshing it to a more contemporary look. I’ve also updated the woefully outdated About page.Here’s a before and after shot:I think it’s much better, definitely more modern and minimalist.The new ...
Wow, it seems like I haven’t posted anything this year. Don’t worry, you aren’t rid of me yet. I’m still alive and posting updates to FriendFeed and (less often) to Twitter.If you belong to what I imagine must be now the microscopic population of loyal readers of my blog, please do hook up with me ...
Jeena emailed me recently about his Rails plugin, plistifier, that allows you to render plists (property lists).It allows you to render your ActiveRecord objects as plists (among other things):def show @post = Post.find(params[:id ]) respond_to do |format| format.xml { render :xml => @post } format.plist { ...
These instructions have been tested on Ubuntu 9.10 (Karmic) 64-bit. Skip right to the instructions if you’re short on time.After being a happy Xen user for several years now, I’ve recently had to switch to an alternative virtualization solution. My colleague Arun (@iamclovin) actually struggled for a week with Xen VMs that locked up on ...




…