nfdi4plants / ARCitect

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

Long file names fail under Windows #199

Open Freymaurer opened 5 months ago

Freymaurer commented 5 months 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 5 months ago

@eik-dahms @micwij

eik-dahms commented 5 months 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 5 months ago

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

eik-dahms commented 5 months 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

Brilator commented 6 days ago

Just a reminder, that people (esp. on windows) keep running into this issue and the ARCitect cannot handle it. git config --global core.longpaths true. This worked for me.