I've seen a lot of people get annoyed with the fact that they have to log out and log back in in order to see any new services they've installed show up in the services menu. It turns out that there is an AppKit function that will dynamically update the services menu without making you log out. But I haven't seen this functionality incorporated into any easy-to-use tool (except several very good projects on Source Forge such as PerlPad. But those require you to be quite technical to use).
To write a small tool to do this is actually very easy: all the code that's required is below:
#include <Foundation/Foundation.h>
#include <AppKit/AppKit.h>
int main (int argc, const char * argv[]) {
NSAutoreleasePool * pool = [[NSAutoreleasePool alloc] init];
NSUpdateDynamicServices();
printf("The services menu has been rebuilt.\n");
printf("You must restart any active applications to see changes.\n");
[pool release];
return 0;
}
Simply make a Foundation Tool Project in Project Builder, paste the code in, and then make sure your project is linked against both Foundation.framework and AppKit.framework and you are good to go. The result is a command-line tool that when run will rebuild the services menu. You'll see the changes right away in newly launched applications. But you won't see the changes in any open applications until you've quit and relaunched them.
Read the rest of the hint for more info on creating the project as well as some comments on how and why to use it...
[robg added detail: I've never built a Project Builder (PB) application before, and I managed to make this work. So here's some added detail which may help other PB newcomers.
Start by launching PB, and select a "Foundation Tool" project (in the "Tool" section) in the Assistant screen. Find a location and assign a name for your project (I used rbldsvcs). When the PB main window opens, in the Source folder in the left pane open the main.m file, copy and paste the above code (replacing whatever is in main.m at that point). Then Control-click on the "External Frameworks and Libraries" folder, and select Add Frameworks. The Foundation.framework was already listed, so I just had to add the AppKit.framework. I then saved the project, and clicked the Hammer icon to build the project.
When the build is done, you can switch to the Terminal and navigate into the project folder you created. You'll find a "build" directory that contains the binary code you just wrote; move this program somewhere on your path, and you can now restart the services menu quite easily:
./rbldsvcs
The services menu has been rebuilt.
You must restart any active applications to see changes.
If I can make this work, almost anyone should be able to do so as well!]
To test this, just drag some .service bundles out of your ~/Library/Services folder, if you have any, or take an application that you know exports some service and make a Stuffed copy of it and delete the original, run the tool, launch another application, and you should not see the entries for the services you've just removed. You can reverse the process to add them back in, all without logging out.
This is useful for people who are changing the keyboard shortcuts for their services menu and want to see those changes without having to log out and log in, for people who are trying to debug which collection of services is conflicting with other services, and for developers in general.
I can also build a GUI version of the tool if the interest is high. (I personally just like using the command-line a lot more and this seemed like the right thing for the command line). But given that the core of the system code is so simple, perhaps someone with more design sense for GUIs can take this on?

