MATLAB Python

getSPTBversion

Syntax

[versionString, versionStruct] = getSPTBversion()

Description

GETSPTBVERSION opens a text file containing version information from Git and parses each line. It extracts useful information about the latest version of SPTB being used and stores it in fields of a struct.

Usage

[versionString, sptb_version] = getSPTBversion() returns the entire version string as produced by a 'git describe' command, and a datastruct containing 8 fields with more detailed version information.

Output

versionString is in the form: 'vmajor.minor-point-fetchHead-dirty'. The fields of the struct, sptb_version are as follows: version: the entire version string major: the major version number minor: the minor version number point: number of commits made since last version update date: the date of the version revision in the format 'Day_of_Week Month Day Year' time: the time of the version revision fetchHead: the commit number of the version revision dirty: a boolean indicating whether the working tree was 'dirty' when the version information was retrieved. If true, then there are changes that have not yet been commited.