chat-downloader icon indicating copy to clipboard operation
chat-downloader copied to clipboard

[QUESTION] What the format argument should be like?

Open teadrinker2015 opened this issue 2 years ago • 1 comments

I can't find the details in docs. It just says:

Format Arguments:
  --format FORMAT       Specify how messages should be formatted for printing,
                        defaults to the site's default value
  --format_file FORMAT_FILE
                        Specify the path of the format file to choose formats
                        from, defaults to None

I have a little knownledge about basic python and CLI

teadrinker2015 avatar May 17 '22 20:05 teadrinker2015

The FORMAT in the --format option is referring to the name of format definitions in the format file, which can be specified by the user using the --format_file option. If the format file is not specified by the user, the default format file will be used, and you can check the content of it here: https://github.com/xenova/chat-downloader/blob/master/chat_downloader/formatting/custom_formats.json

For example, if you want the time in the output looks like 00:00 AM, you can use --format 12_hour, and the 12_hour format specified in the default format file will be applied.

mikelei8291 avatar May 19 '22 04:05 mikelei8291