Earlier this week, we shared a hint about applying Finder labels from the keyboard. But that hint, which focused on adding labels to the Finder's toolbar, suffered from a few annoying limitations. One Macworld reader, who asked to remain anonymous, contacted us with a much better solution to the same problem.
This reader's solution uses Automator. Launch Automator, and create a new Service.
Look for the "Services receive selected..." dropdown menu at the upper right, and choose "files or folders."
In the search box at the upper left, type in Label; you'll see Label Finder Items appear in the list. Drag that entry to the right side of the Automator window. From that section, choose which color label you'd like to create a service for. (You'll create multiple services if you want to create keyboard shortcuts for multiple colors.)
Save your service with a descriptive name (e.g, Label in Red). Now, launch the Keyboard preference pane; you can get there by launching System Preferences directly, or you can go to the Automator menu, and then choose Services Preferences from the Services submenu. Either way, make sure that Services is selected on the left pane, and then find your new service in the right pane--it'll be in the Files and Folders section. Hit Return to select the new service's otherwise-invisible keyboard shortcut box, and then type the shortcut you'd like to use (say, Command-Shift-Control-1). While you're there, make sure that your new service's checkbox is checked. Quit System Preferences (and Automator, if you haven't yet), and select anything in the Finder and try your new key command. You may need to select the service once from the contextual menu by Control-clicking (right-clicking) on the file to label, just to make sure that your Mac becomes aware of the newly-created service and its keyboard shortcut.
Now, though, you'll be able to label files and folders without the limitations of our earlier approach--including those that sit on your desktop.