PPROLint

Saving and leaving

Save a rule, fix the problems that block saving, change and revert built-in rules, delete your rules.

The footer of the editor says where the rule is saved and holds its buttons.

The footer of a custom rule: Saved in max-clip-speed.rule.json. Texts are edited in English; other languages keep their own. Delete rule, Cancel, Save

Save

Save writes the rule to your rules folder, closes the editor and reloads the rules: the change applies from the next check, and the panel confirms with Rule saved.

Save is disabled while:

  • the rule has problems;
  • nothing has changed since you opened the rule.
You are editingSave writes
a new rulea new file, <id>.rule.json.
one of your rulesits own file, whatever its name.
a built-in ruleyour copy, <id>.rule.json, which replaces the built-in rule.

Problems

The editor checks the rule a moment after every change. Each problem shows twice: in the list under the header, and under the control at fault, in red.

3 problems to fix before saving: data.maxSpeed, checks[0].condition.all[1].value.field and checks[0].message.en_US name the unknown field options.maxSpeed
The same problem under the value of the condition, in red: Unknown field options.maxSpeed. Declared options: limit.

The list gives the place of each problem in the rule:

PlaceMeans
name.en_USthe rule's name, in English
options.maxSpeed.defaultthe default of the option maxSpeed
checks[0].conditionthe condition of the first check (checks[1] is the second)
checks[0].condition.all[1]the second condition of the first check's All group
checks[0].message.fr_FRthe message of the first check, in French
data.speedthe diagnostic data entry speed

Common problems:

ProblemFix
Must be a non-empty string.Fill in the name, the description or the message.
Must be a non-empty array… on checksAdd a check.
Unknown field "…"The field is not in the check's scope, or names an option that does not exist (renamed or removed). Pick another field.
A rule with id "…" already exists.Choose another id for the new rule.
Must be a number, like the field it is compared with.The value does not fit the field's type.

Leave without saving

Cancel, or ‹ Rules in the header, leaves the editor. If you changed something, PPROLint asks first:

A dialog: Discard changes? Your changes to Fast clips! have not been saved. Cancel, Discard

Discard drops your changes; Cancel goes back to the editor.

Change a built-in rule

A built-in rule opens in the editor like any other. Change its options, severity, condition or messages, then save: the editor writes your copy, <id>.rule.json, in your rules folder. The footer says so before you save:

The editor on the built-in Tiny clips rule; the footer says Saving creates no-tiny-clips.rule.json in your rules folder. It replaces the built-in rule until you revert.

From then on, your copy runs instead of the built-in rule, and the Rules settings mark it Modified built-in rule. Updates of PPROLint never overwrite it.

Revert a built-in rule

Open your copy and click Revert to built-in.

The footer of a modified built-in rule: Saved in scale-range.rule.json, which replaces the built-in rule. Revert to built-in, Cancel, Save

PPROLint asks to confirm, then deletes your file: the built-in rule runs again.

A dialog: Revert to the built-in rule? scale-range.rule.json will be deleted and the built-in rule Scale range will run again. Cancel, Revert to built-in

Delete a rule

Open one of your rules and click Delete rule. PPROLint asks to confirm, then deletes its file.

A dialog: Delete this rule? max-clip-speed.rule.json will be deleted. Cancel, Delete rule

To stop a rule without deleting it, turn it off in the Rules settings instead. Built-in rules cannot be deleted, only turned off.

The saved file

The editor writes a tidy rule file: defaults are left out, and texts with English only are plain strings. You can open it in a text editor, change it and click Reload rules, then open it in the editor again. See Rule files.

On this page