NppFTP
NppFTP copied to clipboard
File confusion with Linux servers (case sensitive file system) & Windows clients (case insensitive file systems)
Using NPPFTP on a windows machine to connect to a linux server. The linux server has case sensitive filenames, so Foo.txt and foo.txt are different. The directory tree shows the files correctly, but when you try to open/edit the files they clobber one another.
Steps to reproduce:
- Create two files on the server (Foo.txt & foo.txt) with different content.
- Open one of the remote files (Foo.txt)
- Close Foo.txt and open the other remote file (foo.txt)
- The contents of foo.txt will appear in the editor as Foo.txt. Saving the file will overwrite the original file (Foo.txt) with the contents of the second file (foo.txt).
That's a real corner case, not sure how you can really address that as there is no way you can distinguish between them on Windows. I'm pretty sure that the local file name is used to upload to the server, which causes this issue.
Yeah, I don't know if theres a fix, but it was damn frustrating & did write over my work (thankfully, nothing Important). You could probably remove the old cache files if the user have them open in the editor, and throw an error if theres a real conflict.
I encountered the same issue when I created the file with a lowercase name, then renamed it to capitalize the first letter. Solved by copying the contents, manually deleting the file in the Notepad++ cache directory, then pasting the contents back into a new file with the correct file name.
See #161 for an additional aspect of this issue on opening files with same name if seen case insensitive.
See #56 issue could also happen for folder names
I'm not sure the best way to say this so I'll be blunt: I switched editors over this issue about 8 years ago.
Hope you finally fix it!