Home > p2plib > rmlocdirs.m

rmlocdirs

PURPOSE ^

remove data directories from current dir (a cleanup tool)

SYNOPSIS ^

function rmlocdirs

DESCRIPTION ^

 remove data directories from current dir (a cleanup tool)

CROSS-REFERENCE INFORMATION ^

This function calls: This function is called by:

SOURCE CODE ^

0001 function rmlocdirs 
0002 % remove data directories from current dir (a cleanup tool)
0003 ok=0; md=dir; mdl=length(md); 
0004 for i=1:mdl
0005    cf=md(i); 
0006    if (cf.isdir==1 && ~strcmp(cf.name,'.') && ~strcmp(cf.name,'..'))
0007       fprintf('intending to remove %s, ', cf.name);
0008       ok=asknu('OK?',ok); if ok; rmdir(cf.name,'s'); end
0009    end
0010 end

Generated on Wed 15-Aug-2012 10:09:15 by m2html © 2005