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

SearchInDirectoryRecursive returns 1 file instead of multiple #223

Closed
T5ive opened this issue Jul 5, 2023 · 2 comments · Fixed by #225
Closed

SearchInDirectoryRecursive returns 1 file instead of multiple #223

T5ive opened this issue Jul 5, 2023 · 2 comments · Fixed by #225

Comments

@T5ive
Copy link

T5ive commented Jul 5, 2023

Issue: The code that provided searches for files in a specified directory and its subdirectories based on a given pattern. However, the code only returns the first matched file it encounters, rather than all files that match the pattern.

From code: Multiple files should be returned

var files = SearchFilesInDirectory(baseDirectory, searchFileName, excludeDirectories).ToArray();

Logs:

[2023-05-12 22:38:28.403 +07:00 [DBG] MultiFileFinderStep Input [excludeDirectories]:
2023-05-12 22:38:28.404 +07:00 [DBG] MultiFileFinderStep Input [SearchFileName]: '*.json'
2023-05-12 22:38:28.404 +07:00 [DBG] MultiFileFinderStep Output [files]: Found files count: 1, stored in parameter: 'MultiFilesFinderResult']

logs20230512.txt

Step

  1. Create a WebApp with ABP-Framework
  2. Use AbpHelper to generate CRUD

OS: Windows10 22H2


The initial solution that I have worked with return multiple files instead of a single file in the directory search process by storing the results in a collection and return the collection at the end

@blackWins
Copy link
Contributor

Is there any problem with generator localization files

@T5ive
Copy link
Author

T5ive commented Jul 6, 2023

the problem is there only generate from first detected of .json (localize file)

btw a first file generated works fine

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 a pull request may close this issue.

2 participants