Fix CDS extractor support for Windows OS #280
Draft
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
What This PR Contributes
This pull request enhances cross-platform path handling in the CDS tools, with a focus on ensuring compatibility between Unix and Windows environments. The changes update the codebase to use
path.isAbsolute()for path checks, improve detection of direct binary paths for both Windows and POSIX separators, and add comprehensive tests to verify behavior on different platforms. Additionally, development dependencies are updated for improved stability and compatibility.Cross-platform path handling improvements:
startsWith('/')) withpath.isAbsolute()indiagnostics.tsand related test files to ensure correct path resolution on both Unix and Windows systems. [1] [2] [3] [4]compile.tsby checking for both Windows (node_modules\.binThis pull request enhances cross-platform path handling in the CDS tools, with a focus on ensuring compatibility between Unix and Windows environments. The changes update the codebase to usepath.isAbsolute()` for path checks, improve detection of direct binary paths for both Windows and POSIX separators, and add comprehensive tests to verify behavior on different platforms. Additionally, development dependencies are updated for improved stability and compatibility.Cross-platform path handling improvements:
startsWith('/')) withpath.isAbsolute()indiagnostics.tsand related test files to ensure correct path resolution on both Unix and Windows systems. [1] [2] [3] [4]) and POSIX (
node_modules/.bin/) separators, using the platform's native separator for robust compatibility.Testing enhancements:
compile.test.tsanddiagnostics.test.tsto verify correct handling of Windows-style paths, UNC paths, mixed separators, and cross-drive scenarios, ensuring the code behaves as expected on all supported platforms. [1] [2]Dependency updates:
package.json, including ESLint, TypeScript, Prettier, and related plugins, to their latest versions for improved stability and compatibility.Minor code cleanup:
These changes collectively ensure the CDS tools work reliably across different operating systems and improve the maintainability of the codebase.