Fix curl export with multi-line body

This commit is contained in:
Gregory Schier
2024-05-14 00:05:54 -07:00
parent 8de917ea5e
commit 0542f1ebea
3 changed files with 42 additions and 1 deletions

View File

@@ -52,7 +52,7 @@ export function pluginHookImport(rawData: string) {
// Replace non-escaped newlines with semicolons to make parsing easier
// NOTE: This is really slow in debug build but fast in release mode
const normalizedData = rawData.replace(/([^\\])\n/g, '$1; ');
const normalizedData = rawData.replace(/\ncurl/g, '; curl');
let currentCommand: ParseEntry[] = [];