echo off

rem V6 対応を一旦保留(jdk11 でtools.jarを加えてコンパイル)
rem set JAVADOC_V6=JAVADOC_V6

call %~dp0..\..\bin\init.bat

set DEV_DIR=..\..\..\dev
set SVN_DIR=C:/opengion_svn/opengionV7

rem com.sun.javadoc関連のクラスを持ってくる
set CLASSPATH=%CLASSPATH%;./tools.jar

echo ****************************************************
echo * Ant Target is
echo *  compile(default) : compile java files
echo *  taglib           : create taglib xml files
echo *  spec             : create Javadoc Spec sheet
echo *  check            : RELEASE-NOTES check
echo *
echo *  all ※           : compile 〜 check All running
echo ****************************************************

set /p target=Type Target:

set ANT_VER=apache-ant-1.10.3
set ANT_HOME=%DEV_DIR%\%ANT_VER%
set PATH=%PATH%;%ANT_HOME%\bin;

rem logファイルのクリア
echo > log1.txt 2> log2.txt

if "%target%"=="all" (
	set CHECK_FLAG=0
	for %%A in (compile taglib spec check) do (
		echo %%A
		call ant -autoproxy -f buildDoc.xml %%A >> log1.txt 2>> log2.txt
	)
) else (
	set CHECK_FLAG=1
	call ant -autoproxy -f buildDoc.xml %target% > log1.txt 2> log2.txt
)
