code: def _format_action_invocation(self, action, doubledash="--"):
      if not action.option_strings:
          (metavar,) = self._metavar_formatter(action, action.dest)(1)
          return metavar
  
      else:
          parts = []
  
          # if the Optional doesn't take a value, format is:
          #    -s, --long
          if action.nargs == 0:
              parts.extend(
                  [
                      self._bold(action_str)
                      for action_str in action.option_strings
                  ]
              )
  
          # if the Optional takes a value, format is:
          #    -s ARGS, --long ARGS
          else:
              default = self._underline(action.dest.upper())
              args_string = self._format_args(action, default)
              for option_string in action.option_strings:
                  parts.append(
                      "%s %s" % (self._bold(option_string), args_string)
                  )
  
          return ", ".join(p.replace("--", doubledash) for p in parts)
  
imports: import argparse
  import datetime
  import os
  import re
  import time
  from textwrap import wrap
label_desc: Use image node_id 13 for calling the ManPageFormatter obj's underlying member method code with example usage: obj._format_action_invocation(action, doubledash) and returns: metavar, str