n8n-nodes-github-copilot 1.1.2 → 1.1.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -255,10 +255,12 @@ class GitHubCopilot {
255
255
  if (language !== 'other') {
256
256
  fullPrompt = `[${language}] ${fullPrompt}`;
257
257
  }
258
- command = `/usr/bin/gh copilot suggest "${fullPrompt}"`;
258
+ const escapedSuggestPrompt = fullPrompt.replace(/'/g, `'"'"'`);
259
+ command = `/usr/bin/gh copilot suggest '${escapedSuggestPrompt}'`;
259
260
  break;
260
261
  case 'explain':
261
- command = `/usr/bin/gh copilot explain "${fullPrompt}"`;
262
+ const escapedExplainPrompt = fullPrompt.replace(/'/g, `'"'"'`);
263
+ command = `/usr/bin/gh copilot explain '${escapedExplainPrompt}'`;
262
264
  break;
263
265
  case 'shell':
264
266
  const commandType = this.getNodeParameter('commandType', i);
@@ -279,7 +281,8 @@ class GitHubCopilot {
279
281
  default:
280
282
  shellPrompt = fullPrompt;
281
283
  }
282
- command = `/usr/bin/gh copilot suggest "${shellPrompt}" --type shell`;
284
+ const escapedShellPrompt = shellPrompt.replace(/'/g, `'"'"'`);
285
+ command = `/usr/bin/gh copilot suggest '${escapedShellPrompt}' --type shell`;
283
286
  break;
284
287
  default:
285
288
  throw new n8n_workflow_1.NodeOperationError(this.getNode(), `Unknown operation: ${operation}`);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "n8n-nodes-github-copilot",
3
- "version": "1.1.2",
3
+ "version": "1.1.3",
4
4
  "description": "n8n community node for GitHub Copilot CLI integration",
5
5
  "license": "MIT",
6
6
  "homepage": "https://github.com/sufficit/n8n-nodes-github-copilot",