diff options
-rw-r--r-- | utils/rmcvsdir.pp | 15 |
1 files changed, 13 insertions, 2 deletions
diff --git a/utils/rmcvsdir.pp b/utils/rmcvsdir.pp index e26f1fead2..b2e49f5265 100644 --- a/utils/rmcvsdir.pp +++ b/utils/rmcvsdir.pp @@ -17,7 +17,10 @@ procedure deltree(const dirname : string); deltree(dirname+'/'+rec.name) end else - deletefile(dirname+'/'+rec.name); + begin + FileSetAttr(dirname+'/'+rec.name,faArchive); + deletefile(dirname+'/'+rec.name); + end; until findnext(rec)<>0; findclose(rec); end; @@ -38,6 +41,8 @@ procedure searchcvsdir(const dirname : string); begin if rec.name='CVS' then deltree(dirname+'/CVS') + else if rec.name='.svn' then + deltree(dirname+'/.svn') else if (rec.name<>'.') and (rec.name<>'..') then searchcvsdir(dirname+'/'+rec.name) @@ -47,6 +52,12 @@ procedure searchcvsdir(const dirname : string); end; end; +var + para : string; begin - searchcvsdir('.'); + if paramcount=0 then + para:='.' + else + para:=paramstr(1); + searchcvsdir(para); end. |