1
0
mirror of https://github.com/arduino/Arduino.git synced 2025-03-21 12:29:23 +01:00

Correct messages re: sketch/library folder name restrictions

- Specify that library name error is about folder name.
  - We would normally expect "library name" to mean the "fancy name" (as defined by the library.properties name field).
- Specify exactly which characters are allowed.
- State that spaces are prohibited in sketch folder name.
- Remove outdated message about library folders not being allowed to start with a number.
  - This restriction was removed by 4545283ae7.
- State library folder name length restriction.
- Make sketch and library messages consistent with each other.
This commit is contained in:
per1234 2018-06-26 20:13:22 -07:00 committed by Cristian Maglie
parent 677e0508d4
commit 19bfd2ada9
2 changed files with 5 additions and 4 deletions

View File

@ -846,8 +846,9 @@ public class SketchController {
if (!newName.equals(origName)) {
String msg =
tr("The sketch name had to be modified. Sketch names can only consist\n" +
"of ASCII characters and numbers and be less than 64 characters long.");
tr("The sketch name had to be modified.\n" +
"Sketch names must start with a letter or number, followed by letters,\n" +
"numbers, dashes, dots and underscores. Maximum length is 63 characters.");
System.out.println(msg);
}
return newName;

View File

@ -178,8 +178,8 @@ public class LibrariesIndexer {
badLibNotified.add(subfolderName);
String mess = I18n.format(tr("The library \"{0}\" cannot be used.\n"
+ "Library names must contain only basic letters and numbers.\n"
+ "(ASCII only and no spaces, and it cannot start with a number)"),
+ "Library folder names must start with a letter or number, followed by letters,\n"
+ "numbers, dashes, dots and underscores. Maximum length is 63 characters."),
subfolderName);
BaseNoGui.showMessage(tr("Ignoring bad library name"), mess);
}