Main Content

Project Setup

Organize work into projects, automate startup and shutdown, find frequent tasks, reuse standard template settings

Projects help you to organize large modeling projects by finding required files, managing and sharing files and settings, and interacting with source control. SeeWhat Are Projects?and watchUsing Projects to Collaborate, Track, and Merge Changes and Perform Code Reviews (4 min, 50 sec).

Functions

expand all

currentProject Get current project
openProject Load an existing project
close Close project
export Export project to archive
matlab.project.createProject Create blank project
matlab.project.convertDefinitionFiles Change definition file type of project
matlab.project.deleteProject Stop folder management and delete project definition files
matlab.project.loadProject Load project
matlab.project.rootProject Get root project
Simulink.createFromTemplate Create model or project from template
Simulink.findTemplates Find model or project templates with specified properties
Simulink.exportToTemplate Create template from model or project

腿acy API

simulinkproject (Not recommended) Open project and get project object
slproject.create (Not recommended) Create blank project
slproject.getCurrentProjects (Not recommended) List all top-level projects
slproject.loadProject (Not recommended) Load project
addFile Add file or folder to project
addFolderIncludingChildFiles Add folder and child files to project
addPath Add folder to project path
addReference Add referenced project to project
addShortcut Add shortcut to project
addShutdownFile Add shutdown file to project
addStartupFile Add startup file to project
findFile Find project file by name
isLoaded Determine if project is loaded
reload Reload project
removeFile Remove file from project
removePath Remove folder from project path
removeReference Remove project reference
removeShortcut Remove shortcut from project
removeShutdownFile Remove shutdown file from project shutdown list
removeStartupFile Remove startup file from project startup list

腿acy API

simulinkproject (Not recommended) Open project and get project object

Topics

Project Creation

Create a New Project From a Folder

Automatic project creation: Easily turn a folder to a project and manage your files, data, and environment in one place.

Create a Project from a Model

Create a project to organize your model and any dependent files. Simulink®runs dependency analysis on your model to identify required files and a project root location that contains all dependencies.

Add Files to the Project

Add files in the project files view or programmatically.

Create a New Project from an Archived Project

Create a new project from an archived project.

Create a New Project Using Templates

In a project, use templates to create and reuse a standard project structure.

Open Recent Projects

Open recent projects from MATLAB®or Simulink.

指定项目细节,启动文件夹,然后引出ed Files Folders

View and edit details such as the name, description, project root, startup folder, and generated files folders.

Explore Project Tools with the Airframe Project

Try an example project to see how the tools can help you organize your work.

Set MATLAB Projects Preferences

Specify project definition files type, detect project files shadowed by open models, and detect project-wide references when renaming, removing and deleting files.

Startup and Shutdown Automation

Specify Project Path

The project can manage your path automatically when you open and close projects.

Automate Startup Tasks

In a project, startup files help you set up the environment for your project.

Automate Shutdown Tasks

In a project, shutdown files help you clean up the environment for the current project when you close it.

Frequent Task Shortcuts

Create Shortcuts to Frequent Tasks

In a project, create shortcuts for common project tasks and to make it easy to find and access important files and operations.

Use Shortcuts to Find and Run Frequent Tasks

In a project, use shortcuts to make it easy for any project user to find and access important files and operations.

Project Template Creation

Create Templates for Standard Project Settings

To reuse scripts and files for a standard project setup, create templates from projects, edit templates, or explore example templates.

About Projects

What Are Projects?

Use projects to help you organize your work. Find all your required files; manage and share files, settings, and user-defined tasks; and interact with source control.

What Can You Do With Project Shortcuts?

In a project, use shortcuts to make it easy for any project user to find and access important files and operations.

Sharing Projects

Collaborate by sharing projects by email, archive file, template, MATLAB toolbox, or on GitHub®.

Featured Examples