@echo ===============================================================
@echo Trac Lightning 1.x系のプロジェクトをアップグレードします。
@echo アップグレードを行う前に念のため%TL_PROJECT_HOME%ディレクトリの
@echo バックアップを取っておくことをお勧めします。
@echo ===============================================================
pause

call setenv.bat

SET PATH=%TRAC_LIGHT_HOME%\python;%TRAC_LIGHT_HOME%\subversion\bin;%TRAC_LIGHT_HOME%\bin;%PATH%
if not DEFINED TL_PROJECT_HOME set TL_PROJECT_HOME=%TRAC_LIGHT_HOME%\projects

cd /d "%TL_PROJECT_HOME%\trac"

bash -c "for i in *;do trac-admin.bat $i upgrade;done"
bash -c "for i in *;do trac-admin.bat $i wiki upgrade;done"

for /f "delims=" %%A in ('dir /B') do xcopy "%TRAC_LIGHT_HOME%\install\trac-template\htdocs" %%A\htdocs /e/c/f/h/y/i

cd ..\svn
for /f "delims=" %%A in ('dir /B') do copy /y "%TRAC_LIGHT_HOME%\bin\post-commit.bat" %%A\hooks\post-commit.bat

