From 6de20e93e70c7d7d983be2b3c5762989c88fb741 Mon Sep 17 00:00:00 2001 From: Christopher Date: Wed, 21 Jun 2023 13:14:31 -0400 Subject: [PATCH] fix(formatting): Files now formatted like it was previously when passed through --- extension.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/extension.js b/extension.js index a801838..366328b 100644 --- a/extension.js +++ b/extension.js @@ -104,7 +104,8 @@ const openGPTContextPanelCommand = vscode.commands.registerCommand('extension.op const document = vscode.workspace.textDocuments.find(doc => doc.uri.fsPath === file.uri.fsPath); if (document) { const lines = document.getText().split('\n'); - return `${file.uri.fsPath}\n${lines.join('\n')}`; + const formattedLines = lines.map(line => `\t${line}`).join('\n'); + return `${file.uri.fsPath}:\n\`\`\`\n${formattedLines}\n\`\`\``; } return ''; })