Skip to content
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

feat(vscode): add at feature with AT file implementation in VSCode #3602

Open
wants to merge 5 commits into
base: main
Choose a base branch
from

Conversation

Sma1lboy
Copy link
Collaborator

@Sma1lboy Sma1lboy commented Dec 20, 2024

not git repo

image

in git repo

image

@Sma1lboy Sma1lboy force-pushed the feat-at-function-vscode branch from 5244117 to ccad4a3 Compare January 6, 2025 06:28
@Sma1lboy Sma1lboy changed the title feat(vscode): add at functions implementation in vscode feat(vscode): add at feature with AT file implementation in VSCode Jan 6, 2025
clients/vscode/src/chat/utils.ts Outdated Show resolved Hide resolved
clients/vscode/src/chat/utils.ts Outdated Show resolved Hide resolved
clients/vscode/src/chat/webview.ts Outdated Show resolved Hide resolved
clients/vscode/src/chat/webview.ts Outdated Show resolved Hide resolved
.map((tab) => uriToListFileItem(tab.uri, this.gitProvider));
}

const globPattern = `**/${query}*`;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should we validate the query string before injecting it into the glob pattern to ensure **/${query}* is safe? For example, what if the query string contains * or other special characters?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Now that I have applied escapeGlobPattern to the query to prevent pattern matching, there is an issue where I cannot search for a file named *testfile.txt using the query *.

clients/vscode/src/chat/webview.ts Outdated Show resolved Hide resolved
clients/vscode/src/chat/webview.ts Outdated Show resolved Hide resolved
@Sma1lboy Sma1lboy requested a review from icycodes January 6, 2025 21:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants