X-Git-Url: http://git.osdn.net/view?a=blobdiff_plain;f=_src%2FTest%2Fvbslib_test%2FT_devenv%2FT_devenv1.vbs;h=b2c438c0c3c2cfe195b3130027d306f946bc798c;hb=8cd319a3714156b275c5e3809401dfccfa472e29;hp=af57465c7952b7c6f81971bde37081ec17615750;hpb=96594a1f7f4a7fcb1ef2b3641e65c63a0a98635c;p=vbslib%2Fmain.git diff --git a/_src/Test/vbslib_test/T_devenv/T_devenv1.vbs b/_src/Test/vbslib_test/T_devenv/T_devenv1.vbs index af57465..b2c438c 100644 --- a/_src/Test/vbslib_test/T_devenv/T_devenv1.vbs +++ b/_src/Test/vbslib_test/T_devenv/T_devenv1.vbs @@ -1,27 +1,31 @@ Option Explicit '--- start of vbslib include ------------------------------------------------------ -Dim g_debug, g_vbslib_path, g_IncludeType, g_CommandPrompt, g_fs, g_sh +'// ‚±‚±‚́AC³‚µ‚È‚¢‚Å‚­‚¾‚³‚¢B‰º‹LƒƒCƒ“ŠÖ”‚©‚çƒXƒNƒŠƒvƒg‚ð‹Lq‚µ‚Ä‚­‚¾‚³‚¢B +'// ‚l‚rƒIƒtƒBƒX‚âƒRƒ“ƒpƒCƒ‰‚ª‚ ‚ê‚΁A‰º‹L‚Ì‚‡Q‚„‚…‚‚‚•‚‡ ‚ð‚P‚É‚·‚ê‚΁AƒfƒoƒbƒK‚ªŽg‚¦‚Ü‚·B +'// ‚r‚”‚‚–½—ß‚ð‹Lq‚·‚ê‚΁AƒfƒoƒbƒK‚̓uƒŒ[ƒN‚µ‚Ü‚·BÚ‚µ‚­‚Í vbslib ‚Ìà–¾‘‚̍Ōã‚́u¢‚Á‚½‚Æ‚«‚́vB +Dim g_debug, g_admin, g_vbslib_path, g_CommandPrompt, g_fs, g_sh, g_AppKey, g_Vers If IsEmpty( g_fs ) Then + Dim g_MainPath, g_SrcPath : g_SrcPath = WScript.ScriptFullName : g_MainPath = g_SrcPath + Set g_Vers = CreateObject("Scripting.Dictionary") : g_Vers.Add "vbslib", 3.0 '--- start of parameters for vbslib include ------------------------------- g_debug = 0 g_vbslib_path = "vbslib\vbs_inc.vbs" - g_IncludeType = "" g_CommandPrompt = 2 '--- end of parameters for vbslib include --------------------------------- Dim g_f, g_include_path, i : Set g_fs = CreateObject( "Scripting.FileSystemObject" ) - If g_fs.FileExists("setting.vbs") Then Set g_f = g_fs.OpenTextFile( "setting.vbs" ): Execute g_f.ReadAll() - If not IsEmpty( WScript.Arguments.Named.Item("IncludeType") ) Then g_IncludeType = WScript.Arguments.Named.Item("IncludeType") Set g_sh = WScript.CreateObject("WScript.Shell") : g_f = g_sh.CurrentDirectory g_sh.CurrentDirectory = g_fs.GetParentFolderName( WScript.ScriptFullName ) - For i = 10 To 1 Step -1 : If g_fs.FileExists(g_vbslib_path) Then Exit For + For i = 20 To 1 Step -1 : If g_fs.FileExists(g_vbslib_path) Then Exit For g_vbslib_path = "..\" + g_vbslib_path : Next If g_fs.FileExists(g_vbslib_path) Then g_vbslib_path = g_fs.GetAbsolutePathName( g_vbslib_path ) g_sh.CurrentDirectory = g_f - If i=0 Then WScript.Echo "Not found " + g_fs.GetFileName( g_vbslib_path ) +vbCR+vbLF+ "Check g_vbslib_path in " + WScript.ScriptName + " or setting.vbs" : WScript.Quit 1 + If i=0 Then WScript.Echo "Not found " + g_fs.GetFileName( g_vbslib_path ) +vbCR+vbLF+ "Let's download vbslib "&g_Vers.Item("vbslib")&" and Copy vbslib folder." : WScript.Quit 1 Set g_f = g_fs.OpenTextFile( g_vbslib_path ): Execute g_f.ReadAll() : g_f = Empty If ResumePush Then On Error Resume Next - main - ResumePop : On Error GoTo 0 + If IsDefined("main2") Then Set g_f=CreateObject("Scripting.Dictionary") :_ + Set g_AppKey = new AppKeyClass : main2 g_f, g_AppKey.SetKey( new AppKeyClass ) Else _ + Set g_AppKey = new AppKeyClass : g_AppKey.SetKey( new AppKeyClass ) : main + g_f = Empty : ResumePop : On Error GoTo 0 End If '--- end of vbslib include -------------------------------------------------------- @@ -30,21 +34,23 @@ End If ' <<< [main] >>> '******************************************************************************** Sub main() - devenv_clean "sample sln\return.sln" + devenv_clean "sample sln\return_%devenv_ver_name%.sln" If exist("sample sln\Release\return.exe") Then Fail If exist("sample sln\Debug\return.exe") Then Fail - devenv_rebuild "sample sln\return.sln", "Release" + devenv_build "sample sln\return_%devenv_ver_name%.sln", "Release" If Not exist("sample sln\Release\return.exe") Then Fail If exist("sample sln\Debug\return.exe") Then Fail - devenv_rebuild "sample sln\return.sln", "Debug" + devenv_rebuild "sample sln\return_%devenv_ver_name%.sln", "Debug" If Not exist("sample sln\Release\return.exe") Then Fail If Not exist("sample sln\Debug\return.exe") Then Fail - devenv_clean "sample sln\return.sln" + devenv_clean "sample sln\return_%devenv_ver_name%.sln" If exist("sample sln\Release\return.exe") Then Fail If exist("sample sln\Debug\return.exe") Then Fail + + ManualTest "T_devenvManual" Pass End Sub