Jan 12, 2011
Something I am relying on more and more when I am at the end of a coding session and I want to make sure I start right back on what I was working on when I start my next session is #error. With #error turned on it is impossible to compile the project until I have seen my note to myself on what I need to work on next.

Something I am relying on more and more when I am at the end of a coding session and I want to make sure I start right back on what I was working on when I start my next session is #error. With #error turned on it is impossible to compile the project until I have seen my note to myself on what I need to work on next.

Jun 21, 2010

A Calendar about Nothing

A nice site i’ve seen lately to make sure just how on task you are (at least with regards to public Github commits) is called A Calendar about Nothing. Example Calendar from the Github team who you can see work pretty much every day.

What’s a calendar about nothing? It comes from Jerry Seinfeld and is a way to make sure you keep on task and get something you want to get done everyday done, from the article “He told me to get a big wall calendar that has a whole year on one page and hang it on a prominent wall. The next step was to get a big red magic marker.

He said for each day that I do my task of writing, I get to put a big red X over that day. “After a few days you’ll have a chain. Just keep at it and the chain will grow longer every day. You’ll like seeing that chain, especially when you get a few weeks under your belt. Your only job next is to not break the chain.”.”

I know I have some projects I should really be doing some work on them everyday and fall in and out of patterns of working on. I use this technique myself to keep me going on more than just code, learning Japanese and the 2,230 Kanji is a big stress test at times to make sure you spend a little time everyday on them. Once you start this and start to build up a streak you don’t want to break it.

The only bad thing about a calendar about Nothing is that it only tracks public Github commits, for me most of my work at the moment is on private git repos (though I am working to move more and more code to a framework which I plan on open sourcing.) Still regardless of if you use the website for git commits or just to keep you on task at home, this could what you need to get you into the routine of working on what you need to work on everyday.

May 23, 2010

Keep your headers organized

Recently I began to refactor some source code in a big way. I realized that I had 2 classes which mainly dealt with the same thing, but were designed at different points in this apps development. Specifically it went from a single window app to a multi-window app and so for good design and just to eliminate any redundancy I decided to merge them into 1 class.

In doing so I started to organize over my headers and in the process I saw areas where multiple headers could be combined into 1 and got me thinking about the Objective-C class design of several classes within my app. In the end I started to do something like the following for organizing my header files…

#include ThisClass.h

//==CORE DATA=====================
#import ...                     // Core Data Convenience Functions
#import ...                     // Core Data ...
//==VIEW CONTROLLERS==============
#import ...                     // View Controller for ...
#import ...                     // View Controller for ...
#import ...                     // View Controller for ...
//==UTILITY=======================
#import ...                     // Debug Convenience methods...
#import ...                     // ...

It’s up to you how you organize these, but for me having the header files organized into general bins and having a brief description of each class/header made it much easier to get an overview of my headers, look at my header list quickly, find a specific header I am looking for, and think about my class design and areas for improvement.

Apr 29, 2010
A great tool I ran into today is Ingredients via Brandon Walkin on Twitter.

Ingredients is a great standalone Cocoa Documentation browser app. It’s not only functional, but looks great and comes with the ability to search additional sites like Google, Cocoa Builder, CocoaDev & StackOverflow within the app.

Up till now I used a combination of OmniWeb with local bookmarks and it’s search configured for sites like Github, Google Code, Stack Overflow, CocoaDev,etc. While it’s not going to 100% replace that it’s the first app that I feel almost could. I’ve only used it for a few hours but I already love it.

A great tool I ran into today is Ingredients via Brandon Walkin on Twitter.

Ingredients is a great standalone Cocoa Documentation browser app. It’s not only functional, but looks great and comes with the ability to search additional sites like Google, Cocoa Builder, CocoaDev & StackOverflow within the app.

Up till now I used a combination of OmniWeb with local bookmarks and it’s search configured for sites like Github, Google Code, Stack Overflow, CocoaDev,etc. While it’s not going to 100% replace that it’s the first app that I feel almost could. I’ve only used it for a few hours but I already love it.

Apr 18, 2010

Commit Editing with VIM (Keyboard Shortcuts)

On the 365Git blog there is a nice simple post giving the common vim keyboard shortcuts for doing commit messages with

Git defaults to using vim to input a commit message (though you can change the editor easily), if you don’t supply a commit message with your commit. I personally try to keep my commits small and use `git commit -a -m` when possible, but if you need to write a commit message of any significant length these keyboard shortcuts are good to know if you are going to stick with vim.

Apr 15, 2010
Today I am going to do another Tool that was sent to me via one of my Twitter followers, then get back to regular tips.

If you want have an App or tip or link you think belongs here, just @reply to cocoasamurai or email me cocoasamurai [at] gmail.com and let me know it’s for this blog.

One of my twitter followers pointed me at an app called Bwana, which according to the site means Mr or Sir in Swahili. Basically it turns your Webkit browser (except for Google Chrome) into a man page browser. I can easily look man pages up in terminal, but sometimes it’s just faster to be able to quickly skim over a man page for a particular section your looking for, and this tool helps.

All you do is put it in your Applications folder, restart your browser, and then in Safari or OmniWeb (what I use for all my Developer specific browsing when coding) you can type man: and then the manpage you are looking up and it’ll come up in your browser. So you could type man:git and it’ll bring up the git man page in your browser.

Today I am going to do another Tool that was sent to me via one of my Twitter followers, then get back to regular tips.

If you want have an App or tip or link you think belongs here, just @reply to cocoasamurai or email me cocoasamurai [at] gmail.com and let me know it’s for this blog.

One of my twitter followers pointed me at an app called Bwana, which according to the site means Mr or Sir in Swahili. Basically it turns your Webkit browser (except for Google Chrome) into a man page browser. I can easily look man pages up in terminal, but sometimes it’s just faster to be able to quickly skim over a man page for a particular section your looking for, and this tool helps.

All you do is put it in your Applications folder, restart your browser, and then in Safari or OmniWeb (what I use for all my Developer specific browsing when coding) you can type man: and then the manpage you are looking up and it’ll come up in your browser. So you could type man:git and it’ll bring up the git man page in your browser.

Apr 13, 2010
Another great tool I’ve come across lately is Code Pilot
Code Pilot looks like Quicksilver for Xcode. It’s an Xcode plugin that enables you to easily browse your source code files and methods with a keyboard shortcut. Xcode already has this ability to a degree, but its Quick Open feature can only search the prefix of your source code file names, whereas Code Pilot can search for any matching pattern in the source code file name. Once you have found a file/class your looking for you can easily hit Space and search through the methods of a class in the same way you searched through your classes/Files.
I’ve only just begun to play around with this, but it’s already looking like a much better way to navigate around to classes and files in my Xcode Projects.

Another great tool I’ve come across lately is Code Pilot

Code Pilot looks like Quicksilver for Xcode. It’s an Xcode plugin that enables you to easily browse your source code files and methods with a keyboard shortcut. Xcode already has this ability to a degree, but its Quick Open feature can only search the prefix of your source code file names, whereas Code Pilot can search for any matching pattern in the source code file name. Once you have found a file/class your looking for you can easily hit Space and search through the methods of a class in the same way you searched through your classes/Files.

I’ve only just begun to play around with this, but it’s already looking like a much better way to navigate around to classes and files in my Xcode Projects.

Apr 12, 2010
Today’s bit of advise is an app called Concentrate.

Although not a Developer specific tool, I’ve found this invaluable for shutting down distractions like twitter & email so I can just focus. Think of it as automator for productivity. It can change your desktop background (to something less distracting), shut down apps (and even make sure you can’t relaunch them while concentrating) and block distracting websites like Twitter, Facebook, YouTube, Reddit, etc. Once your concentrating period is up you can launch those apps and visit those distracting websites all you want and restore your Desktop wallpaper to what you originally had.

Now I try and go for 25-30 periods of just focusing on coding and then take a 5-10 minute brake and then repeat the cycle. If your going to code you might as well just focus on that and then check your email/twitter after a time of working. For some developers this is an invaluable tool to make sure they stay on track.

Today’s bit of advise is an app called Concentrate.

Although not a Developer specific tool, I’ve found this invaluable for shutting down distractions like twitter & email so I can just focus. Think of it as automator for productivity. It can change your desktop background (to something less distracting), shut down apps (and even make sure you can’t relaunch them while concentrating) and block distracting websites like Twitter, Facebook, YouTube, Reddit, etc. Once your concentrating period is up you can launch those apps and visit those distracting websites all you want and restore your Desktop wallpaper to what you originally had.

Now I try and go for 25-30 periods of just focusing on coding and then take a 5-10 minute brake and then repeat the cycle. If your going to code you might as well just focus on that and then check your email/twitter after a time of working. For some developers this is an invaluable tool to make sure they stay on track.

Apr 5, 2010

Developer Productivity

Think of this as like a 43 folders blog except for developers. Now I am not super crazy about productivity, but I do enjoy hearing tips & tricks from other developers that make me more productive. And here I hope to share with you things that have made me more productive and hope they make you more productive and in that way we all get more done with less frustration, and the world is a better place.

About