Malicious enjoyment derived from observing someone else’s misfortune
 

Tag Archives: ruby

Site5 promo code for October

You can still get 13% off a new Site5 7.5TB/750GB/$7.50 Plan until November! These guys are a great rails host. Get this deal while it’s hot! Code: HALLOWEEN2007

A Beer Atom Feed

So, after reviewing over 50 beers on BeerAdvocate, I’ve come to the conclusion that them not having an RSS or Atom feed of my most recent reviews available is stupid. So, I decided to make my own by scraping their HTML today. I started off by pumping some random code into irb that included Hpricot and Builder. Ruby rocks for doing stuff like this.

New Mephisto Post Pinger List

Today I found a nice ping list for WordPress. I decided to put it into my copy of the Mephisto Post Pinger plugin. I’m not sure if it works yet, but this post will give it a good test.

Site5′s 5 dollar hosting deal gets better again

OK – I’m usually pretty critical in general, but this is the best hosting I’ve ever found, and it’s 3 times better than when I bought it, and it’s still the same price! So, you should click the image above and go sign up. These guys give you great support – I’ve contacted them numerous times and always had my problem solved within just a few minutes. I’ve noticed my site down once, and as soon as I emailed them, [...]

Flash Video Player for Mephisto

So I made this awesome filter for Mephisto that allows you to easily embed flash videos in your post. May require tweaking if using a non-standard URL root. It’s as simple as this: <macro:flash>/assets/2007/8/13/party.flv</macro:flash> Or, you can make it complicated: <macro:flash width=”640″ height=”480″>/assets/2007/8/13/party.flv</macro:flash> Which ends up like this: Installation Install it from your mephisto directory: ./script/plugin install -x https://modzer0.cs.uaf.edu/repos/hank/code/rails/mephisto/filtered_column_flash_video Voila! Firebreathing!

Mephisto Post Pinging Improvement

So, the post pinger plugin was pretty awesome, but it was pinging RubyCorner and Rubylicious when it shouldn’t have. I made it tag-based so it checks a category of feed URL and decides whether the tag matches the category. Right now, I’ve only implemented it for the ruby tag since that’s all I should need for these two services. ArticlePingObserver::SERVICES = [ { :url => "http://rpc.pingomatic.com/", :type => :xmlrpc }, { :url => "http://rpc.weblogs.com/pingSiteForm", :type => :rest }, { :url [...]

PL/Ruby on CentOS 5

I had some trouble compiling PL/Ruby for PostgreSQL today on Modzer0. I solved it with some clever extconf.rb switches: ruby extconf.rb –with-pgsql-include=/usr/include/pgsql/ –with-pgsql-version=81 Now I avoid the problems I was having before: [root@modzer0 plruby-0.5.1]# make make[1]: Entering directory #… In function ‘perm_fmgr_info’:plruby.c:116: error: ‘TopMemoryContext’ undeclared (first use in this function) plruby.c:116: error: (Each undeclared identifier is reported only once plruby.c:116: error: for each function it appears in.) plruby.c: In function ‘plruby_call_handler’: plruby.c:706: warning: unused variable ‘result’ plruby.c: In function ‘pl_compile’: [...]

Automagic blending of wallpapers using RMagick

I wanted a program that let me blend random wallpapers from a directory together and set them every minute with increasing opacity on one image, and then to select a new random image and repeat the process. I did this using RMagick and some Ruby. Make the following tree: ~/.wallmold/ current.yml Fill current.yml with this: — file2: someimage wallpaperdir: wallpaper directory dissolution: 0.1 file1: anotherimage Replacing the image names and directory with the proper stuffs, full path on directory and [...]

Ubuntu hides gems from you!

You might think Ubuntu would put its gems someplace normal, such as /usr/lib/ruby/gems… Wrong. It puts them in /var/lib/gems, which explains why the cheat gem doesn’t work when installed. Now I need to add /var/lib/gems/1.8/bin to my $PATH.

Site5 Doubles $5 Deal!

I noticed today that Site5 has doubled their $5 deal! Now you get the following for only $5/month: 110 GB Storage 5 TB of bandwidth allowance per month 110 Domain Pointers Free Setup Ruby on Rails Friendly I am currently using this plan for this blog, and am extremely happy with it after coming over from Dreamhost. Sign up now!