Skip to content

Move common completion methods to CompletionHelpers class #25138

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Conversation

ArmaanMcleod
Copy link
Contributor

@ArmaanMcleod ArmaanMcleod commented Mar 7, 2025

PR Summary

Moved common completion methods from CompletionCompleters to CompletionHelpers class.

Methods:

  • GetMatchingResults
  • HandleDoubleAndSingleQuote
  • CompletionRequiresQuotes

Also changed all the parts of the code which use these methods to reference the helpers static class.

PR Context

These methods can then be used in a public API.

PR Checklist

@ArmaanMcleod
Copy link
Contributor Author

@iSazonov So just moved code and included the quote method. Is this acceptable to get merged?

@iSazonov
Copy link
Collaborator

iSazonov commented Mar 7, 2025

Since QuoteCompletionText is new method it should be in another PR with tests.

@ArmaanMcleod
Copy link
Contributor Author

Since QuoteCompletionText is new method it should be in another PR with tests.

@iSazonov done. I will add that method in a separate PR after this new class is merged 🙂

@iSazonov iSazonov added the CL-CodeCleanup Indicates that a PR should be marked as a Code Cleanup change in the Change Log label Mar 8, 2025
@iSazonov

This comment was marked as outdated.

This comment was marked as outdated.

@iSazonov iSazonov self-assigned this Mar 8, 2025
@iSazonov iSazonov merged commit ca96c2c into PowerShell:master Mar 10, 2025
39 of 41 checks passed
Copy link
Contributor

microsoft-github-policy-service bot commented Mar 10, 2025

📣 Hey @ArmaanMcleod, how did we do? We would love to hear your feedback with the link below! 🗣️

🔗 https://aka.ms/PSRepoFeedback

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CL-CodeCleanup Indicates that a PR should be marked as a Code Cleanup change in the Change Log
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants