This is handy for reading (or cutting and pasting from) documentation that is in HTML that is included with open source software without jumping to an external browser. Check it out:
Archive for the 'open source' Category
The other day I was asked how much disk space a particular Kete project’s production database used. I didn’t have an answer, so I started searching for one.
In my case, the db software is MySQL and getting a report about various aspects of a db’s tables boils down to this query:
The output of this query has way more information than I need, plus to get the total number of bytes used you have to add all the values up anyway, so I decided to make a rake task to make this repeatable and return something succinct.
I have added the new rake task to the Kete app’s codebase. If you aren’t a Kete user, but need this functionality for your Ruby on Rails app, you can find it here:
Note there is a formatting method taken from the Rails Helpers, I would love to not duplicate this definition. If anyone has a recommendation for the best way to pull this method into this rake task, I would appreciate it. Probably a simple include statement, but I didn’t get around to figuring out the correct incantation.
I would also love to hear how best to make this handle other database software, for example PostgreSQL, too.
Server Setup and Deployment for Rails using Capistrano, Mongrel, and Nginx using Mac OS X for Development and Debian Etch for ProductionSunday, October 14th, 2007
As previously mentioned, I have written a guide on how to set up Kete (also applicable to other Rails apps though Kete includes some extra required software and niceties to make it easier) for Development on Mac OS X. This guide also includes best practices for Deployment. So the following guide can be seen as the first half of the story:
But what about the host that you are deploying to? I cover that for Debian Etch in the following guide:
You might also be curious what software Kete requires. Here’s a breakdown:
I’ve added a guide over at Kete.net.nz for how to install Kete for development on Mac OS X. You can find hit here:
If anything doesn’t work for you, please let me know.
I’m going to outline how to set up Aquamacs for my IRC requirements with the built in ERC emacs IRC client so that it automates joining the server and channels I want, with some other bells and whistles (the bell part, literally!). All of these steps have .emacs file equivalent, so you could use it as a starting pointing point for figuring out how to set them, even if you don’t use Aquamacs (Mac OS X GUI emacs).
Here are the steps:
Installing and Configuring Aquamacs (Emacs 22 for Mac OS X) with Ruby and Ruby on Rails Development NicetiesTuesday, August 14th, 2007
Personally, I like a highly portable text editor that is powerful enough to use as an IDE. TextMate, from what I hear, is pretty darn great, but by being limited to only Macs, TextMate doesn’t cut it for me. Emacs being emacs, it is quite possible to set it up to be as nice if not nicer than TextMate for Rails development. A good overview can be found at http://www.credmp.org/index.php/2006/11/28/ruby-on-rails-and-emacs/.
And WOW is emacs 22’s Tramp for remote file editing via SSH/SCP awesome! More on that at the end of this post.
Using Subversion with Piston to do vendor branch management for an entire open source Ruby on Rails applicationFriday, June 8th, 2007
People are moving away from managing their Rails plugins with svn externals towards Piston’s easy vendor branch management approach.
But what if you want to use Piston’s easy version of Subversion’s vendor branch management for dealing with the code for an entire Rails application based on an open source project like Mephisto, Collaboa, or in my case Kete? (more…)
From a howto on Robby on Railshere. You’ll want to read http://www.rubyinside.com/advent2006/12-piston.html for more commands and reasons to go this route.
I have a host where Nginx listens on port 80 and dishes out requests to various apps depending on what their host name is. It also does appropriate load balancing. Primarily I use this for hosting various instances of Kete Ruby on Rails apps, but I also use it for supporting the subversion repository under Apache and a few other RoR apps, too. I wanted to setup up web log statistics for all of the above and I wanted to do it in such a way that it’s easy to add another web app to view statistics for.
Awstats is wicked easy to setup if you live in the LAMP world, but I could find a decent tutorial that covered my setup. So here goes… (more…)
This assumes that you have already installed things outlined here.
$ sudo apt-get install libsvn-ruby1.8
$ sudo gem install redcloth
$ sudo gem install syntax
$ sudo gem install -y xhtmldiff
$ cd /path/to/where/you/have/your/apps
$ svn co http://svn.collaboa.org/svn/collaboa/trunk/ your_app_name_for_collaboa
$ cd your_app_name_for_collaboa
$ cp config/database.yml.sample config/database.yml