-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbuildfile.m
31 lines (23 loc) · 1.01 KB
/
buildfile.m
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
function plan = buildfile
import matlab.buildtool.tasks.CodeIssuesTask
% Create a plan from task functions
plan = buildplan(localfunctions);
% Add the "check" task to identify code issues
plan("check") = CodeIssuesTask(WarningThreshold=0);
% Make the "archive" task the default task in the plan
plan.DefaultTasks = "archive";
% Make the "archive" task dependent on the "check" and "test" tasks
plan("archive").Dependencies = "check";
end
function archiveTask(~, version)
opts = matlab.addons.toolbox.ToolboxOptions('dice', "92916d00-6626-4c09-b4d7-1cc087b13a6f"); %pick any identifier you want, but keep it constant.
opts.AuthorCompany = 'MathWorks';
opts.AuthorEmail = '[email protected]';
opts.AuthorName = 'Eduard Benet Cerda';
opts.Description = 'MATLAB Implementation of the DICE 2023 model from William Nordhaus.';
opts.OutputFile = 'DICE2023.mltbx';
opts.Summary = 'DICE Climate Model 2023';
opts.ToolboxName = 'DICE2023';
opts.ToolboxVersion = version;
matlab.addons.toolbox.packageToolbox(opts);
end