Split output file into multiple partitions (#116)

This commit is contained in:
Alexey Golub
2018-11-03 22:53:20 +02:00
committed by GitHub
parent aa53cecd4e
commit a0359b1e43
13 changed files with 133 additions and 19 deletions

View File

@@ -42,7 +42,7 @@ namespace DiscordChatExporter.Cli.Verbs
}
// Export
exportService.ExportChatLog(chatLog, filePath, Options.ExportFormat);
exportService.ExportChatLog(chatLog, filePath, Options.ExportFormat, Options.PartitionLimit);
// Print result
Console.WriteLine($"Exported chat to [{filePath}]");

View File

@@ -22,6 +22,9 @@ namespace DiscordChatExporter.Cli.Verbs.Options
[Option("before", Default = null, HelpText = "Limit to messages sent before this date.")]
public DateTime? Before { get; set; }
[Option('p', "partition", Default = null, HelpText = "Split output into partitions limited to this number of messages.")]
public int? PartitionLimit { get; set; }
[Option("dateformat", Default = null, HelpText = "Date format used in output.")]
public string DateFormat { get; set; }