Rev | Line | |
---|
[144] | 1 | %WEBVERSION Set version on website
|
---|
| 2 | %
|
---|
[147] | 3 | % OUT = WEBVERSION(VERSION,TOOLBOX,FTPSITE)
|
---|
[144] | 4 | %
|
---|
[147] | 5 | %Creates a file TOOLBOX_version.txt containing just the VERSION number on
|
---|
| 6 | %FTPSITE. FTPSITE should be created by the @FTP package andchanged to the
|
---|
| 7 | %proper directory.
|
---|
[144] | 8 |
|
---|
| 9 | function out = webversion(version,varargin)
|
---|
| 10 |
|
---|
[147] | 11 | [toolbox,ftpsite] = setdefaults(varargin,'prtools',[]);
|
---|
[144] | 12 | if isempty(ftpsite)
|
---|
| 13 | ftpsite = ftp('prtools.tudelft.nl','prlab','0iX7&b3c');
|
---|
[147] | 14 | cd(ftpsite,'httpdocs/files')
|
---|
[144] | 15 | end
|
---|
| 16 |
|
---|
| 17 | versionfile = fullfile(fileparts(which(mfilename)),[toolbox '_version.txt']);
|
---|
| 18 | fid = fopen(versionfile,'w');
|
---|
[147] | 19 | fprintf(fid,['Version ' version ' ' date]);
|
---|
[144] | 20 | fclose(fid);
|
---|
| 21 | s = mput(ftpsite,versionfile);
|
---|
| 22 | delete(versionfile)
|
---|
| 23 | if nargout > 1
|
---|
| 24 | out = s;
|
---|
| 25 | end
|
---|
| 26 |
|
---|
Note: See
TracBrowser
for help on using the repository browser.