Replaced the unused variable 'res' with a discard operator in the PartialResult call to enhance code clarity and maintainability by explicitly indicating the result is not used.
Signed-off-by: Ivandro Jao <Ivandrofly@gmail.com>
Encapsulate VoskRecognizer instantiation within a using statement to guarantee resource disposal. This change improves memory management and aligns with best practices for resource handling. Also, maintain the existing logic structure for audio file processing.
Signed-off-by: Ivandro Jao <Ivandrofly@gmail.com>
Moved the method `IsDirectoryWritable` from `WhisperAudioToText` to `FileUtil` for better code reuse and maintainability. Adjusted references in `WhisperAudioToText` and `VoskAudioToText` accordingly.
Signed-off-by: Ivandro Jao <Ivandrofly@gmail.com>
Enhanced the `DeleteFileAssociationViaRegistry` method to also delete the default registry value associated with the file extension if it matches the given application extension. This ensures a more thorough cleanup of file type associations in the registry.
Signed-off-by: Ivandro Jao <Ivandrofly@gmail.com>
Replace the verbose subtitle file type descriptions with shorter, more concise names. This enhances readability and consistency across the codebase by focusing on the essential part of each description.
Signed-off-by: Ivandro Jao <Ivandrofly@gmail.com>
Updated InterjectionsRepository to check if the dictionary directory exists before attempting to save files. If the directory does not exist, it will now be created automatically. This change prevents potential errors during file saving operations.
Signed-off-by: Ivandro Jao <Ivandrofly@gmail.com>
This change merges several separate ItemGroup sections in the Test.csproj file into fewer ones. It improves the structure and readability of the project file without altering its functionality. This will make future updates to the project file simpler and more efficient.
Signed-off-by: Ivandro Jao <Ivandrofly@gmail.com>
The MSTest.Sdk package version entry was redundant since it is not being used in the project. This cleanup helps to simplify the package management and reduce potential confusion.
Signed-off-by: Ivandro Jao <Ivandrofly@gmail.com>
Consolidate MSTest package versions for simplicity and to avoid conflicts. Removed individual MSTest related references from the project file and centralized the version management in Directory.Packages.props.
Signed-off-by: Ivandro Jao <Ivandrofly@gmail.com>
Re-enabling the MSTest.TestAdapter package reference allows the project to use MSTest framework adapters, ensuring it can run and discover MSTest tests correctly. This change is essential for maintaining compatibility with expected test structures and execution.
Signed-off-by: Ivandro Jao <Ivandrofly@gmail.com>
Deleted commented-out import statements that are no longer needed. This cleanup helps maintain code clarity and reduces confusion about dependencies.
Signed-off-by: Ivandro Jao <Ivandrofly@gmail.com>
Replaced deprecated MSTest.TestAdapter with new MSTest packages and added necessary analyzer configurations. Also included version management for the Microsoft.NET.Test.Sdk and various MSTest packages in Directory.Packages.props to ensure uniformity across the project.
Signed-off-by: Ivandro Jao <Ivandrofly@gmail.com>
Converted Test.csproj to SDK-style format for modern .NET framework targeting and project simplification. Added MSTest.TestAdapter and MSTest.TestFramework package references and their versions to Directory.Packages.props.
Signed-off-by: Ivandro Jao <Ivandrofly@gmail.com>
Removed unnecessary entries for /src/TestResults/, NuGet files, and package directories. Also added .idea/ for JetBrains Rider configuration files. This ensures the .gitignore file is more organized and easier to maintain.
Signed-off-by: Ivandro Jao <Ivandrofly@gmail.com>