2010 Development Toolbox
Here is a quick run down of the tools and applications I user pretty much everyday. As of this time I'm doing a lot of frontend work as well as some backend PHP development.
Programming
- Browsers
- Safari - I use it for all my general development
- Firefox - Mostly great for tuning CSS and pixel pushing
- Google Chrome - Great for debugging and performance testing
- Textmate - texteditor
- open in Textmate - utility to put in your Finder that lets you quickly open files in Textmate
- project plugin - better project handling for Textmate
- Versions - Very clean SVN client
- Fluid - great to take web pages you always access and make them their own app.
- JIRA - This is just a great setup, this way JIRA is always a few keystrokes away
- jQuery API - quick and easy access to the jQuery API
- iTerm - better replacement for the built in mac terminal
- vim - best TE in the world (next to Textmate?)
- Sequel Pro - GUI for MySQL
- Charles Web Proxy - for intercepting and viewing http data, also great for testing slow connections to a certain domain
- Reggy - Regular expression sandbox, great for finding out what the hell is going on with a regular expression
- HTTP Client - Great app that let's you play with HTTP, great for testing out backend services
- VMWare Fusion - X-browser testing
- Adobe Photoshop CS5
Utilities
- Caffeine - awesome little app to keep your computer from going to sleep or launch the screensaver. You don't know how much you love caffeine until you actually use it a few times
- Divvy - awesome window management app that helps you resize windows on the fly using hotkeys or your mouse.
- Droplr - terrific app for taking screenshots and sharing them with others
- Spot Color - great little color picker
- VirtualHostX - app to manage all the virtualhosts installed on your system's apache instance
- iStat Menus - bunch of monitors that sit in your menubar and report system status to you. Great for keeping an eye on memory and processor usage
Misc
- Evernote - Great for taking notes throughout the day and also syncs back up with your iphone or mobile device
- Mail.app
- Pandorajam - If you listen to pandora, do your self a favor and download this badass app right now. Simply amazing.
- Grooveshark - think of iTunes, but has any song you can think of. Completely web based.
- Adium - IM client
- Colloquy - IRC client
- Echofon - Twitter client
- Skim - PDF Reader, much better than preview or acrobat reader
Gentoo Linux – Wallpapers
For those of you looking for my Gentoo Wallpapers, they can be found here.
Magento Sidebar Categories
The following will display a list of categories in your store in your right sidebar.
Layout
Alter page.xml so that the default handle's right block contains the following:
<block type="catalog/navigation" name="category.listing" template="catalog/navigation/categories.phtml" />My final right block looks as follows
<block type="core/text_list" name="right" as="right"> <block type="catalog/navigation" name="featured" template="catalog/featured_random.phtml" /> <block type="catalog/navigation" name="category.listing" template="catalog/navigation/categories.phtml" /> </block>
Template
Create the file template/catalog/navigation/categories.phtml and paste in the following
<div class="block block-layered-nav">
<div class="block-title">
<h2>Categories</h2>
</div>
<div class="block-content">
<ul id="nav_category" class="nav_category">
<?php foreach ($this->getStoreCategories(true) as $_category): ?>
<?php echo $this->drawItem($_category) ?>
<?php endforeach ?>
</ul>
</div>
</div>Magento Sidebar Featured Products
This tutorial will explain how to add a featured product to the sidebar. In this example we will add the featured product to the right sidebar. The steps we will follow are as follows.
- Create a new category in the magento admin area to contain our featured products.
- Add the block calls to the XML Layout
- Create the phtml template files to be referenced by the block
Category
Add a new category to your store to contain your featured products. Make it inactive and jot down the id that it is given once saved. Add any products you want to consider featured to this category. Also make sure this category is not a root category.
Layout
Open page.xml and inside your default handle's right block add the following line.
<block type="catalog/navigation" name="featured" template="catalog/featured_random.phtml" />My finished right block looks as follows:
<block type="core/text_list" name="right" as="right"> <block type="catalog/navigation" name="featured" template="catalog/featured_random.phtml" /> <block type="catalog/navigation" name="category.listing" template="catalog/navigation/categories.phtml" /> </block>
Template
Use the following code for featured_random.phtml
<?php /** * Magento * * NOTICE OF LICENSE * * This source file is subject to the Academic Free License (AFL 3.0) * that is bundled with this package in the file LICENSE_AFL.txt. * It is also available through the world-wide-web at this URL: * http://opensource.org/licenses/afl-3.0.php * If you did not receive a copy of the license and are unable to * obtain it through the world-wide-web, please send an email * to license@magentocommerce.com so we can send you a copy immediately. * * DISCLAIMER * * Do not edit or add to this file if you wish to upgrade Magento to newer * versions in the future. If you wish to customize Magento for your * needs please refer to http://www.magentocommerce.com for more information. * * @category design_default * @package Mage * @copyright Copyright (c) 2008 Irubin Consulting Inc. DBA Varien (http://www.varien.com) * @license http://opensource.org/licenses/afl-3.0.php Academic Free License (AFL 3.0) */ ?> <?php $category_id = "25"; // category_id for "Featured Products" $_productCollection = Mage::getResourceModel('catalog/product_collection') ->addAttributeToSelect(array('name', 'price', 'small_image'), 'inner') ->addCategoryFilter(Mage::getModel('catalog/category')->load($category_id)); ?> <?php if($_productCollection->count()): ?> <?php $products = array(); foreach ($_productCollection as $_product) { array_push($products, $_product); } $_product = $products[rand(0,count($products)-1)]; ?> <div class="block block-featured-product"> <div class="block-title"> <h2>Featured Product</h2> </div> <div class="block-content"> <ul id="featured-product-list"> <li class="featured-product"> <h4><?php echo $this->htmlEscape($_product->getName())?></h4> <a href="<?php echo $_product->getProductUrl() ?>" title="<?php echo $this->htmlEscape($this->getImageLabel($_product, 'small_image')) ?>"> <img class="product-image" src="<?php echo $this->helper('catalog/image')->init($_product, 'small_image')->resize(117, 117); ?>" alt="<?php echo $this->htmlEscape($this->getImageLabel($_product, 'small_image')) ?>" title="<?php echo $this->htmlEscape($this->getImageLabel($_product, 'small_image')) ?>" /> </a> <a class="view-item-button" href="<?php echo $_product->getProductUrl() ?>" title="<?php echo $this->htmlEscape($_product->getName()) ?>">View Item</a> </li> </ul> </div> </div> <?php endif; ?>
Resources:
- Elias Interactive - Adapted from Homepage Featured Products
Pragmatic Development
What does it mean to be a pragmatic programmer, or to program pragmatically? Generally speaking, acting pragmatically or being pragmatic means to act practically. Taking things for what they are, don't make things more difficult then they have to be. Take these ideals and apply them to development and you can be a very efficient, very productive, pragmatic programmer.
Andy Hunt and David Thomas have written a terrific book on Pragmatic Programming. They mention many qualities that they have found pragmatic programmers to possess:
- A fast and early adopter - Pragmatic programmers love drinking the newest flavors of the technology coolaid. Playing with a new technology is like getting to play with a new toy. It's fun and represents something new and unknown to be figured out.
- Curious and Inquisitive - Pragmatic programmers are always asking questions. Curious about how and why things work, and what the best way is to solve a problem. The knowledge picked up from these questions almost always becomes more useful in understanding future questions.
- Grounded and Realistic - Pragmatic programmers have a very realistic view on things. They won't forget that the webapp you're building is only a tool for the means, not the end to the means.
- Jack of all Trades - Being able to wear multiple hats makes pragmatic programmers more adaptable but also more valuable. Pragmatic Programmers have the ability to switch from one task to another pretty often, while still being able to claim a master or some.
- Care about their craft - As a pragmatic programmer you have to care about what you are doing if you are to really have an appreciation for what you do. A pragmatic programmer has fun crafting their code and finding elegant, yet practical answers to their problems.
- Always be thinking - A pragmatic programmer tries not to do things out of habit. Always asking "why?", and "how?" helps to always be thinking about your work and why you are doing it the way you are.
The Pragmatic Programmer



