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.
Use the pathvalidate package to sanitise collection names in order to use them as collection directory names. We want the collection names to be a part of the collection directory names because the user will see these names when looking for collection SVGs in the QGIS GUI.
Since pathvalidate is not a standard package, version 2.2.2 has been included in the ext_libs directory.
Fixes: #110
The collection directory will now be a combination of the sanitised collection name and the sanitised repository name.
Example:
Animal silhouettes (Alina's Repository)
.An alternative is to use a combination of the santised collection name and a hash.
Example:
Animal silhouettes-33b75e8e0ac1ef736eae109d5d5de0697f4b2174
.If this PR is applied, previously installed collections will have their directories renamed, so the user may have to update QGIS projects that use/include resources from these collections.
What has been done to make the transition smoother for the users:
local_collection_path
inrebuild_collections
(repository_manager.py) - will rename already "installed" collections.