def _ConfigureGlobalAttributes(self, command): """Configures top level attributes of the generated command. Args: command: The command being generated. """ if self.spec.is_hidden: command = base.Hidden(command) if self.spec.release_tracks: command = base.ReleaseTracks(*self.spec.release_tracks)(command) if not hasattr(command, 'detailed_help'): key_map = { 'description': 'DESCRIPTION', 'examples': 'EXAMPLES', } command.detailed_help = { key_map.get(k, k): v for k, v in self.spec.help_text.items() } command.detailed_help['API REFERENCE'] = ( 'This command uses the *{}/{}* API. The full documentation for this ' 'API can be found at: {}'.format( self.method.collection.api_name, self.method.collection.api_version, self.method.collection.docs_url))
def _ConfigureGlobalAttributes(self, command): """Configures top level attributes of the generated command. Args: command: The command being generated. """ if self.spec.is_hidden: command = base.Hidden(command) if self.spec.release_tracks: command = base.ReleaseTracks(*self.spec.release_tracks)(command) command.detailed_help = self.spec.help_text
def _ConfigureGlobalAttributes(self, command): """Configures top level attributes of the generated command. Args: command: The command being generated. """ if self.spec.is_hidden: command = base.Hidden(command) if self.spec.release_tracks: command = base.ReleaseTracks(*self.spec.release_tracks)(command) command.detailed_help = self.spec.help_text command.detailed_help['API REFERENCE'] = ( 'This command uses the *{}/{}* API. The full documentation for this ' 'API can be found at: {}'.format( self.method.collection.api_name, self.method.collection.api_version, self.method.collection.docs_url))