matlab-migrate-settings

Migrate MATLAB settings paths in .m scripts between MATLAB releases.

995|122|Updated Apr 3, 2026
One-click install
npx skills add https://github.com/matlab/matlab-agentic-toolkit --skill matlab-migrate-settings
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: matlab-migrate-settings
Source: https://github.com/matlab/matlab-agentic-toolkit/tree/main/skills-catalog/matlab-environment-and-settings/matlab-migrate-settings
Command: npx skills add https://github.com/matlab/matlab-agentic-toolkit --skill matlab-migrate-settings

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

When upgrading MATLAB releases, scripts that programmatically set preferences via .PersonalValue or .TemporaryValue break because setting paths get renamed, moved, retyped, or removed. Manually diffing factory settings between releases and fixing every startup script, team preference file, or test setup script is slow and error-prone.

Core Features & Use Cases

  • Cross-release settings diff: Compares factory settings between two MATLAB installations using .hpp source files or strings extraction from compiled DLL/SO binaries to build a rename/move/remove/added change map.
  • Automatic script rewriting: Parses any .m file that assigns MATLAB settings, verifies each setting against the target release, translates values when types change (e.g., logical to string enum), and writes a new release-suffixed file without touching the original.
  • Runtime validation: Runs the migrated file in the target MATLAB to confirm zero errors, fixing moved paths and type mismatches iteratively.
  • Use Case: After installing R2026a, point the skill at your existing startup.m written for R2025b and receive a validated startup_R2026a.m with updated paths, translated values, and a migration summary.

Quick Start

Migrate my startup.m settings script from R2025b to the latest installed MATLAB release and validate the result.

Frequently Asked Questions about matlab-migrate-settings

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I migrate a MATLAB startup script to a new release?

Provide the path to your .m file and optionally the source and target releases. The skill diffs factory settings between the two MATLAB installations, rewrites changed setting paths, translates values when types changed, and writes a new release-suffixed file such as startup_R2026a.m.

How do I find which MATLAB settings changed between releases?

The skill compares factory settings definitions from each release's .hpp source files, or extracts strings from the compiled mwmatlab_factory_settings library when source is unavailable. It classifies each change as renamed, moved, split, removed, or type-changed.

Does it work on Windows where .hpp settings files are missing?

Yes. On Windows and other installs without .hpp source, it uses the strings tool on the compiled factory settings DLL to extract setting names, group context, and validation values, then confirms ambiguous cases at runtime in MATLAB.

Will it overwrite my original startup.m file?

No. The original file is never modified. The migrated output is written to a new file in the same directory with the target release appended to the name, such as startup_R2026a.m.

What happens to settings that were removed in the new MATLAB release?

Before classifying a setting as removed, the skill searches the target installation for the key under candidate groups using hasSetting. Only keys confirmed absent everywhere are commented out with an explanatory note; moved settings are rewritten to their new path instead.

When should I not use this settings migration approach?

Do not use it for .m files that do not assign MATLAB settings, for interactive preference changes (use the Preferences dialog), or for Simulink and toolbox-specific settings, since it covers core MATLAB settings only.