nfdi4plants / ARCitect

Cross-plattform app to create and manage ARCs.
9 stars 6 forks source link

Long file names fail under Windows #199

Open Freymaurer opened 2 weeks ago

Freymaurer commented 2 weeks ago

Hey! So for now we added the git terminal view to remove silent fails!

Image

The issue with long file names still persists but is visible!

Image

At the moment, we are undecided on how to approach this. Should we apply settings to git for the user or should we just return a sensible error?

I will close this issue and open a new issue, in which this can be discussed!

Originally posted by @Freymaurer in #183

Freymaurer commented 2 weeks ago

@eik-dahms @micwij

eik-dahms commented 2 weeks ago

I would suggest to do this on start up. Check if windows -> check global config core.longpaths is set to true if not do ->

git config --global core.longpaths true

this should set the config globally for the current user. This should not require additional permissions and will be read by any git command executed by the current user.

this should be working without changing the windows settings, but should be tested anyways.

Alternatively:

kMutagene commented 2 weeks ago

Maybe related? https://learn.microsoft.com/en-us/windows/win32/fileio/naming-a-file?redirectedfrom=MSDN#maximum-path-length-limitation

eik-dahms commented 2 weeks ago

@kMutagene the mentioned "\?\" prefix is what git uses if you turn set the core.longpaths to true.

https://github.com/git/git/commit/0f634d0ca3ce9345affc6e817a8c057b60d87f0f