Seems like there should be an existing snippet for this but I couldn't find it.
I want my script to have a few different connect methods, either TCP socket, CGI script,
or run from command line. Is there a well established way for my script to know how
it was invoked and can the "use" instructions be made conditional on the mode
of invocation?