mirror of
https://github.com/osukey/osukey.git
synced 2025-07-02 16:59:53 +09:00
Migrate custom tournament client assets to uppercased directories
It has transpired that on filename-case-sensitive filesystems, the tournament client does not consistently handle custom asset paths. Videos and mods could only be looked up from `videos` and `mods` directories (lowercase), while flags could only be looked up from the `Flags` directory (uppercase). A complicating circumstance is that default country flags, coming from osu-resources, also depend on the flag lookup being uppercased. To attempt to clean up the handling as much as it appears to be possible, automatically move user-supplied lowercase directories to uppercase.
This commit is contained in:
@ -87,9 +87,9 @@ namespace osu.Game.Tournament.Tests.NonVisual
|
||||
// Recreate the old setup that uses "tournament" as the base path.
|
||||
string oldPath = Path.Combine(osuRoot, "tournament");
|
||||
|
||||
string videosPath = Path.Combine(oldPath, "videos");
|
||||
string modsPath = Path.Combine(oldPath, "mods");
|
||||
string flagsPath = Path.Combine(oldPath, "flags");
|
||||
string videosPath = Path.Combine(oldPath, "Videos");
|
||||
string modsPath = Path.Combine(oldPath, "Mods");
|
||||
string flagsPath = Path.Combine(oldPath, "Flags");
|
||||
|
||||
Directory.CreateDirectory(videosPath);
|
||||
Directory.CreateDirectory(modsPath);
|
||||
@ -123,9 +123,9 @@ namespace osu.Game.Tournament.Tests.NonVisual
|
||||
|
||||
string migratedPath = Path.Combine(host.Storage.GetFullPath("."), "tournaments", "default");
|
||||
|
||||
videosPath = Path.Combine(migratedPath, "videos");
|
||||
modsPath = Path.Combine(migratedPath, "mods");
|
||||
flagsPath = Path.Combine(migratedPath, "flags");
|
||||
videosPath = Path.Combine(migratedPath, "Videos");
|
||||
modsPath = Path.Combine(migratedPath, "Mods");
|
||||
flagsPath = Path.Combine(migratedPath, "Flags");
|
||||
|
||||
videoFile = Path.Combine(videosPath, "video.mp4");
|
||||
modFile = Path.Combine(modsPath, "mod.png");
|
||||
|
Reference in New Issue
Block a user