Home > atmlab > arts > arts_version.m

arts_version

PURPOSE ^

ARTS_VERSION Reports the version of arts

SYNOPSIS ^

function s = arts_version( long_on_screen )

DESCRIPTION ^

 ARTS_VERSION   Reports the version of arts

    The version is reported as a short string. Complete information can be
    printed on the screen.

 FORMAT   s = arts_version( long_on_screen )
        
 OUT   s              A string describing the arts version, e.g. 'arts-2.1.3'
 OPT   long_on_screen Flag to print detailed information.

CROSS-REFERENCE INFORMATION ^

This function calls: This function is called by:

DOWNLOAD ^

arts_version.m

SOURCE CODE ^

0001 % ARTS_VERSION   Reports the version of arts
0002 %
0003 %    The version is reported as a short string. Complete information can be
0004 %    printed on the screen.
0005 %
0006 % FORMAT   s = arts_version( long_on_screen )
0007 %
0008 % OUT   s              A string describing the arts version, e.g. 'arts-2.1.3'
0009 % OPT   long_on_screen Flag to print detailed information.
0010 
0011 % 2012-10-22   Created by Patrick Eriksson.
0012 
0013 function s = arts_version( long_on_screen )
0014 
0015 [notok,s] = arts( '-v', [], true );
0016 
0017 if nargin & long_on_screen
0018   disp(s)
0019 end
0020 
0021 i1 = min( findstr( s, 'arts-' ) );
0022 i2 = min( find( s(i1:end) == ' ' ) );
0023 
0024 s = s( i1+[0:i2-2] );
0025

Generated on Mon 15-Sep-2014 13:31:28 by m2html © 2005