Regarding file/directory name case

Post about your mods, learn about OpenMW mod compatibility, check for problematic mods, discuss issues, and give us feedback about your experience with modded OpenMW.
Post Reply
Antsan
Posts: 47
Joined: 13 Mar 2014, 11:15

Regarding file/directory name case

Post by Antsan »

Not sure whether this is the right board, but I also wouldn't know where else to ask.

I just wasted a few days installing mods on Linux, and now I noticed that some of the mod installations I tried to do per hand (you know, copying folders into a common mod folder to overwrite files and so on) failed because the mods themselves used inconsistent casing for their folder and file names.
So now I looked for a script to just downcase all files and folders in a given foldertree, found something and am wondering whether normalizing all mods I download that way would lead to any problems. But since OpenMW cannot rely on file name case being consistent, this shouldn't be a problem, right?
User avatar
AnyOldName3
Posts: 2668
Joined: 26 Nov 2015, 03:25

Re: Regarding file/directory name case

Post by AnyOldName3 »

Don't install more than one mod to one directory. This exact situation is one of the main reasons we have the virtual/multiple data directory system in the first place. If you have one mod per directory, provided you've not put OpenMW into strict filesystem mode (which doesn't work with Morrowind anyway), it'll let FILENAME from a high-priority mod override filename from a low-priority mod, just like the mods expect.
User avatar
wazabear
Posts: 96
Joined: 13 May 2020, 19:31
Gitlab profile: https://gitlab.com/glassmancody.info

Re: Regarding file/directory name case

Post by wazabear »

You should just start over and use the multiple data paths or a dedicated mod manager. Here is a pretty thorough overview of all the techniques https://modding-openmw.com/getting-star ... aging-mods. My personal preference, even on linux, is MO2 under wine with the mo2->OpenMW plugin.

You probably have subfolders and files with slightly different cases, there is no sane way to reverse what you've done.
Antsan
Posts: 47
Joined: 13 Mar 2014, 11:15

Re: Regarding file/directory name case

Post by Antsan »

So you suggest I register the right subdirectories of mods with BAIN installers separately. Wouldn't have thought of doing it that way.
I still keep single mods in their separate directories but I kinda like having all the things that are supposed to be one mod as one coherent unit.

I've already started over. I probably could've salvaged the stuff I'd already done by looking at c-times while normalizing, since I copied everything at least once upon installation, in the correct order for overwriting.
Now I unpack, normalize the resulting directory tree, then overwrite (inside the same mod, not the standard data directory). I feel like keeping all the options for different files, many of which will be overwritten by the same mod, is a waste of space.
User avatar
AnyOldName3
Posts: 2668
Joined: 26 Nov 2015, 03:25

Re: Regarding file/directory name case

Post by AnyOldName3 »

You don't have to have multiple data directories for different parts of the same mod if you don't want to do it that way. It's less likely that that will cause you problems (as a given mod author probably isn't switching case between different versions of the same directory they made), and if it does, it's easier to find and fix them.
Antsan
Posts: 47
Joined: 13 Mar 2014, 11:15

Re: Regarding file/directory name case

Post by Antsan »

Yeah nah, I only merged directories of the same mod ever and I still got that problem. It's really astonishing how many mod authors seem to switch between different cases for their directory names.
And it's not easier to find and fix them – after the fact it's still not immediately obvious which of two file versions to use. Again, you can check the time the file was last touched on your filesystem, but that's not necessarily easy to figure out if you got a few hundred duplicated files.

I'm using portmod now, though, so it's moot.
User avatar
Mantar
Posts: 38
Joined: 17 Jul 2020, 23:32

Re: Regarding file/directory name case

Post by Mantar »

I guess you could run a touch over all the files in the new directory to update their time stamps before merging it in.

Code: Select all

find ./directoryname/ -exec touch {} ;
Cammera
Posts: 19
Joined: 08 Oct 2017, 22:35

Re: Regarding file/directory name case

Post by Cammera »

Different namecase fucks you over even if you use multiple directories, yes.
I recomend running convmv on all data directories.

Code: Select all

convmv --replace -r --lower --notest -f utf8 .
works for me.
Post Reply