Skip to content

Commit

Permalink
added global vars at the beginning and some docs
Browse files Browse the repository at this point in the history
  • Loading branch information
syarra committed Jun 23, 2017
1 parent af05bed commit 581210b
Showing 1 changed file with 16 additions and 10 deletions.
26 changes: 16 additions & 10 deletions .ci/runTutorial.m
Original file line number Diff line number Diff line change
@@ -1,17 +1,25 @@
function runTutorial(tutorialName)
% Runs the given tutorial after initialising The COBRA Toolbox.
%
% USAGE:
%
% runTutorial(tutorialName)
%
% INPUT:
% tutorialName: string containing the name of the tutorial to be run
%
% .. Author: Sylvain Arreckx, June 2017

% include the root folder and all subfolders
addpath(genpath(pwd))
global WAITBAR_TYPE;
global ENV_VARS;
WAITBAR_TYPE = 0; % Mute progress bars
ENV_VARS.printLevel = 0; % Mute initCobraToolbox

addpath(pwd) % include the root folder

% run the official initialisation script
initCobraToolbox

% Mute progress bars and initCobraToolbox
global WAITBAR_TYPE;
global ENV_VARS;
WAITBAR_TYPE = 0;
ENV_VARS.printLevel = 0;

% retrieve the models first
retrieveModels;

Expand All @@ -20,5 +28,3 @@ function runTutorial(tutorialName)
fprintf('Default solver is set to GLPK\n');

eval(tutorialName);

end

0 comments on commit 581210b

Please sign in to comment.