Sketch tab rename consisting only of case changes prevented on case-insensitive file systems #2272
Open
3 tasks done
Labels
topic: code
Related to content of the project itself
type: imperfection
Perceived defect in any part of project
Sketch tab rename consisting only of case changes prevented on case-insensitive file systems
Describe the problem
Windows and macOS (by default) use a case insensitive file system, where from a user perspective there is no functional difference between a file named
foo
andFoo
. However, filename case has a semantic significance and these file systems are "case-preserving", meaning the user has control over case in file names.The files of a sketch are represented by editor tabs in Arduino IDE. The files can be renamed by selecting "Rename" from the editor toolbar context menu.
Arduino IDE's "Rename" feature prohibits a rename operation under the following conditions:
🐛 The user is forced to either resign themselves to a semantically sub-ideal filename or else use an alternative method for renaming the file, which will be inconvenient and might cause other problems.
To reproduce
Set Up
The editor toolbar context menu will open.
The "Name for new file" dialog will open.
foo
in the tab name field in the dialog.A new editor tab named "foo.ino" is added in Arduino IDE.
Demo
The editor toolbar context menu will open.
The "New name for file" dialog will open.
Foo
in the tab name field in the dialog.🐛 An incorrect message is shown in the dialog:
🐛 The "OK" button in the dialog is disabled.
Expected behavior
It is possible to change the case of sketch filenames via the Arduino IDE tab rename feature on all case-preserving file systems.
Arduino IDE version
69b7365
Operating system
Operating system version
Additional context
Originally reported at
Workaround
You will now see that the renamed tab has been duplicated in Arduino IDE (#482). You can restore the IDE from this broken state by performing the following procedure:
A menu will appear on the editor toolbar:
Issue checklist
The text was updated successfully, but these errors were encountered: