Skip to content

Categories:

Beginner Capistrano FAQ Incoming

Being the documentation co-ordinator for Capistrano definitely has it’s privledges. I get to hold my head up high and say “we’re working on it!” when some says something derogatory about the documentation.

Or like today. Jamis sent me the transcript from yesterday’s online tutorial session. I’m only 25% through it and I’ve begun to draft 3 FAQs for the following topics:

  • What are the command line help options?
  • How do I manage my production database.yml file?
  • What does deploy:setup do?

We are working on the best, long-term place for the FAQ and other documentation to live. When we announce what our solution will be it will come from http://capify.org/news first. So just point your RSS reader to the feed, relax and enjoy all the great Capistrano news delivered right to your virtual doorstep!

Posted in programming.

del.icio.us/capistrano_links folksonomy

In order to better serve Capistrano users world-wide I will attempt to centralize and analyze all the great information out there on the w-w-w.  Hopefully this can be a place where you can search for information and answers, until we get better documentation online.

I will be adding useful notes as I evaluate the content behind the links to help you search through the account for answers.

Here’s the conventions I’m using to tag links for the capistrano_links account on del.icio.us/capistrano_links.

_official_sites_: capify.org, capistrano.lighthouseapp.com, official
application: mingle, radiant, webistrano
documentation: howto, faq, manual, links, quick_fix, rdoc, recipe
domains: give a domain scorecard. Highest score wins!
frameworks: rails, django, zend
gems: god, mongrel_cluster, sqlite3
hosts: site5, slicehost
languages: ruby, php, perl
libraries: deprec, capistrano-extensions
plugins: acts_as_ferret
scm: git, svn, cvs, perforce
tasks: deploy:rollback, deploy:cold (if specific enough or good example)
topics: agile, apache, passenger, spinner, svn_to_git
version: 1.4, 2.1, 2.4.3

Do you have a link to add?  Email me now: capistrano_links@filmprog.com.

Posted in programming.

RailsConf 2008 Personal Take Aways

I had a blast at RailsConf this year and just wanted to say a few things regarding the experience.

First off I want to thank Ruby Central (Chad, Rich and David) for their continued hard work.  All the hard work from O’Reilly employees as well.  Some unsung heros there I’m sure.

The Doubletree hotel bumped me up to the 15th floor because I checked in so late on Thursday night.  The room was amazing.  I didn’t want to leave, but the conference was better.

The conference sessions had some great speakers.  I was pleasantly surprised by how entertaining Joel Spolsky was.  I really took a lot out of his lesson.  More than just the three bullet points:

  • Put the user in control
  • Obsessive over aesthetic
  • Observe culture code

These three things are the qualities that if you had all three you have the maximum potential for what he called a “blue chip” product.  If you can focus on these things you can create a superior product.

For those people who didn’t attend the third point really boils down to knowing the language or jargon of your product’s domain.  So if you were creating a product for a 9-1-1 telecommunications center you’d probably need to know a term like EMT stood for Emergency Medical Technician.

The other big thing for me I took away from the conference was Nathaniel Talbott’s talk: 23 Hacks.  He mention that when talking to Chad Fowler about the joy of hacking Fowler admitted that he starts many more projects than he actually finishes.

For the longest time I have punished myself for starting so many “failed” projects as I might have called them.  But that both Nathaniel and Chad do the same thing, start many but complete few, that made me feel less self-conscious about my “incomplete” projects (note the adjective change).

Chad also said that musicians create much more music than they actually release.  And it’s in that joy or act of “jamming” on music where they practice in order to get better for when it is publicly consumed.

It all gels into a new paradigm for me and my programming.  That I can start as many personal projects as I want, as long as I’m hacking and having fun I can learn/practice/grow my art.

Sounds like next year is Vegas.  Should be interesting.  From personal experience working for another company, they should be ready for a huge increase in attendance.  Good thing O’Reilly has their back.

Now I’m off to code something.  Anything.  And have fun in the process.

Posted in programming.

Change default font Personal Brain Mac OS X

So I’ve been compiling a bunch of reused and useful command line snippets into my Personal Brain software. They then become searchable and easy to refer to when I need them the most.

But I don’t want to have to keep changing the font of the notes every time I write a new one. There is no way in the UI to set the default font so you have to hack it.

Open your Terminal and type:

mate /Applications/PersonalBrain.app/Contents/Resources/app/res/notes.css

I assume TextMate installed with the Terminal hook. But whatever editor you have will work, just use the path above.

NOTE: This is a global setting for all notes.

This is a definite weakness of the software. If you change the font of a note and come back to add to it, it won’t use the new font, it will use the global default.

I chose Monaco because it’s fixed width and I like it. Problem solved for me. Hope it helps for you.

Posted in programming. Tagged with , .

Create Zoom Shortcut in Mac OS X Terminal

So lately I’ve been getting into this flow of wanting to make a terminal screen full-screen when I need to focus or read long lines. And I’ve been getting sick of having to use the mouse to push the green plus sign to toggle this.

I did a quick search and found an Apple Script that will work for Terminal and TextMate, which are my bread and butter, respectively.

-- A script to automatically zoom the frontmost window.
-- © 2006 by Daniel Jalkut, Inspired by:
--
-- http://www.macosxhints.com/article.php?story=20051227001809626&lsrc=osxh
--

tell application "System Events"
	set frontAppName to name of first application process whose frontmost is true
end tell

set tryZoomedAttribute to true
set tryMenuScripting to false
set tryButtonScripting to false
set allMethodsFailed to false

-- Special cases. For Applications whose behavior we know responds to one or the other
-- method, force that method here.
if (frontAppName is equal to "iTunes") then
	set tryZoomedAttribute to false
	set tryMenuScripting to true
end if

if (tryZoomedAttribute is equal to true) then
	tell application frontAppName
		try
			set zoomed of window 1 to not (zoomed of window 1)
		on error
			set tryMenuScripting to true
		end try
	end tell
end if

-- Make sure the user has UI scripting enabled before we go on...
if ((tryMenuScripting is equal to true) or (tryButtonScripting is equal to true)) then
	tell application "System Events"
		if UI elements enabled is false then
			tell application "System Preferences"
				activate
				set current pane to pane "com.apple.preference.universalaccess"
				display dialog "UI element scripting is not enabled. Check 'Enable access for assistive devices'"
			end tell
		end if
	end tell
end if

if (tryMenuScripting is equal to true) then
	tell application "System Events"
		tell process frontAppName
			try
				click menu item "Zoom" of menu of menu bar item "Window" of menu bar 1
			on error
				set tryButtonScripting to true
			end try
		end tell
	end tell
end if

if (tryButtonScripting is equal to true) then
	-- UI Scripting method:
	tell application "System Events"
		try
			tell process frontAppName
				click button 2 of window 1
			end tell
		on error
			set allMethodsFailed to true
		end try
	end tell
end if

if (allMethodsFailed is equal to true) then
	display dialog "I'm sorry, I couldn't figure out how to zoom this window."
end if

As they suggest you’ll want to add it as a trigger via Quicksilver. This is where the article lacks information about how to do this so I give that here. I assume you’re using Quicksilver.

  1. Create a folder ~/Library/Scripts (if you don’t already have one)
  2. Copy the above script and paste it into Script Editor.
  3. Save that script as Green Zoomer.scpt in your ~/Library/Scripts folder.
  4. Use the Quicksilver keyboard shortcut Command + ; to bring up the Catalog.
  5. Click Custom on the left hand side, then on the bottom right you’ll see the plus sign to add a Source.
  6. Click that plus sign and choose File & Folder Scanner.
  7. Use the keyboard shortcut Command + Shift + G to type in a manual path.
  8. Type in ~/Library/Scripts, click Open.
  9. Click on the refresh icon in the bottom menu to make sure Quicksilver picks up the new script you added.
  10. Use the Quicksilver keyboard shortcut Command + ‘ to bring up the Triggers.
  11. Click the plus sign at the bottom and choose HotKey.
  12. The Select an item dialog box will appear or you can make it appear by clicking on the new trigger you’ve added.
  13. Type in the first field Green Zoomer and Quicksilver will pickup the file you created, and give it a default action of Run. That’s what we want.
  14. Click Save and you’re ready to zoom!

My Firefox browser would give me the error ‘UI element scripting is not enabled. Check ‘Enable access for assistive devices’ when I tried to zoom it.

Daniel’s script even apologizes for the error. But no apology is necessary, because OS X pops up Universal Access and you can just click on the Enable access for assistive devices check box and you’re good.

Thanks Simon for the original and Daniel for the rewrite!

Posted in programming. Tagged with , .