def help_handler(docpie, flag):
        """Default help(`--help`, `-h`) handler. print help string and exit.

        when help = 'short_brief', flag startswith `--` will print
        the full `doc`, `-` for "Usage" section and "Option" section only.
        when help = 'short_brief_notice', flag startswith `--` will print
        the full `doc`, `-` for "Usage" section and "Option" section only,
        with a message.
        "Use `--help` to see the full help messsage" in the end

        otherwith(default), print the full `doc`
        """
        help_type = docpie.help
        helpstyle = docpie.helpstyle
        if helpstyle == 'python':
            doc = Docpie.help_style_python(docpie.doc)
        elif helpstyle == 'dedent':
            doc = Docpie.help_style_dedent(docpie.doc)
        # elif help_style == 'raw':
        #     doc = Docpie.help_style_raw(docpie.doc)
        else:
            doc = docpie.doc

        if help_type == 'short_brief':
            if flag.startswith('--'):
                print(doc)
            else:
                print(docpie.usage_text.rstrip())
                option_sections = docpie.option_sections
                if option_sections:
                    print('')
                    print('\n'.join(option_sections.values()))
        elif help_type == 'short_brief_notice':
            if flag.startswith('--'):
                sys.stdout.write(doc)
            else:
                print(docpie.usage_text)
                option_sections = docpie.option_sections
                if option_sections:
                    print('')
                    print('\n'.join(option_sections.values()).rstrip())
                print('')
                print('Use `--help` to see the full help messsage.')
        else:
            sys.stdout.write(doc)
        sys.exit()