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

Allow :NEEDS to check against subdirectories #117

Merged
merged 3 commits into from Apr 22, 2018
Merged

Allow :NEEDS to check against subdirectories #117

merged 3 commits into from Apr 22, 2018

Conversation

blowfishpro
Copy link
Collaborator

If some component of a :NEEDS block has a slash in it (and it doesn't already exist in the mod list), it will attempt to match against subdirectories of GameData

  • :BEFORE, and :AFTER do not consider this logic
  • Comparison is case-sensitive
  • Leading/trailing slashes will be dropped but will be considered when deciding whether to check this as a path
  • Multiple slashes together are treated as a single slash
  • PluginData directories are excluded
  • It checks against KSP's in-memory game database tree rather than what's physically there

Resolves #108

If the needs string contains a / it will check for a directory with that
path in GameData.  Notes:

* PluginData folders are excluded
* Leading and trailing slashes are allowed
* Multiple slashes together will be treated as a single slash
* Comaprison is case sensitive
@sarbian sarbian merged commit 8d1c771 into master Apr 22, 2018
@blowfishpro blowfishpro deleted the NeedsPath branch April 22, 2018 18:30
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 this pull request may close these issues.

None yet

2 participants