Skip to content
This repository has been archived by the owner on Jun 9, 2023. It is now read-only.

Path separator issue and StringUtils optimization #9

Merged
merged 2 commits into from
Jan 16, 2023

Conversation

kasperstyre
Copy link

In the current version of the tool, any feature that uses Path.PathSeparator in some way fails to run on my machine. The reason for this is that this field is used to separate multiple paths, not the directories in a single path. On my Windows 11 PC, the value evaluates to ";".

The Path.DirectorySeperatorChar would be more suitable to use, as that field evaluates to "" on Windows, and "/" on UNIX like systems.

For StringUtils, I have rewritten some of the methods to allow an arbitrary amount of parameters without having to write a new method for each different amount.

The most important part for me is the path separator changes, as that fix is required to make the tool run on my system, so if the StringUtil changes are not wanted, feel free to discard those changes.

Copy link
Owner

@MintLily MintLily left a comment

Choose a reason for hiding this comment

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

You know, with my version 3 rewrite, they were 100% supposed to be Path.DirectorySeperatorChars that would be my bad. And thanks for that. The StringUtils seems better overall anyway (compared to my drunken code).

@MintLily MintLily merged commit bc9f873 into MintLily:main Jan 16, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants