MATLAB Community

MATLAB, community & more

Updating toolboxes from a MATLAB Minimart store

Posted by Ned Gulley,

This post is the continuation of the previous one, in which MathWorks consultant David Sampson introduced the basics behind his free Minimart MATLAB store app. This time David tells you more about how to use it.

Updating toolboxes from a MATLAB Minimart store

by David Sampson

In my previous post, I provided an introduction to MATLAB toolbox packaging and MATLAB Minimart. In this post, I will focus on keeping your toolboxes up-to-date using your store.

Pushing toolbox upgrades to users and coordinating upgrades among workgroup members are common challenges. As a consultant, I have seen many home-grown approaches, from mailing lists to shared drives to custom MATLAB code to general purpose installer solutions. Using MATLAB toolbox packaging and a toolbox store makes toolbox management easier. MATLAB Minimart includes an update function, minimart.updateToolboxes, that compares your installed toolboxes with those in the store. This function leverages the toolbox management APIs introduced in release R2016a.

As an example, consider a user installation with a number of toolboxes installed – some from the store and up-to-date, others from the store and out-of-date, and others still from elsewhere.


To generate a report on differences between installed toolbox versions and versions available in the store, enter this command.

>> minimart.updateToolboxes('C:\work\store\demo','query')
'Snowplow Toolbox' version 1.0 is installed, but a later version 2.3 is available in the store.
'GUI Layout Toolbox' version 2.2.2 is installed, but this toolbox is not in the store.
'MATLAB Web Maps' version 1.2 is installed, but this toolbox is not in the store.
'MATLAB Tracks' version 1.1.3 is installed, but this toolbox is not in the store.
'Dump Truck Toolbox' version 2.1 is installed, but a later version 3.1 is available in the store.
'Pickup Truck Toolbox' version 1.1 is installed, and is the latest version in the store.
'Cable Car Toolbox' version 3.3 is installed, and is the latest version in the store.

There are four possible states:

  1. Installed version matches latest available version – no action required
  2. Later version available in the store – would you like to upgrade?
  3. Only earlier version(s) available in the store – how did you get a later one?
  4. Toolbox not available in the store – did you get this from somewhere else?

To automatically update all your installed toolbox versions to the latest available versions in the store, type this.

>> minimart.updateToolboxes('C:\work\store\demo','auto')

MATLAB displays a progress bar and reports updates to the Command Window.

Upgrading 'Snowplow Toolbox' from version 1.0 to version 2.3... done.
Upgrading 'Dump Truck Toolbox' from version 2.1 to version 3.1... done.

There is also a third mode, ‘manual’, that prompts you to accept each upgrade and downgrade.

You may find it convenient to create a shortcut on the MATLAB Desktop to perform automatic updates. This allows you to update all of your toolboxes at the click of a button.


MATLAB Minimart is a demo to whet your appetite, not a fully featured enterprise solution. As Jaguar Land Rover described, there are many additional features – access control, approval, discussion boards, integration with other tools to name just a few – that may be necessary or valuable in the context of your organization. My colleagues and I at MathWorks Consulting would be happy to work with you to develop a store solution that meets your specific requirements… not to mention build some great toolboxes to put in it. You can also adapt the MATLAB Minimart code and template as you wish.

Thanks to my colleague, Sylvain Lacaze, who worked with me on developing MATLAB Minimart. All shininess is down to him.

One thought to leave you with. On the day that MATLAB Minimart was first demonstrated, XKCD ran this comic.

Please give MATLAB Minimart a try, and share your comments on the File Exchange.

Add A Comment

What is 4 + 8?

Preview: hide