Line | |
---|
1 | %WEBVERSION Set version on website
|
---|
2 | %
|
---|
3 | % OUT = WEBVERSION(VERSION,TOOLBOX,FTPSITE)
|
---|
4 | %
|
---|
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.
|
---|
8 |
|
---|
9 | function out = webversion(version,varargin)
|
---|
10 |
|
---|
11 | [toolbox,ftpsite] = setdefaults(varargin,'prtools',[]);
|
---|
12 | if isempty(ftpsite)
|
---|
13 | ftpsite = ftp('prtools.tudelft.nl','prlab','0iX7&b3c');
|
---|
14 | cd(ftpsite,'httpdocs/files')
|
---|
15 | end
|
---|
16 |
|
---|
17 | versionfile = fullfile(fileparts(which(mfilename)),[toolbox '_version.txt']);
|
---|
18 | fid = fopen(versionfile,'w');
|
---|
19 | fprintf(fid,['Version ' version ' ' date]);
|
---|
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.