Skip to content

Commit 65e7d38

Browse files
committed
Default intelligent search results to checked and pass sub search flag
- while generating commit message, in unstaged search, even though all files are selected we get error for intelligent: 'no files selected' └── apps └── editor └── src ├── commands │ └── generate-commit-message-commands │ ├── actions │ │ ├── get-prompt-data.ts │ │ └── run-generate-action.ts │ ├── generate-commit-message-commands.ts │ ├── index.ts │ └── utils │ ├── build-commit-message-prompt.ts │ ├── generate-commit-message-with-api.ts │ ├── get-commit-message-config.ts │ └── strip-wrapping-quotes.ts ├── features │ └── search-files │ ├── index.ts │ ├── search-files.ts │ ├── search-modes │ │ ├── perform-intelligent-search-mode.ts │ │ ├── perform-keywords-search-mode.ts │ │ └── perform-phrase-search-mode.ts │ └── utils │ ├── analyze-files.ts │ ├── check-matches-condition.ts │ ├── create-search-regex.ts │ ├── prompt-for-config.ts │ ├── prompt-for-intelligent-search-results.ts │ ├── prompt-for-keywords-match-mode.ts │ ├── prompt-for-keywords-target.ts │ ├── prompt-for-search-mode.ts │ ├── prompt-for-search-results.ts │ ├── prompt-for-search-term.ts │ ├── prompt-for-shrink-mode.ts │ ├── search-files-by-intelligent.ts │ ├── search-files-by-keywords.ts │ ├── search-files-by-phrase.ts │ ├── show-search-results-quick-pick.ts │ └── shrink-file │ ├── index.ts │ ├── languages │ │ ├── c-style.ts │ │ ├── css.ts │ │ ├── html.ts │ │ ├── jsx.ts │ │ ├── python.ts │ │ ├── ruby.ts │ │ └── sql.ts │ └── shrink-file.ts ├── i18n │ └── translations │ └── commands │ └── search-files-command.ts └── utils └── git-repository-utils.ts
1 parent 3c5cc57 commit 65e7d38

2 files changed

Lines changed: 3 additions & 2 deletions

File tree

‎apps/editor/src/features/search-files/utils/prompt-for-intelligent-search-results.ts‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ export const prompt_for_intelligent_search_results = async (params: {
6363
const base_title = t('feature.search-files.results.intelligent')
6464

6565
return (await show_search_results_quick_pick({
66-
matched_items: unique_paths.map((path) => ({ path })),
66+
matched_items: unique_paths.map((path) => ({ path, checked: true })),
6767
unmatched_selected_paths: unmatched_selected_files,
6868
workspace_provider: params.workspace_provider,
6969
title: base_title,

‎apps/editor/src/utils/git-repository-utils.ts‎

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -536,7 +536,8 @@ export const prepare_staged_changes = async (params: {
536536
workspace_provider: params.workspace_provider,
537537
extension_context: params.extension_context,
538538
websocket_manager: params.websocket_manager,
539-
show_back_button: true
539+
show_back_button: true,
540+
is_sub_search: true
540541
})
541542

542543
if (search_result === 'back') {

0 commit comments

Comments
 (0)