Tip of the Day: Set Git Author and Email [Updated] 1
Quick tip, especially if you use GitHub with Gravatar so a little profile picture will show up on GitHub you likely need to set your Author and Email for Git. So instead of falling back to your system username and machine name for an email address (at least on the Mac), and your account's long name for author name, Git will use the correct information and your gravatar will show up in GitHub (minimally just match your email with your Gravatar account).
Run the following commands:
git config --global user.name 'Your Name'
git config --global user.email ben@domain.com
This will add entries to your ~/.gitconfig file under the [User] section.
Thats it. See me on GitHub here: http://github.com/unilogic
Thanks Tim for the correct way of doing this.
Resource: http://cheat.errtheblog.com/s/git
Tip of the Day: Fixing Page Up and Page Down Keys in Leopard's Terminal.app 1
To expand on my last post about fixing the home and end keys in Terminal here is how to fix the Page Up and Page Down keys.
Follow the directions in my last post, but instead of choosing the end or home keys select the page up and page down keys.
Set action to send string to shell and in the text box copy and paste: \033[6~ for page down, and \033[5~ for page up in the text box under the action pull-down.
If you can't copy and paste, the key sequence goes as the following: ESC [ 6 ~ and ESC [ 5 ~ respectively. Those two key sequences should expand to the above text.
Tip of the Day: Fixing Home and End Keys in Leopard's Terminal.app 2
By default in Terminal.app the home and end scroll the the top of the screen and the end of the screen buffer respectively. To make Terminal act like a normal console (in other words the home key moves the cursor to the beginning of the line, and the end key moved the cursor to the end of the line, etc) do the following:
- Open Terminal
- Open Terminal's preferences
- Goto the Settings Tab
- Goto the Keyboard Tab as shown below

- Select the end key settings
- Change the action setting to send string to shell as below

- In the text box below the action setting, enter the key combination of ctrl-e.
- The text \005 should appear like below

- Click OK
- Select the home key
- Change the action setting to send string to shell
- For this key enter the key combination of ctrl-a
- The text \001 should appear like below

- Click OK and close the preferences.
The end and home keys should now act like a normal console in Terminal. Enjoy!
Resource: http://blog.yiqiang.org/2007/12/fixing-home-and-end-key-for-terminalapp.html
Programming Rails Applications on NetBeans 6.1
Introduction
I have been using NetBeans 6.1 IDE for some time forcing myself to use JRuby because of the issues that NetBeans has with Ruby. I must say my experience thus far has been superior to any NetBeans release to date. That being said I am planning on using this post to list potential to make the core NetBeans 6.X/7.X the best release for Ruby on Rails developers.
Enhancement Requests
I want to preface this section of the post with the fact that I feel NetBeans is a wonderful IDE and has many features that many Java developers benefit from. That being said this is by no means discrediting any of the wonderful advancements they have brought to the Rails IDE arena.
Permissions
Using NetBeans 6.1 without JRuby is just a hassle. The implementation either needs to be dropped or made more seamless.
Gem Management
There needs to be a better quicker way to manage gems. Currently it is a long painful process which is different from what Rails developers are used to. I am a die-hard Mac OS X Rails developer and I am used to opening up the terminal and managing my gems there. I thing the best solution for this is to have a jruby/gem console that opens the terminal with the correct PATH specified and all the gem management can be done right there.
Rake Tasks
Rails developers prefer using their keyboards with shortcuts. We are used to quick editors that have great keyboard support. The editor that comes to mind is TextMate. That being said I feel there must be a better way to run rake tasks and other commands that are run frequently through the command line.
Source Code Management
GIT is the new hotness in the rails world and there needs to be solid support for git in NetBeans. There is not much of a message here except for that git support is a must.
Capistrano Integration
This would make NetBeans a HUGE success. Integration with Capistrano for developers to deploy their application. There could be some sort of collaboration on deployment where you can test each app that is marked for deployment on a local glassfish server and then one of the choices get deployed out to production.
Conclusion
Any of the above enhancement requests are welcome to collaboration and improvement via commands or email. I look forward to your comments.
TOTD: Installing Git on Mac OS X
Introduction
Git has become quite the popular version control system in the rails community. That being said I am announcing that I will stop using ports for my tutorials and install everything from source. There are advantages and disadvantages to this and the main reason is that I am sick of waiting for ports that are outdated.
Requirements
This install is quite easy. All the dependencies required ship with Mac OS X Leopard. That being said lets get started. For this to install successfully you must have the following installed on your computer:
- Apple Developer Tools
Installation
Download the latest package from Git At the time of writing this tutorial the current version is Git 1.5.5.
Below are the directions to completely install the Git version control system.
cd /usr/local/src
curl -O http://kernel.org/pub/software/scm/git/git-1.5.5.tar.bz2
tar -xjf git-1.5.5.tar.bz2
cd git-1.5.5
./configure --prefix=/usr/local
make
sudo make install