def _make_autoenv(self, action):
        """ Generate a suitable env variable for this action.  This is
        dependant on our subcommand hierarchy.  Review the prog setter for
        details. """
        env = ('%s_%s' % (self.prog, action.dest)).upper()
        env = re.sub(self.env_scrub_re, '', env.strip())
        env = re.sub(self.env_flatten_re, '_', env)
        if re.match('^[0-9]', env):
            # Handle leading numbers.
            env = '_%s' % env
        return env
Generate a suitable env variable for this action.  This is
        dependant on our subcommand hierarchy.  Review the prog setter for
        details.