You can use source control with projects. For more information, see Clone from Git Repository, Create Projects, and Use Source Control with Projects.
About MathWorks Source Control Integration
Use MATLAB to work with files under source control. You can perform operations such as update, commit, merge changes, and view revision history directly from the Current Folder browser.
Select or Disable Source Control System
MathWorks® source control integration is on by default. You can select or disable a source control system.
Customize External Source Control to Use MATLAB for Diff and Merge
Use the MATLAB Comparison Tool for diff and merge from external source control tools.
Retrieve Files from Git Repository
Clone a remote Git™ repository to retrieve repository files.
Create a new Git or SVN repository.
To use a third-party source control tools, register your binary files to avoid file corruption. To prevent frequent login prompts when you interact with your remote repository, use SSH Authentication with MATLAB.
Mark Files for Addition to Source Control
When you create a new file in a folder under source control, mark the file for addition to source control.
Move, Rename, or Delete Files Under Source Control
Move, rename, or delete files using the MATLAB Source Control context menu options or another source control client application.
Clone an external Git repository as a submodule.
Update Git File Status and Revision
Refresh the source control status of files in the repository, and fetch updates of files in a repository.
Review Changes in Source Control
Browse the history of a file, or compare file revisions.
Commit Modified Files to Source Control
After you review changes and mark any new files for addition into source control, you can commit your files.
Resolve Source Control Conflicts
If a conflict message appears when you try to commit files, examine and resolve conflicts.
Create, merge, and delete branches, or switch to another branch.
Pull, Push and Fetch Files with Git
Use this workflow to work with a remote repository. With Git, there is a two-step workflow: commit local changes, and then push to the remote repository.
Revert Changes in Source Control
Remove local changes in a file or revert a file to a specified revision.
Create a new local copy of a repository by retrieving files from source control.
Create a new Git or SVN repository.
MATLAB provides built-in SVN integration.
Mark Files for Addition to Source Control
When you create a new file in a folder under source control, mark the file for addition to source control.
Move, Rename, or Delete Files Under Source Control
Move, rename, or delete files using the MATLAB Source Control context menu options or another source control client application.
Update SVN File Status and Revision
Refresh the source control status of files, and update local copies of files.
It is good practice to get a file lock before editing a file. The lock tells other users that the file is being edited, and you can avoid merge issues.
Review Changes in Source Control
Browse the history of a file, or compare file revisions.
Commit Modified Files to Source Control
After you review changes and mark any new files for addition into source control, you can commit your files.
Resolve Source Control Conflicts
If a conflict message appears when you try to commit files, examine and resolve conflicts.
Revert Changes in Source Control
Remove local changes in a file or revert a file to a specified revision.