def _processCmdLineArgs(self):
        try:
            self._opts, self._args = getopt.getopt(
                self._cmdLineArgs, 'h', ['help',
                                            'env',
                                            'pickle=',
                                            ])

        except getopt.GetoptError, v:
            # print help information and exit:
            print(v)
            print(self.usage())
            sys.exit(2)
        
        for o, a in self._opts:
            if o in ('-h', '--help'):
                print(self.usage())
                sys.exit()
            if o == '--env':
                self._template.searchList().insert(0, os.environ)
            if o == '--pickle':
                if a == '-':
                    unpickled = load(sys.stdin)
                    self._template.searchList().insert(0, unpickled)
                else:
                    f = open(a)
                    unpickled = load(f)
                    f.close()
                    self._template.searchList().insert(0, unpickled)
dataset/ETHPy150Open binhex/moviegrabber/lib/site-packages/Cheetah/TemplateCmdLineIface.py/CmdLineIface._processCmdLineArgs/original