Skip to main content

Module transfer

Module transfer 

Source
Expand description

Settings export and import, in the Settings app: General › Advanced holds “Export settings…” and “Import settings…”, each a wizard of the wizard kit, and both are commands an agent or a test runs alone.

  • Export (settings.export): the settings the person changed (the app value scope), or a library’s or workspace’s values (layer), every setting or those of one scope or section (place); with the person’s shortcuts (shortcuts) and the settings custom pages edit (pages, on by default). A sensitive setting (Descriptor::sensitive) is never written: it is listed under leftOut. The file is the settings-export document (egui_pop_model::admin::transfer). dryRun answers the document without writing it.
  • Import (settings.import): reads a file (file, or the document itself as document), judges each value against the setting declared here (a change, the same value, unknown, obsolete, invalid, sensitive; transfer::plan), and applies the changes chosen (keys; null: every change) into a value scope (scope, app by default) as one undo step of the settings’ history (Ctrl+Z in the Settings app). A value of the wrong type or out of range is never applied: it is skipped with its reason. dryRun (and the read-only settings.importPreview) answer the plan without applying it. settings.undoImport takes the last import back, a library’s or workspace’s layer and the shortcuts included.
  • Obsolete settings: an application names the settings it retired (Admin::obsolete), so an old file’s values for them are flagged, not applied.

Structs§

Selection
What an export takes.

Constants§

CMD_EXPORT
Writes the chosen settings to a file.
CMD_IMPORT
Reads a settings file and applies the changes chosen (or, dryRun, says what it would do).
CMD_IMPORT_PREVIEW
What an import would do: read-only, for the import wizard’s table.
CMD_UNDO_IMPORT
Takes the last import back.
EXPORT_WIZARD
The export wizard’s id.
IMPORT_WIZARD
The import wizard’s id.

Functions§

read_file
Reads a settings file from disk.