Instruction stringlengths 14 778 | input_code stringlengths 0 4.24k | output_code stringlengths 1 5.44k |
|---|---|---|
Simplify the script. It now allows normal ant targets and flags to be passed straight through. For example | @REM
@REM Copyright (c) 2006, Intel Corporation
@REM All rights reserved. This program and the accompanying materials
@REM are licensed and made available under the terms and conditions of the BSD License
@REM which accompanies this distribution. The full text of the license may be found at
@REM http://opensource.org/licenses/bsd-license.php
@REM
@REM THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
@REM WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
@REM
@REM @if "%1"=="" (goto build)
@REM @if "%1"=="clean" (goto clean)
@REM @if "%1"=="cleanall" (goto cleanall)
:build
@echo on
ant -f %WORKSPACE%/build.xml %1 %2 %3
@echo off
@goto end
:clean
@echo on
ant clean -f %WORKSPACE%/build.xml
@echo off
@goto end
:cleanall
@echo on
ant cleanall -f %WORKSPACE%/build.xml
@echo off
@goto end
:end | @REM
@REM Copyright (c) 2006, Intel Corporation
@REM All rights reserved. This program and the accompanying materials
@REM are licensed and made available under the terms and conditions of the BSD License
@REM which accompanies this distribution. The full text of the license may be found at
@REM http://opensource.org/licenses/bsd-license.php
@REM
@REM THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
@REM WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
@REM
ant -f %WORKSPACE%/build.xml %*
|
Use correct build string in metadata files | conda list -p "%PREFIX%" --canonical
if errorlevel 1 exit 1
for /f "delims=" %%i in ('conda list -p "%PREFIX%" --canonical') do set condalist=%%i
if errorlevel 1 exit 1
echo "%condalist%"
if not "%condalist%"=="conda-build-test-build-string-1.0-1" exit 1
cat "%PREFIX%\conda-meta\conda-build-test-build-string-1.0-1.json"
if errorlevel 1 exit 1
cat "%PREFIX%\conda-meta\conda-build-test-build-string-1.0-1.json" | grep '"build_number": 0'
if errorlevel 1 exit 1
cat "%PREFIX%\conda-meta\conda-build-test-build-string-1.0-1.json" | grep '"build": "abc"'
if errorlevel 1 exit 1
| conda list -p "%PREFIX%" --canonical
if errorlevel 1 exit 1
for /f "delims=" %%i in ('conda list -p "%PREFIX%" --canonical') do set condalist=%%i
if errorlevel 1 exit 1
echo "%condalist%"
if not "%condalist%"=="conda-build-test-build-string-1.0-abc" exit 1
cat "%PREFIX%\conda-meta\conda-build-test-build-string-1.0-abc.json"
if errorlevel 1 exit 1
cat "%PREFIX%\conda-meta\conda-build-test-build-string-1.0-abc.json" | grep '"build_number": 0'
if errorlevel 1 exit 1
cat "%PREFIX%\conda-meta\conda-build-test-build-string-1.0-abc.json" | grep '"build": "abc"'
if errorlevel 1 exit 1
|
Patch for version 0.79 update | @echo off
cls
:start
echo Starting server...
"Nomad Server\NomadServer.exe" -name "My Oxide Server" -port 5127 -slots 10 -clientVersion "0.78" -password "" -tcpLobby "149.202.51.185" 25565
echo.
echo Restarting server...
echo.
goto start
| @echo off
cls
:start
echo Starting server...
"Nomad Server\NomadServer.exe" -name "My Oxide Server" -port 5127 -slots 10 -clientVersion "0.79" -password "" -tcpLobby "149.202.51.185" 25565
echo.
echo Restarting server...
echo.
goto start
|
Add WinSxS path to vcomp90 | for %%F in ("." "bin") do (
cmake -G "%CMAKE_GENERATOR%" ^
-DCMAKE_INSTALL_PREFIX:PATH="%LIBRARY_PREFIX%" ^
-DCMAKE_INSTALL_DEBUG_LIBRARIES:BOOL="OFF" ^
-DCMAKE_INSTALL_DEBUG_LIBRARIES_ONLY:BOOL="OFF" ^
-DCMAKE_INSTALL_OPENMP_LIBRARIES:BOOL="ON" ^
-DCMAKE_INSTALL_SYSTEM_RUNTIME_DESTINATION:STRING=%%F ^
"%RECIPE_DIR%"
if errorlevel 1 exit 1
cmake --build "%SRC_DIR%" ^
--target INSTALL ^
--config Release
if errorlevel 1 exit 1
)
| if "%ARCH%" == "32" (set "ARCH_DIR=x86")
if "%ARCH%" == "64" (set "ARCH_DIR=amd64")
dir /a:d /o:-n /s /b C:\Windows\WinSxS\%ARCH_DIR%_microsoft.vc90.openmp* > vcomp90_locs.txt
type vcomp90_locs.txt
set /p VCOMP_DIR=<vcomp90_locs.txt
echo "%VCOMP_DIR%"
for %%F in ("." "bin") do (
cmake -G "%CMAKE_GENERATOR%" ^
-DCMAKE_INSTALL_PREFIX:PATH="%LIBRARY_PREFIX%" ^
-DCMAKE_INSTALL_SYSTEM_RUNTIME_LIBS:PATH="%VCOMP_DIR%\vcomp90.dll" ^
-DCMAKE_INSTALL_DEBUG_LIBRARIES:BOOL="OFF" ^
-DCMAKE_INSTALL_DEBUG_LIBRARIES_ONLY:BOOL="OFF" ^
-DCMAKE_INSTALL_OPENMP_LIBRARIES:BOOL="ON" ^
-DCMAKE_INSTALL_SYSTEM_RUNTIME_DESTINATION:STRING=%%F ^
"%RECIPE_DIR%"
if errorlevel 1 exit 1
cmake --build "%SRC_DIR%" ^
--target INSTALL ^
--config Release
if errorlevel 1 exit 1
)
|
Update the version to 5.12.6. | ECHO OFF
SET "ARCH=x64"
SET "VC_ARCH=amd64"
SET "QT_KIT=C:\Qt\5.12.0\msvc2017_64"
SET "DIR=%~dp0"
SET "BUILD_TYPE=release"
SET "BUILD_DIR=%DIR%..\build-OAuthRedirectExample-Desktop_Qt_5_12_0_MSVC2017_64bit-Release\%BUILD_TYPE%"
SET "ARCGIS_SDK_DIR=C:\Program Files (x86)\ArcGIS SDKs\Qt100.7\sdk\windows\%ARCH%\bin\%BUILD_TYPE%"
call "C:\Program Files (x86)\Microsoft Visual Studio\2017\Professional\VC\Auxiliary\Build\vcvarsall.bat" %VC_ARCH%
call %QT_KIT%\bin\windeployqt.exe %BUILD_DIR%\OAuthRedirectExample.exe --qmldir %DIR% -sensors -positioning
copy "%ARCGIS_SDK_DIR%\EsriCommonQt.dll" "%BUILD_DIR%\EsriCommonQt.dll"
copy "%ARCGIS_SDK_DIR%\runtimecore.dll" "%BUILD_DIR%\runtimecore.dll"
| ECHO OFF
SET "ARCH=x64"
SET "VC_ARCH=amd64"
SET "QT_KIT=C:\Qt\5.12.6\msvc2017_64"
SET "DIR=%~dp0"
SET "BUILD_TYPE=release"
SET "BUILD_DIR=%DIR%..\build-OAuthRedirectExample-Desktop_Qt_5_12_6_MSVC2017_64bit-Release\%BUILD_TYPE%"
SET "ARCGIS_SDK_DIR=C:\Program Files (x86)\ArcGIS SDKs\Qt100.7\sdk\windows\%ARCH%\bin\%BUILD_TYPE%"
call "C:\Program Files (x86)\Microsoft Visual Studio\2017\Professional\VC\Auxiliary\Build\vcvarsall.bat" %VC_ARCH%
call %QT_KIT%\bin\windeployqt.exe %BUILD_DIR%\OAuthRedirectExample.exe --qmldir %DIR% -sensors -positioning
copy "%ARCGIS_SDK_DIR%\EsriCommonQt.dll" "%BUILD_DIR%\EsriCommonQt.dll"
copy "%ARCGIS_SDK_DIR%\runtimecore.dll" "%BUILD_DIR%\runtimecore.dll"
|
Update comport and avrdude path. | @echo #----------------------------------------------------------------------------#
@echo # Generating main.lss
@echo #----------------------------------------------------------------------------#
avr-objdump -h -S bin\main.elf > bin\main.lss
@echo #----------------------------------------------------------------------------#
@echo # Generating main.hex
@echo #----------------------------------------------------------------------------#
avr-objcopy -O ihex bin\main.elf bin\main.hex
@echo #----------------------------------------------------------------------------#
@echo # File size main.hex
@echo #----------------------------------------------------------------------------#
avr-size --target=ihex bin\main.hex
@echo #----------------------------------------------------------------------------#
@echo # Burning main.hex in ATMega328p with COM7
@echo #----------------------------------------------------------------------------#
c:\arduino\WinAVR-20100110\bin\avrdude.exe -v -pm2560 -cstk500v2 -PCOM4 -b115200 -e -U flash:w:"bin\main.hex"
@echo # Done | @echo #----------------------------------------------------------------------------#
@echo # Generating main.lss
@echo #----------------------------------------------------------------------------#
avr-objdump -h -S bin\main.elf > bin\main.lss
@echo #----------------------------------------------------------------------------#
@echo # Generating main.hex
@echo #----------------------------------------------------------------------------#
avr-objcopy -O ihex bin\main.elf bin\main.hex
@echo #----------------------------------------------------------------------------#
@echo # File size main.hex
@echo #----------------------------------------------------------------------------#
avr-size --target=ihex bin\main.hex
@echo #----------------------------------------------------------------------------#
@echo # Burning main.hex in ATMega328p with COM5
@echo #----------------------------------------------------------------------------#
avrdude.exe -v -pm2560 -cstk500v2 -PCOM5 -b115200 -e -U flash:w:"bin\main.hex"
@echo # Done |
Fix node Windows absolute path | @echo off
:: http://stackoverflow.com/questions/12322308/batch-file-to-check-64bit-or-32bit-os
reg Query "HKLM\Hardware\Description\System\CentralProcessor\0" | find /i "x86" > NUL && set ARCH=x86 || set ARCH=x64
set NODE_PATH="%~dp0\bin\node\node-win32-%ARCH%.exe"
@IF NOT EXIST %NODE_PATH% (
set NODE_PATH="node.exe"
)
%NODE_PATH% "%~dp0\..\lib\resin.js" %*
| @echo off
:: http://stackoverflow.com/questions/12322308/batch-file-to-check-64bit-or-32bit-os
reg Query "HKLM\Hardware\Description\System\CentralProcessor\0" | find /i "x86" > NUL && set ARCH=x86 || set ARCH=x64
set NODE_PATH="%~dp0\node\node-win32-%ARCH%.exe"
@IF NOT EXIST %NODE_PATH% (
set NODE_PATH="node.exe"
)
%NODE_PATH% "%~dp0\..\lib\resin.js" %*
|
Add more logging for debugging formatting failures on windows | SET "JAVA_HOME=C:\opt\jdk1.8.0_161"
cd git-repo
./mvnw clean install | SET "JAVA_HOME=C:\opt\jdk1.8.0_161"
cd git-repo
./mvnw clean install -X |
Kill background processes to allow parent to exit | if not exist "C:\Windows\Temp\msys2.exe" (
powershell -Command "[Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::TLS12; (New-Object System.Net.WebClient).DownloadFile('https://github.com/msys2/msys2-installer/releases/download/2020-07-20/msys2-x86_64-20200720.exe', 'C:\Windows\Temp\msys2.exe')" <NUL
)
cmd /c "C:\Windows\Temp\msys2.exe -v --script A:\msys2-install.qs"
| if not exist "C:\Windows\Temp\msys2.exe" (
powershell -Command "[Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::TLS12; (New-Object System.Net.WebClient).DownloadFile('https://github.com/msys2/msys2-installer/releases/download/2020-07-20/msys2-x86_64-20200720.exe', 'C:\Windows\Temp\msys2.exe')" <NUL
)
cmd /c "C:\Windows\Temp\msys2.exe -v --platform minimal --script A:\msys2-install.qs"
taskkill /IM "gpg-agent.exe" /F
taskkill /IM "dirmngr.exe" /F
|
Update script to check properly for missing variables, and get the quotations right (I hope)... | @echo off
rem check that JAVA_HOME and LCF_HOME are set
rem save existing path here
set OLDDIR=%CD%
cd %LCF_HOME%\processes
set CLASSPATH=.
for %%f in (jar/*) do call script\setclasspath.bat %%f
set JAVADEFINES=
for %%g in (define/*) do call script\setdefine.bat %%g
rem restore old path here
cd %OLDDIR%
"%JAVA_HOME%\bin\java" -Dorg.apache.lcf.configfile=%LCF_HOME%\properties.ini %JAVADEFINES% -classpath %CLASSPATH% %1 %2 %3 %4 %5 %6 %7 %8 %9
| @echo off
rem check that JAVA_HOME and LCF_HOME are set
if not exist "%JAVA_HOME%\bin\java.exe" goto nojavahome
if not exist "%LCF_HOME%\properties.ini" goto nolcfhome
rem save existing path here
set OLDDIR=%CD%
cd "%LCF_HOME%\processes"
set CLASSPATH=.
for %%f in (jar/*) do call script\setclasspath.bat %%f
set JAVADEFINES=
for %%g in (define/*) do call script\setdefine.bat %%g
rem restore old path here
cd "%OLDDIR%"
"%JAVA_HOME%\bin\java" "-Dorg.apache.lcf.configfile=%LCF_HOME%\properties.ini" %JAVADEFINES% -classpath "%CLASSPATH%" %1 %2 %3 %4 %5 %6 %7 %8 %9
goto done
:nojavahome
echo Environment variable JAVA_HOME is not set properly.
goto done
:nolcfhome
echo Environment variable LCF_HOME is not set properly.
goto done
:done
|
Make sure only the used lib files end up in the Magick.NET.libs folder. | @echo off
call "%vs140comntools%vsvars32.bat"
set LIBDIR=C:\Magick.NET.libs
set TARGET=C:\Magick.NET\ImageMagick
if "%2"=="AnyCPU" goto anycpu
xcopy %LIBDIR%\lib\Release\%2 %TARGET%\lib\Release\%2 /Y /S /I
xcopy %LIBDIR%\%1\lib\Release\%2 %TARGET%\$1\lib\Release\%2 /Y /S /I
goto build
:anycpu
xcopy %LIBDIR%\lib\Release %TARGET%\lib\Release /Y /S /I
xcopy %LIBDIR%\%1\lib\Release %TARGET%\$1\lib\Release /Y /S /I
:build
powershell -ExecutionPolicy Unrestricted ..\Scripts\AppVeyor\Build.ps1 %1 %2 | @echo off
call "%vs140comntools%vsvars32.bat"
set LIBDIR=C:\Magick.NET.libs
set TARGET=C:\Magick.NET\ImageMagick
if "%2"=="AnyCPU" goto anycpu
xcopy %LIBDIR%\lib\Release\%2 %TARGET%\lib\Release\%2 /Y /S /I
xcopy %LIBDIR%\%1\lib\Release\%2 %TARGET%\%1\lib\Release\%2 /Y /S /I
goto build
:anycpu
xcopy %LIBDIR%\lib\Release %TARGET%\lib\Release /Y /S /I
xcopy %LIBDIR%\%1\lib\Release %TARGET%\%1\lib\Release /Y /S /I
:build
rmdir /S /Q %LIBDIR%
xcopy %TARGET% %LIBDIR% /Y /S /I
powershell -ExecutionPolicy Unrestricted ..\Scripts\AppVeyor\Build.ps1 %1 %2 |
Add command line for hector | build\install\hector\bin\hector.bat com.marklogic.hector.JobConfig job input_file_path=./src/test/resources/Most_Popular_Baby_Names_NYC.csv delimited_root_name=baby-name document_type=xml output_collections=baby-name chunk_size=100 thread_count=4 | |
Add Windows batch file for batch conversion. | @for %%a in (*.mid) do @midisplit "%%a" "%%~na-split.mid"
rem @set midisplit_dir=%~dp0
rem
rem :dispatch_loop
rem @if "%1"=="" @goto dispatch_done
rem @echo %midisplit_dir%midisplit "%1" "%~dpn1.mid"
rem @shift
rem @goto dispatch_loop
rem :dispatch_done
| |
Fix command history in Windows | @echo off
setlocal enabledelayedexpansion
set PLAY_VERSION="2.2-SNAPSHOT"
if defined JPDA_PORT set DEBUG_PARAM="-Xrunjdwp:transport=dt_socket,server=y,suspend=n,address=%JPDA_PORT%"
set p=%~dp0
set p=%p:\=/%
set fp=file:///!p: =%%20!
java -Xms512M -Xmx1024M -Xss1M -XX:+CMSClassUnloadingEnabled -XX:MaxPermSize=256M %DEBUG_PARAM% %JAVA_OPTS% -Dfile.encoding=UTF-8 -Dplay.version="%PLAY_VERSION%" -Dsbt.ivy.home="%~dp0..\repository" -Dplay.home="%~dp0." -Dsbt.boot.properties="%fp%sbt/sbt.boot.properties" %PLAY_OPTS% -jar "%~dp0sbt\sbt-launch.jar" %*
:end
endlocal
| @echo off
setlocal enabledelayedexpansion
set PLAY_VERSION="2.2-SNAPSHOT"
if defined JPDA_PORT set DEBUG_PARAM="-Xrunjdwp:transport=dt_socket,server=y,suspend=n,address=%JPDA_PORT%"
set p=%~dp0
set p=%p:\=/%
set fp=file:///!p: =%%20!
java -Xms512M -Xmx1024M -Xss1M -XX:+CMSClassUnloadingEnabled -XX:MaxPermSize=256M %DEBUG_PARAM% %JAVA_OPTS% -Dfile.encoding=UTF-8 -Dinput.encoding=Cp1252 -Dplay.version="%PLAY_VERSION%" -Dsbt.ivy.home="%~dp0..\repository" -Dplay.home="%~dp0." -Dsbt.boot.properties="%fp%sbt/sbt.boot.properties" %PLAY_OPTS% -jar "%~dp0sbt\sbt-launch.jar" %*
:end
endlocal
|
Allow Bridge environment variables to configure Bridge use | echo off
setlocal
REM elevated window does not set current directory correctly.
REM Workaround it by passing the current directory as 1st parameter
pushd %1
certutil -addstore -f root RootCATest.cer
certutil -f -p test -importpfx "WcfTestServer.pfx"
netsh http add sslcert ipport=0.0.0.0:44285 certhash=1d85a3f6cd2c022c5ca54e5cb200a47f89ba0d3d appid={00000000-0000-0000-0000-000000000000}
start powershell -ExecutionPolicy Bypass -File ..\test\Bridge\bin\ensureBridge.ps1 %2 %3 %4 %5 %6 %7
exit /b
| echo off
setlocal
REM elevated window does not set current directory correctly.
REM Workaround it by passing the current directory as 1st parameter
pushd %1
certutil -addstore -f root RootCATest.cer
certutil -f -p test -importpfx "WcfTestServer.pfx"
netsh http add sslcert ipport=0.0.0.0:44285 certhash=1d85a3f6cd2c022c5ca54e5cb200a47f89ba0d3d appid={00000000-0000-0000-0000-000000000000}
if '%BridgeHost%' neq '' (
set _bridgeHostArg=-hostName %BridgeHost%
)
if '%BridgePort%' neq '' (
set _bridgePortArg=-portNumber %BridgePort%
)
if '%BridgeAllowRemote%' neq '' (
set _bridgeAllowRemoteArg=-allowRemote %BridgeAllowRemote%
)
echo Executing: start powershell -ExecutionPolicy Bypass -File ..\test\Bridge\bin\ensureBridge.ps1 %_bridgeHostArg% %_bridgePortArg% %_bridgeAllowRemoteArg%
start powershell -ExecutionPolicy Bypass -File ..\test\Bridge\bin\ensureBridge.ps1 %_bridgeHostArg% %_bridgePortArg% %_bridgeAllowRemoteArg%
exit /b
|
Fix depot_tools\git.bat when depot_tools in not in PATH. | @echo off
setlocal
if not defined EDITOR set EDITOR=notepad
set PATH=%~dp0GIT_BIN_DIR\cmd;%PATH%
"%~dp0GIT_BIN_DIR\GIT_PROGRAM" %*
| @echo off
setlocal
if not defined EDITOR set EDITOR=notepad
set PATH=%~dp0GIT_BIN_DIR\cmd;%~dp0;%PATH%
"%~dp0GIT_BIN_DIR\GIT_PROGRAM" %*
|
Update Windows CI build script. |
set MSBUILD_EXE=C:\Windows\Microsoft.NET\Framework\v3.5\MSBuild
cd 3rd-party\UnitTest++
%MSBUILD_EXE% UnitTest++.vsnet2008.sln /p:Configuration=Debug /target:Clean
%MSBUILD_EXE% UnitTest++.vsnet2008.sln /p:Configuration=Release /target:Clean
%MSBUILD_EXE% UnitTest++.vsnet2008.sln /p:Configuration=Debug
%MSBUILD_EXE% UnitTest++.vsnet2008.sln /p:Configuration=Release
cd ..\..
cmake CMakeLists.txt
%MSBUILD_EXE% libamqp.sln /p:Configuration=Debug /target:Clean
%MSBUILD_EXE% libamqp.sln /p:Configuration=Release /target:Clean
%MSBUILD_EXE% libamqp.sln /p:Configuration=Debug
| @echo off
set DEVENV=C:\Windows\Microsoft.NET\Framework\v3.5\MSBuild
set DEVENV=C:\Program Files\Microsoft Visual Studio 9.0\Common7\IDE\devenv.exe
if exist "%DEVENV%" goto devenv_found
set DEVENV=C:\Program Files(x86)\Microsoft Visual Studio 9.0\Common7\IDE\devenv.exe
if exist "%DEVENV%" goto devenv_found
echo "Please set DEVENV to the location of the devenv.exe program.
got end
:devenv_found
echo "Building UnitTest++"
cd 3rd-party\UnitTest++
"%DEVENV%" UnitTest++.vsnet2008.sln /Rebuild Debug
"%DEVENV%" UnitTest++.vsnet2008.sln /Rebuild Release
cd ..\..
echo "Running CMake"
del CMakeCache.txt /q
del CMakeFiles /s /q
cmake CMakeLists.txt
echo "Building Libamqp"
"%DEVENV%" libamqp.sln /Rebuild Debug
"%DEVENV%" libamqp.sln /Build Debug /project RUN_TESTS
:end
|
Handle spaces in args for batch file | @echo off
rem ======================================================================== rem
rem Copyright 2015-2016 Intel Corporation rem
rem rem
rem Licensed under the Apache License, Version 2.0 (the "License"); rem
rem you may not use this file except in compliance with the License. rem
rem You may obtain a copy of the License at rem
rem rem
rem http://www.apache.org/licenses/LICENSE-2.0 rem
rem rem
rem Unless required by applicable law or agreed to in writing, software rem
rem distributed under the License is distributed on an "AS IS" BASIS, rem
rem WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. rem
rem See the License for the specific language governing permissions and rem
rem limitations under the License. rem
rem ======================================================================== rem
setlocal
md build
cd build
cmake -L ^
-G "%1" ^
-T "%2" ^
-D OSPRAY_BUILD_ISA=ALL ^
-D OSPRAY_BUILD_MIC_SUPPORT=OFF ^
-D OSPRAY_USE_EXTERNAL_EMBREE=ON ^
-D embree_DIR=..\..\embree\lib\cmake\embree-2.9.0 ^
-D USE_IMAGE_MAGICK=OFF ^
..
cmake --build . --config Release --target ALL_BUILD -- /m /nologo
:abort
endlocal
:end
| @echo off
rem ======================================================================== rem
rem Copyright 2015-2016 Intel Corporation rem
rem rem
rem Licensed under the Apache License, Version 2.0 (the "License"); rem
rem you may not use this file except in compliance with the License. rem
rem You may obtain a copy of the License at rem
rem rem
rem http://www.apache.org/licenses/LICENSE-2.0 rem
rem rem
rem Unless required by applicable law or agreed to in writing, software rem
rem distributed under the License is distributed on an "AS IS" BASIS, rem
rem WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. rem
rem See the License for the specific language governing permissions and rem
rem limitations under the License. rem
rem ======================================================================== rem
setlocal
md build
cd build
cmake -L ^
-G "%~1" ^
-T "%~2" ^
-D OSPRAY_BUILD_ISA=ALL ^
-D OSPRAY_BUILD_MIC_SUPPORT=OFF ^
-D OSPRAY_USE_EXTERNAL_EMBREE=ON ^
-D embree_DIR=..\..\embree\lib\cmake\embree-2.9.0 ^
-D USE_IMAGE_MAGICK=OFF ^
..
cmake --build . --config Release --target ALL_BUILD -- /m /nologo
:abort
endlocal
:end
|
Add batch file that creates the directory structure required by the XMC4500 GCC port. | REM This file should be executed from the command line prior to the first
REM build. It will be necessary to refresh the Eclipse project once the
REM .bat file has been executed (normally just press F5 to refresh).
REM Copies all the required files from their location within the standard
REM FreeRTOS directory structure to under the Eclipse project directory.
REM This permits the Eclipse project to be used in 'managed' mode and without
REM having to setup any linked resources.
REM Standard paths
SET FREERTOS_SOURCE=..\..\Source
SET COMMON_SOURCE=..\Common\minimal
SET COMMON_INCLUDE=..\Common\include
REM Have the files already been copied?
IF EXIST src\FreeRTOS_Source Goto END
REM Create the required directory structure.
MD src\FreeRTOS_Source
MD src\FreeRTOS_Source\include
MD src\FreeRTOS_Source\portable\GCC
MD src\FreeRTOS_Source\portable\GCC\ARM_CM4F
MD src\FreeRTOS_Source\portable\MemMang
MD src\Common_Demo_Source
MD src\Common_Demo_Source\include
REM Copy the core kernel files into the SDK projects directory
copy %FREERTOS_SOURCE%\tasks.c src\FreeRTOS_Source
copy %FREERTOS_SOURCE%\queue.c src\FreeRTOS_Source
copy %FREERTOS_SOURCE%\list.c src\FreeRTOS_Source
copy %FREERTOS_SOURCE%\timers.c src\FreeRTOS_Source
REM Copy the common header files into the SDK projects directory
copy %FREERTOS_SOURCE%\include\*.* src\FreeRTOS_Source\include
REM Copy the portable layer files into the projects directory
copy %FREERTOS_SOURCE%\portable\GCC\ARM_CM4F\*.* src\FreeRTOS_Source\portable\GCC\ARM_CM4F
REM Copy the basic memory allocation files into the SDK projects directory
copy %FREERTOS_SOURCE%\portable\MemMang\heap_2.c src\FreeRTOS_Source\portable\MemMang
REM Copy the files that define the common demo tasks.
copy %COMMON_SOURCE%\dynamic.c src\Common_Demo_Source
copy %COMMON_SOURCE%\BlockQ.c src\Common_Demo_Source
copy %COMMON_SOURCE%\death.c src\Common_Demo_Source
copy %COMMON_SOURCE%\blocktim.c src\Common_Demo_Source
copy %COMMON_SOURCE%\semtest.c src\Common_Demo_Source
copy %COMMON_SOURCE%\PollQ.c src\Common_Demo_Source
copy %COMMON_SOURCE%\GenQTest.c src\Common_Demo_Source
copy %COMMON_SOURCE%\recmutex.c src\Common_Demo_Source
copy %COMMON_SOURCE%\sp_flop.c src\Common_Demo_Source
copy %COMMON_SOURCE%\countsem.c src\Common_Demo_Source
copy %COMMON_SOURCE%\integer.c src\Common_Demo_Source
REM Copy the common demo file headers.
copy %COMMON_INCLUDE%\*.h src\Common_Demo_Source\include
: END
| |
Enable .netmf in the gated build. | @REM Copyright (c) Microsoft. All rights reserved.
@REM Licensed under the MIT license. See LICENSE file in the project root for full license information.
setlocal
set build-root=%~dp0..
rem // resolve to fully qualified path
for %%i in ("%build-root%") do set build-root=%%~fi
REM -- C# --
cd %build-root%\csharp\device\build
call build_mf.cmd
if errorlevel 1 goto :eof
cd %build-root%
| |
Fix bug: directory contains space character | @ECHO OFF
@REM ----- INIT SCREEN -----
TITLE Using command line to create new job !!!
COLOR 0f
CLS
@REM ----- SET DEFAULT DIRECTORY -----
SET DIRNAME=%~dp0
IF "%DIRNAME%" == "" SET DIRNAME=.\
@REM ----- GET INFORMATION FOR JOB FROM CONSOLE -----
ECHO --------------- CREATE JOB: %2 ---------------
ECHO.
SET inputResult=%*
IF "%1"=="-n" (
"%DIRNAME%\groovy.bat" "%DIRNAME%\genjob.groovy" %inputResult%
) ELSE (
ECHO "Incorrect format !!!"
ECHO "Correct format of command: "
ECHO "genjob -n <jobName> [-f <strFetchAction>] [-q <strQuery>] [-c <strCommand>] [-d <strDbExec>] [-fp <pathToFile>]"
) | @ECHO OFF
setlocal
@REM ----- INIT SCREEN -----
TITLE Using command line to create new job !!!
COLOR 0f
CLS
@REM ----- SET WIPERDOG HOME DIRECTORY -----
set WIPERDOGHOME=%~dp0..
for %%i in ("%WIPERDOGHOME%") do set WIPERDOGHOME=%%~fsi
cd "%WIPERDOGHOME%\bin"
@REM ----- GET INFORMATION FOR JOB FROM CONSOLE -----
ECHO --------------- CREATE JOB: %2 ---------------
ECHO.
SET inputResult=%*
IF "%1"=="-n" (
"%WIPERDOGHOME%\bin\groovy.bat" "%WIPERDOGHOME%\bin\genjob.groovy" %inputResult%
) ELSE (
ECHO "Incorrect format !!!"
ECHO "Correct format of command: "
ECHO "genjob -n <jobName> [-f <strFetchAction>] [-q <strQuery>] [-c <strCommand>] [-d <strDbExec>] [-fp <pathToFile>]"
)
endlocal |
Add bat file for vim initialization on windows. | mkdir C:\Users\Nathan Mador-House\Documents\gVimPortable\Data\settings\vimfiles\autoload
call git clone git://github.com/tpope/vim-surround C:\Users\Nathan Mador-House\Documents\gVimPortable\Data\settings\vimfiles\autoload\
call git clone git://github.com/tpope/vim-commentary.git C:\Users\Nathan Mador-House\Documents\gVimPortable\Data\settings\vimfiles\autoload\
call git clone https://github.com/easymotion/vim-easymotion C:\Users\Nathan Mador-House\Documents\gVimPortable\Data\settings\vimfiles\autoload\
call git clone https://github.com/kien/rainbow_parentheses.vim C:\Users\Nathan Mador-House\Documents\gVimPortable\Data\settings\vimfiles\autoload\
call git clone https://github.com/itchyny/calendar.vim C:\Users\Nathan Mador-House\Documents\gVimPortable\Data\settings\vimfiles\autoload\
call git clone https://github.com/itchyny/lightline.vim C:\Users\Nathan Mador-House\Documents\gVimPortable\Data\settings\vimfiles\autoload\
call git clone https://github.com/Yggdroot/indentLine C:\Users\Nathan Mador-House\Documents\gVimPortable\Data\settings\vimfiles\autoload\
call git clone https://github.com/Raimondi/delimitMate.git C:\Users\Nathan Mador-House\Documents\gVimPortable\Data\settings\vimfiles\autoload\
| |
Add a batch script for the first commit. | @echo off
:: 启动命令处理器扩展名 启动延缓环境变量扩展名
setlocal ENABLEEXTENSIONS ENABLEDELAYEDEXPANSION
:: 双脱字符的功用
echo Hi there^^!
:: 如果是从图形界面(相对于命令行)启动的,则暂停
echo %cmdcmdline% | find "%~0" > nul
if %errorlevel% EQU 0 pause
::
echo %cmdcmdline% | findstr /c:"%~n0" > nul
if %errorlevel% EQU 0 pause
| |
Stop error by adding space at end of line | java -Xrunhprof:cpu=samples -DWNDBVERSION=1.7 -DWNHOME=C:\nlp\opennlp\opennlp\dictionary\src\ -DWNSEARCHDIR=C:\nlp\WordNet\dict\ -jar output\dictionary-0.1.0.jar %1 -g -h -o -a -s -Oop.txt -over -synsa -antsa -perta -famla -synsn -simsn -antsn -coorn -hypen -hypon -treen -holon -sprtn -smemn -ssubn -hholn -meron -subsn -partn -membn -hmern -nomnn -attrn -famln -synsv -simsv -antsv -coorv -hypev -hypov -treev -tropv -entav -causv -nomnv -framv -famlv -synsr -antsr -pertr -famlr
| java -Xrunhprof:cpu=samples -DWNDBVERSION=1.7 -DWNHOME=C:\nlp\opennlp\opennlp\dictionary\src\ -DWNSEARCHDIR=C:\nlp\WordNet\dict\ -jar output\dictionary-0.1.0.jar %1 -g -h -o -a -s -Oop.txt -over -synsa -antsa -perta -famla -synsn -simsn -antsn -coorn -hypen -hypon -treen -holon -sprtn -smemn -ssubn -hholn -meron -subsn -partn -membn -hmern -nomnn -attrn -famln -synsv -simsv -antsv -coorv -hypev -hypov -treev -tropv -entav -causv -nomnv -framv -famlv -synsr -antsr -pertr -famlr
|
Update bat file for Python 3 build | REM Set variables for Microsoft Visual Studio for Python 2.7
REM @call "C:\Users\michaelh3\AppData\Local\Programs\Common\Microsoft\Visual C++ for Python\9.0\vcvarsall.bat" amd64
REM Set environ as workaround for bugs (See http://stackoverflow.com/questions/2817869/error-unable-to-find-vcvarsall-bat and http://bugs.python.org/issue23246)
REM SET DISTUTILS_USE_SDK=1
REM SET MSSdk=1
@call "C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\vcvarsall.bat" x86_amd64
REM Test build
python setup.py sdist bdist_wheel
REM Upload to PyPi
REM python setup.py sdist bdist_wheel upload
| REM Set variables for Microsoft Visual Studio for Python 2.7
REM @call "C:\Users\michaelh3\AppData\Local\Programs\Common\Microsoft\Visual C++ for Python\9.0\vcvarsall.bat" amd64
REM Set environ as workaround for bugs (See http://stackoverflow.com/questions/2817869/error-unable-to-find-vcvarsall-bat and http://bugs.python.org/issue23246)
REM SET DISTUTILS_USE_SDK=1
REM SET MSSdk=1
REM Set variables for Microsoft Visual Studio for Python 3.6
@call "C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\vcvarsall.bat" x86_amd64
REM Test build
python setup.py sdist bdist_wheel
REM Upload to PyPi
REM python setup.py sdist bdist_wheel upload
|
Add missing gradle wrapper file | @if "%DEBUG%" == "" @echo off
@rem ##########################################################################
@rem
@rem Gradle startup script for Windows
@rem
@rem ##########################################################################
@rem Set local scope for the variables with windows NT shell
if "%OS%"=="Windows_NT" setlocal
set DIRNAME=%~dp0
if "%DIRNAME%" == "" set DIRNAME=.
set APP_BASE_NAME=%~n0
set APP_HOME=%DIRNAME%
@rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
set DEFAULT_JVM_OPTS="-Xmx64m"
@rem Find java.exe
if defined JAVA_HOME goto findJavaFromJavaHome
set JAVA_EXE=java.exe
%JAVA_EXE% -version >NUL 2>&1
if "%ERRORLEVEL%" == "0" goto init
echo.
echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
echo.
echo Please set the JAVA_HOME variable in your environment to match the
echo location of your Java installation.
goto fail
:findJavaFromJavaHome
set JAVA_HOME=%JAVA_HOME:"=%
set JAVA_EXE=%JAVA_HOME%/bin/java.exe
if exist "%JAVA_EXE%" goto init
echo.
echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME%
echo.
echo Please set the JAVA_HOME variable in your environment to match the
echo location of your Java installation.
goto fail
:init
@rem Get command-line arguments, handling Windows variants
if not "%OS%" == "Windows_NT" goto win9xME_args
:win9xME_args
@rem Slurp the command line arguments.
set CMD_LINE_ARGS=
set _SKIP=2
:win9xME_args_slurp
if "x%~1" == "x" goto execute
set CMD_LINE_ARGS=%*
:execute
@rem Setup the command line
set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar
@rem Execute Gradle
"%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %CMD_LINE_ARGS%
:end
@rem End local scope for the variables with windows NT shell
if "%ERRORLEVEL%"=="0" goto mainEnd
:fail
rem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of
rem the _cmd.exe /c_ return code!
if not "" == "%GRADLE_EXIT_CONSOLE%" exit 1
exit /b 1
:mainEnd
if "%OS%"=="Windows_NT" endlocal
:omega
| |
Move NuGet.exe restore location back to the root | @echo off
REM This is a script that will set environment information about where to find
REM NuGet.exe, it's version and ensure that it's present on the enlistment.
set NuGetExeVersion=3.5.0-beta2
set NuGetExeFolder=%~dp0..\..\Binaries\Download\%NuGetExeVersion%
set NuGetExe=%NuGetExeFolder%\NuGet.exe
REM Download NuGet.exe if we haven't already
if not exist "%NuGetExe%" (
echo Downloading NuGet %NuGetExeVersion%
powershell -noprofile -executionPolicy RemoteSigned -file "%~dp0download-nuget.ps1" "%NuGetExeVersion%" "%NuGetExeFolder%" || goto :DownloadNuGetFailed
)
| @echo off
REM This is a script that will set environment information about where to find
REM NuGet.exe, it's version and ensure that it's present on the enlistment.
set NuGetExeVersion=3.5.0-beta2
set NuGetExeFolder=%~dp0..\..
set NuGetExe=%NuGetExeFolder%\NuGet.exe
REM Download NuGet.exe if we haven't already
if not exist "%NuGetExe%" (
echo Downloading NuGet %NuGetExeVersion%
powershell -noprofile -executionPolicy RemoteSigned -file "%~dp0download-nuget.ps1" "%NuGetExeVersion%" "%NuGetExeFolder%" || goto :DownloadNuGetFailed
)
|
Fix unit test run error on UWP by not running them | @REM Copyright (c) Microsoft. All rights reserved.
@REM Licensed under the MIT license. See LICENSE file in the project root for full license information.
setlocal
set build-root=%~dp0..
rem // resolve to fully qualified path
for %%i in ("%build-root%") do set build-root=%%~fi
REM -- C --
cd %build-root%\tools
call build_dotnet.cmd %*
if errorlevel 1 goto :eof
call build_uwp.cmd %*
if errorlevel 1 goto :eof
cd %build-root% | @REM Copyright (c) Microsoft. All rights reserved.
@REM Licensed under the MIT license. See LICENSE file in the project root for full license information.
setlocal
set build-root=%~dp0..
rem // resolve to fully qualified path
for %%i in ("%build-root%") do set build-root=%%~fi
REM -- C --
cd %build-root%\tools
call build_dotnet.cmd %*
if errorlevel 1 goto :eof
call build_uwp.cmd --skip-unittests %*
if errorlevel 1 goto :eof
cd %build-root% |
Update test to check for existence of app-local msbuild instead of version number | @echo off
REM This is a script that will set environment information about where to find
REM NuGet.exe, it's version and ensure that it's present on the enlistment.
set NuGetExeVersion=3.6.0-beta1
set NuGetExeFolder=%~dp0..\..
set NuGetExe=%NuGetExeFolder%\NuGet.exe
if "%VisualStudioVersion%" == "15.0" (
set NuGetAdditionalCommandLineArgs=-verbosity quiet -configfile "%NuGetExeFolder%\nuget.config" -Project2ProjectTimeOut 1200 -msbuildpath "%DevenvDir%\..\..\MSBuild\15.0\Bin"
) else (
set NuGetAdditionalCommandLineArgs=-verbosity quiet -configfile "%NuGetExeFolder%\nuget.config" -Project2ProjectTimeOut 1200
)
REM Download NuGet.exe if we haven't already
if not exist "%NuGetExe%" (
echo Downloading NuGet %NuGetExeVersion%
powershell -noprofile -executionPolicy Bypass -file "%~dp0download-nuget.ps1" "%NuGetExeVersion%" "%NuGetExeFolder%" || goto :DownloadNuGetFailed
)
| @echo off
REM This is a script that will set environment information about where to find
REM NuGet.exe, it's version and ensure that it's present on the enlistment.
set NuGetExeVersion=3.6.0-beta1
set NuGetExeFolder=%~dp0..\..
set NuGetExe=%NuGetExeFolder%\NuGet.exe
REM If we have an applocal copy of MSBuild, pass it to NuGet. Otherwise, assume NuGet knows how to find it.
if exist "%DevenvDir%\..\..\MSBuild\15.0\Bin\MSBuild.exe" (
set NuGetAdditionalCommandLineArgs=-verbosity quiet -configfile "%NuGetExeFolder%\nuget.config" -Project2ProjectTimeOut 1200 -msbuildpath "%DevenvDir%\..\..\MSBuild\15.0\Bin"
) else (
set NuGetAdditionalCommandLineArgs=-verbosity quiet -configfile "%NuGetExeFolder%\nuget.config" -Project2ProjectTimeOut 1200
)
REM Download NuGet.exe if we haven't already
if not exist "%NuGetExe%" (
echo Downloading NuGet %NuGetExeVersion%
powershell -noprofile -executionPolicy Bypass -file "%~dp0download-nuget.ps1" "%NuGetExeVersion%" "%NuGetExeFolder%" || goto :DownloadNuGetFailed
)
|
Use REM for comments to avoid error messages on the DOS prompt for Windows users | # This is for windows users only.
# If you're on a mac or linux, just run `ant build` from this folder in Terminal
set MYDIR=%~dp0
set ANT_OPTS=-D"file.encoding=UTF-8"
ant build | REM # This is for windows users only.
REM # If you're on a mac or linux, just run `ant build` from this folder in Terminal
set MYDIR=%~dp0
set ANT_OPTS=-D"file.encoding=UTF-8"
ant build |
Make working in Command Prompt slightly more bearable | @ECHO OFF
REM Uncomment to enable verbose mode
REM SET VERBOSE=YES
REM Because I'm tired of forgetting this
DOSKEY ls=dir
DOSKEY man=help
DOSKEY which=where
REM Add alias for Sublime Text
SET SUBLREGPATH=HKLM\Software\Microsoft\Windows\CurrentVersion\Uninstall\Sublime Text 2_is1
SET SUBLBINNAME=sublime_text.exe
REG QUERY "%SUBLREGPATH%" /v InstallLocation > NUL 2>&1
IF NOT ERRORLEVEL 1 (
FOR /F "tokens=2*" %%a IN ('REG QUERY "%SUBLREGPATH%" /v InstallLocation ^| FINDSTR /R "[a-z]:\\.*\\$"') DO @SET SUBLDIRPATH=%%b
DOSKEY subl="%SUBLDIRPATH%%SUBLBINNAME%" $*
) ELSE (
IF DEFINED VERBOSE ECHO Couldn't locate Sublime Text install; not adding 'subl' alias.
)
FOR /F "delims==" %%i IN ('SET SUBL') DO @SET %%i=
| |
Add push package script :cow: | ..\.nuget\NuGet.exe push ..\Topshelf.Autofac\bin\Release\Topshelf.Autofac.*.nupkg -Source https://www.nuget.org/api/v2/package
| |
Add ability to generate nunit test results | @pushd %~dp0
ECHO Remember to build the solution first!
REM pause
"%~dp0\TestHarness\packages\NUnit.Runners.2.6.3\tools\nunit-console.exe" "%~dp0\TestHarness\nunit\bin\Debug\nunitHarness.dll" /result=results-example-nunit.xml /nologo /nodots
pause
@popd | |
Add a check for 32-bit vs 64-bit OS and then use the appropriate python | @echo off
REM
REM Verify that we can find the 'makepanda' python script
REM and the python interpreter. If we can find both, then
REM run 'makepanda'.
REM
set thirdparty=thirdparty
if defined MAKEPANDA_THIRDPARTY set thirdparty=%MAKEPANDA_THIRDPARTY%
if not exist makepanda\makepanda.py goto :missing1
if not exist %thirdparty%\win-python\python.exe goto :missing2
%thirdparty%\win-python\python.exe makepanda\makepanda.py %*
if errorlevel 1 if x%1 == x--slavebuild exit 1
goto done
:missing1
echo You need to change directory to the root of the panda source tree
echo before invoking makepanda. For further install instructions, read
echo the installation instructions in the file doc/INSTALL-MK.
goto done
:missing2
echo You seem to be missing the 'thirdparty' directory. You probably checked
echo the source code out from sourceforge. The sourceforge repository is
echo missing the 'thirdparty' directory. You will need to supplement the
echo code by downloading the 'thirdparty' directory from www.panda3d.org
goto done
:done
| @echo off
REM
REM Check the Windows architecture and determine with Python
REM to use; 64-bit or 32-bit. Verify that we can find the
REM 'makepanda' python script and the python interpreter.
REM If we can find both, then run 'makepanda'.
REM
if %PROCESSOR_ARCHITECTURE% == AMD64 (
set pythondir=win-python-x64
) else (
set pythondir=win-python
)
set thirdparty=thirdparty
if defined MAKEPANDA_THIRDPARTY set thirdparty=%MAKEPANDA_THIRDPARTY%
if not exist makepanda\makepanda.py goto :missing1
if not exist %thirdparty%\%pythondir%\python.exe goto :missing2
%thirdparty%\%pythondir%\python.exe makepanda\makepanda.py %*
if errorlevel 1 if x%1 == x--slavebuild exit 1
goto done
:missing1
echo You need to change directory to the root of the panda source tree
echo before invoking makepanda. For further install instructions, read
echo the installation instructions in the file doc/INSTALL-MK.
goto done
:missing2
echo %thirdparty%
echo You seem to be missing the 'thirdparty' directory. You probably checked
echo the source code out from sourceforge. The sourceforge repository is
echo missing the 'thirdparty' directory. You will need to supplement the
echo code by downloading the 'thirdparty' directory from www.panda3d.org
goto done
:done
|
Add release script for windows | @echo off
if "%~1" == "" (
echo Usage: release_win.bat path-to-bin-folder
goto end
)
setlocal
set destdir="%cd%\%~1"
mkdir build
cd build
del CMakeCache.txt rem make sure to use default settings
cmake -D CMAKE_INSTALL_PREFIX=%destdir% -G "Visual Studio 12 2013 Win64" ..
ICProjConvert150 embree.sln /IC /s /f
cmake --build . --config Release --target INSTALL -- /m
cd ..
endlocal
:end
| |
Deploy feet version to own folder | @echo off
set BASENAME=Geocache_Height
set BASEPATH=%HOMEPATH%\Documents\Dev\GitHub\userscripts\GeocacheHeight
set DEPLOYPATH=%APPDATA%\Mozilla\Firefox\Profiles\6rhioilk.default\gm_scripts\%BASENAME%
cd "%BASEPATH%"
copy "src\%BASENAME%.meta.js" .
copy /b "src\%BASENAME%.meta.js" + src\header.js + "src\formatHeight.js" + "src\%BASENAME%.js" + src\footer.js ".\%BASENAME%.user.js"
copy %BASENAME%.meta.js %DEPLOYPATH%
copy %BASENAME%.user.js %DEPLOYPATH%
copy "src\%BASENAME%_feet.meta.js" .
copy /b "src\%BASENAME%_feet.meta.js" + src\header.js + "src\formatHeight_feet.js" + "src\%BASENAME%.js" + src\footer.js ".\%BASENAME%_feet.user.js"
copy %BASENAME%_feet.meta.js %DEPLOYPATH%
copy %BASENAME%_feet.user.js %DEPLOYPATH%
set BASENAME=
set BASEPATH= | @echo off
set BASENAME=Geocache_Height
set BASEPATH=%HOMEPATH%\Documents\Dev\GitHub\userscripts\GeocacheHeight
set DEPLOYPATH=%APPDATA%\Mozilla\Firefox\Profiles\6rhioilk.default\gm_scripts\%BASENAME%
cd "%BASEPATH%"
copy "src\%BASENAME%.meta.js" .
copy /b "src\%BASENAME%.meta.js" + src\header.js + "src\formatHeight.js" + "src\%BASENAME%.js" + src\footer.js ".\%BASENAME%.user.js"
copy %BASENAME%.meta.js %DEPLOYPATH%
copy %BASENAME%.user.js %DEPLOYPATH%
copy "src\%BASENAME%_feet.meta.js" .
copy /b "src\%BASENAME%_feet.meta.js" + src\header.js + "src\formatHeight_feet.js" + "src\%BASENAME%.js" + src\footer.js ".\%BASENAME%_feet.user.js"
copy %BASENAME%_feet.meta.js %DEPLOYPATH%_(feet)
copy %BASENAME%_feet.user.js %DEPLOYPATH%_(feet)
set BASENAME=
set BASEPATH= |
Update to work with common | setlocal
set BUILDER_START_DIR=
set BUILDER_TOP_DIR=
set BUILDROOT_DIR=
set __CMD_INIT_RUN__=
%PYTHON% wb_git_main.py %*
endlocal
| setlocal
set PYTHONPATH=%BUILDER_TOP_DIR%\Source;%BUILDER_TOP_DIR%\Source\Common
set BUILDER_START_DIR=
set BUILDER_TOP_DIR=
set BUILDROOT_DIR=
set __CMD_INIT_RUN__=
echo PYTHONPATH %PYTHONPATH%
%PYTHON% wb_git_main.py %*
endlocal
|
Fix labels in the cmd script | @echo off
setlocal
set "output=nul"
set "times=1"
:help
:parseArgs
if "%~1" == "" goto main
if /i "%~1" == "-?" goto help
if /i "%~1" == "-h" goto help
if /i "%~1" == "--help" goto help
if /i "%~1" == "-t" (
set "times=%~2"
shift
)
if /i "%~1" == "--times" (
set "times=%~2"
shift
)
if /i "%~1" == "-o" (
set "output=%~2"
shift
)
if /i "%~1" == "--output" (
set "output=%~2"
shift
)
shift
:curl
@powershell -NoProfile "iwr %~1 -OutFile %~2" 2> nul
goto :eof
:downloadPackage
set "url=https://www.nuget.org/api/v2/package/%~1"
call :curl "%url%" %2
goto :eof
:main
for /l %%i in (1, 1, %times%) do (
call :downloadPackage "%package%" "%output%"
)
| @echo off
setlocal
set "output=nul"
set "times=1"
:help
goto :eof
:parseArgs
if "%~1" == "" goto main
if /i "%~1" == "-?" goto help
if /i "%~1" == "-h" goto help
if /i "%~1" == "--help" goto help
if /i "%~1" == "-t" (
set "times=%~2"
shift
)
if /i "%~1" == "--times" (
set "times=%~2"
shift
)
if /i "%~1" == "-o" (
set "output=%~2"
shift
)
if /i "%~1" == "--output" (
set "output=%~2"
shift
)
shift
goto parseArgs
:curl
@powershell -NoProfile "iwr %~1 -OutFile %~2" 2> nul
goto :eof
:downloadPackage
set "url=https://www.nuget.org/api/v2/package/%~1"
call :curl "%url%" %2
goto :eof
:main
for /l %%i in (1, 1, %times%) do (
call :downloadPackage "%package%" "%output%"
)
|
Change baseline path for Win to avoid problematic drive letter | @echo off
rem ======================================================================== rem
rem Copyright 2015-2017 Intel Corporation rem
rem rem
rem Licensed under the Apache License, Version 2.0 (the "License"); rem
rem you may not use this file except in compliance with the License. rem
rem You may obtain a copy of the License at rem
rem rem
rem http://www.apache.org/licenses/LICENSE-2.0 rem
rem rem
rem Unless required by applicable law or agreed to in writing, software rem
rem distributed under the License is distributed on an "AS IS" BASIS, rem
rem WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. rem
rem See the License for the specific language governing permissions and rem
rem limitations under the License. rem
rem ======================================================================== rem
setlocal
echo Running tests
md failed
set OSP_LIBS=build\Release
set BASELINE_DIR=N:\OSPRay\test-data\img\
set PATH=%PATH%;%OSP_LIBS%;%embree_DIR%\bin
call build\regression_tests\Release\ospray_test_suite.exe --gtest_output=xml:tests.xml --baseline-dir=%BASELINE_DIR%
exit /B %ERRORLEBEL%
endlocal
| @echo off
rem ======================================================================== rem
rem Copyright 2015-2017 Intel Corporation rem
rem rem
rem Licensed under the Apache License, Version 2.0 (the "License"); rem
rem you may not use this file except in compliance with the License. rem
rem You may obtain a copy of the License at rem
rem rem
rem http://www.apache.org/licenses/LICENSE-2.0 rem
rem rem
rem Unless required by applicable law or agreed to in writing, software rem
rem distributed under the License is distributed on an "AS IS" BASIS, rem
rem WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. rem
rem See the License for the specific language governing permissions and rem
rem limitations under the License. rem
rem ======================================================================== rem
setlocal
echo Running tests
md failed
set OSP_LIBS=build\Release
set BASELINE_DIR=\\sdvis-nas\NAS\OSPRay\test-data\img\
set PATH=%PATH%;%OSP_LIBS%;%embree_DIR%\bin
call build\regression_tests\Release\ospray_test_suite.exe --gtest_output=xml:tests.xml --baseline-dir=%BASELINE_DIR%
exit /B %ERRORLEBEL%
endlocal
|
Fix quoting of ES_JAVA_OPTS in plugin script | @echo off
setlocal enabledelayedexpansion
setlocal enableextensions
set ES_JAVA_OPTS="--add-opens java.base/sun.security.provider=ALL-UNNAMED %ES_JAVA_OPTS%"
set ES_MAIN_CLASS=org.elasticsearch.plugins.PluginCli
set ES_ADDITIONAL_CLASSPATH_DIRECTORIES=lib/tools/plugin-cli
call "%~dp0elasticsearch-cli.bat" ^
%%* ^
|| goto exit
endlocal
endlocal
:exit
exit /b %ERRORLEVEL%
| @echo off
setlocal enabledelayedexpansion
setlocal enableextensions
set ES_JAVA_OPTS=--add-opens java.base/sun.security.provider=ALL-UNNAMED %ES_JAVA_OPTS%
set ES_MAIN_CLASS=org.elasticsearch.plugins.PluginCli
set ES_ADDITIONAL_CLASSPATH_DIRECTORIES=lib/tools/plugin-cli
call "%~dp0elasticsearch-cli.bat" ^
%%* ^
|| goto exit
endlocal
endlocal
:exit
exit /b %ERRORLEVEL%
|
Call msbuild from build script | @echo off
"%PROGRAMFILES%\7-Zip\7z" a -tzip "AITD-tools.zip" ^
".\CacheViewer\CacheViewer\bin\Release\*.exe" ^
".\LifeDISA\LifeDISA\bin\Release\*.exe" ^
".\LifeDISA\LifeDISA\bin\Release\UnPAK.dll" ^
".\MemoryViewer\MemoryViewer\bin\Release\*.exe" ^
".\MemoryViewer\MemoryViewer\bin\Release\SDL.dll" ^
".\MemoryViewer\MemoryViewer\bin\Release\SDL2.dll" ^
".\MemoryViewer\MemoryViewer\bin\Release\SDL2_image.dll" ^
".\MemoryViewer\MemoryViewer\bin\Release\Shared.dll" ^
".\TrackDISA\TrackDISA\bin\Release\*.exe" ^
".\VarsViewer\VarsViewer\bin\Release\*.exe"
| @echo off
%WINDIR%\Microsoft.NET\Framework\v4.0.30319\msbuild.exe /p:Configuration=Release ".\CacheViewer\CacheViewer.sln"
if %ERRORLEVEL% NEQ 0 pause
%WINDIR%\Microsoft.NET\Framework\v4.0.30319\msbuild.exe /p:Configuration=Release ".\LifeDISA\LifeDISA.sln"
if %ERRORLEVEL% NEQ 0 pause
%WINDIR%\Microsoft.NET\Framework\v4.0.30319\msbuild.exe /p:Configuration=Release ".\MemoryViewer\MemoryViewer.sln"
if %ERRORLEVEL% NEQ 0 pause
%WINDIR%\Microsoft.NET\Framework\v4.0.30319\msbuild.exe /p:Configuration=Release ".\TrackDISA\TrackDISA.sln"
if %ERRORLEVEL% NEQ 0 pause
%WINDIR%\Microsoft.NET\Framework\v4.0.30319\msbuild.exe /p:Configuration=Release ".\VarsViewer\VarsViewer.sln"
if %ERRORLEVEL% NEQ 0 pause
"%PROGRAMFILES%\7-Zip\7z" a -tzip "AITD-tools.zip" ^
".\CacheViewer\CacheViewer\bin\Release\*.exe" ^
".\LifeDISA\LifeDISA\bin\Release\*.exe" ^
".\LifeDISA\LifeDISA\bin\Release\UnPAK.dll" ^
".\MemoryViewer\MemoryViewer\bin\Release\*.exe" ^
".\MemoryViewer\MemoryViewer\bin\Release\SDL.dll" ^
".\MemoryViewer\MemoryViewer\bin\Release\SDL2.dll" ^
".\MemoryViewer\MemoryViewer\bin\Release\SDL2_image.dll" ^
".\MemoryViewer\MemoryViewer\bin\Release\Shared.dll" ^
".\TrackDISA\TrackDISA\bin\Release\*.exe" ^
".\VarsViewer\VarsViewer\bin\Release\*.exe" ^
"-mx=9"
if %ERRORLEVEL% NEQ 0 pause |
Add script to build dev version | REM First Run the prepare tasks for each task:
REM triggerbuildtask\perpareTriggerBuildTask.bat
REM waitforbuildtask\perpareWaitForBuildTask.bat
REM Don't forget to increase the version!
tfx extension create --manifest-globs .\vss-extension_dev.json | |
Add gradle --configure-on-demand flag to bintray upload script | @echo off
setlocal EnableDelayedExpansion
REM Uploading all modules at once (with one gradle command) does not work any more, so a separate command for each module must be issued
SET username=%1
SET apikey=%2
SET modules="MediaPlayer" "MediaPlayer-DASH"
FOR %%m in (%modules%) DO (
gradlew %%~m:clean %%~m:build %%~m:bintrayUpload -PbintrayUser=%username% -PbintrayKey=%apikey% -PdryRun=false
)
| @echo off
setlocal EnableDelayedExpansion
REM Uploading all modules at once (with one gradle command) does not work any more, so a separate command for each module must be issued
SET username=%1
SET apikey=%2
SET modules="MediaPlayer" "MediaPlayer-DASH"
FOR %%m in (%modules%) DO (
gradlew %%~m:clean %%~m:build %%~m:bintrayUpload -PbintrayUser=%username% -PbintrayKey=%apikey% -PdryRun=false --configure-on-demand
)
|
Remove copyall in order to copy to network share | ### this file is a sample taken from mongo-c-driver-legacy-build. must be adapted to new driver ####
robocopy ..\bin\Win32\Debug\ %1\user\mongoc-dll\ mongo-client*.dll /ZB /X /COPYALL /TEE
robocopy ..\bin\Win32\Release\ %1\user\mongoc-dll\ mongo-client*.dll /ZB /X /COPYALL /TEE
robocopy ..\bin\x64\Debug\ %1\user\mongoc-dll\ mongo-client*.dll /ZB /X /COPYALL /TEE
robocopy ..\bin\x64\Release\ %1\user\mongoc-dll\ mongo-client*.dll /ZB /X /COPYALL /TEE
EXIT /B 0 | ### this file is a sample taken from mongo-c-driver-legacy-build. must be adapted to new driver ####
robocopy ..\bin\Win32\Debug\ %1\user\mongoc-dll\ mongo-client*.dll /ZB /X /TEE
robocopy ..\bin\Win32\Release\ %1\user\mongoc-dll\ mongo-client*.dll /ZB /X /TEE
robocopy ..\bin\x64\Debug\ %1\user\mongoc-dll\ mongo-client*.dll /ZB /X /TEE
robocopy ..\bin\x64\Release\ %1\user\mongoc-dll\ mongo-client*.dll /ZB /X /TEE
EXIT /B 0
|
Add installing NuGet packages to build bat file | pushd NCDK
call :BuildProject NCDK
popd
pushd NCDKDisplay
call :BuildProject NCDK.Display
popd
goto END
:BuildProject
set ProjectName=%1
if "%ProjectName%" == "" exit 1
MSBuild "%ProjectName%.csproj" /t:Build /p:Configuration=Release
nuget pack "%ProjectName%.nuspec" -Prop Configuration=Release -IncludeReferencedProjects
if "%MyNuGetDir%" neq "" (
xcopy /D /Y "*.nupkg" "%MyNuGetDir%"
del /Q "*.nupkg"
)
set ProjectName=
exit /b
:END
| pushd NCDK
dotnet add package MathNet.Numerics.Signed
dotnet add package dotNetRDF
call :BuildProject NCDK
popd
pushd NCDKDisplay
call :BuildProject NCDK.Display
popd
goto END
:BuildProject
set ProjectName=%1
if "%ProjectName%" == "" exit 1
MSBuild "%ProjectName%.csproj" /t:Build /p:Configuration=Release
nuget pack "%ProjectName%.nuspec" -Prop Configuration=Release -IncludeReferencedProjects
if "%MyNuGetDir%" neq "" (
xcopy /D /Y "*.nupkg" "%MyNuGetDir%"
del /Q "*.nupkg"
)
set ProjectName=
exit /b
:END
|
Fix error propagation for windows x64 build script | set path=%userprofile%\Downloads\instantclient-basic-windows.x64-12.1.0.1.0\instantclient_12_1\vc11;%userprofile%\Downloads\instantclient-basic-windows.x64-12.1.0.1.0\instantclient_12_1;%path%
copy packages\oracledart\oracledart_extension.dll packages\oracledart\oracledart_extension_ia32.dll
copy packages\oracledart\oracledart_extension_x64.dll packages\oracledart\oracledart_extension.dll
..\build\ReleaseX64\dart oracledart_test.dart
del packages\oracledart\oracledart_extension.dll
copy packages\oracledart\oracledart_extension_ia32.dll packages\oracledart\oracledart_extension.dll
del packages\oracledart\oracledart_extension_ia32.dll | set path=%userprofile%\Downloads\instantclient-basic-windows.x64-12.1.0.1.0\instantclient_12_1\vc11;%userprofile%\Downloads\instantclient-basic-windows.x64-12.1.0.1.0\instantclient_12_1;%path%
copy packages\oracledart\oracledart_extension.dll packages\oracledart\oracledart_extension_ia32.dll
copy packages\oracledart\oracledart_extension_x64.dll packages\oracledart\oracledart_extension.dll
..\build\ReleaseX64\dart oracledart_test.dart
set buildexitcode=%ERRORLEVEL%
del packages\oracledart\oracledart_extension.dll
copy packages\oracledart\oracledart_extension_ia32.dll packages\oracledart\oracledart_extension.dll
del packages\oracledart\oracledart_extension_ia32.dll
exit /b %buildexitcode% |
Build header and footer properly | Set DecorateName=DecorateName
Set Book=mencius
Set FontType=Traditional
Set BookFont=%Book%_%FontType%
Set CSSExt=.css
Set CSS_=--css=..\css\
Set NameStyle=%CSS_%%DecorateName%%CSSExt%
Set Output=%BookFont%
If "%1" == "name" (
Set Output=%Output%_%DecorateName%
Set Style=%NameStyle%
)
If Not "%2" == "" (
Set Output=%Output%_%2
Set Style=%Style% %CSS_%%2%CSSExt%
)
If Not "%3" == "" (
Set Output=%Output%_%3
Set Style=%Style% %CSS_%%3%CSSExt%
)
Set HTMLExt=.html
Set HTMLOutput=%Output%%HTMLExt%
Call pandoc ..\source\%Book%.md -o %HTMLOutput% --standalone --toc %Style% --verbose
Call wkhtmltopdf.exe --margin-top 15 --margin-bottom 15 --header-center [section] --header-left [subsection] --header-right [page] --header-line --header-spacing 5 --footer-center "Version 0.1" --footer-line --footer-spacing 5 %HTMLOutput% %Output%.pdf | Set DecorateName=DecorateName
Set Book=mencius
Set FontType=Traditional
Set BookFont=%Book%_%FontType%
Set CSSExt=.css
Set CSS_=--css=..\css\
Set NameStyle=%CSS_%%DecorateName%%CSSExt%
Set Output=%BookFont%
If "%1" == "name" (
Set Output=%Output%_%DecorateName%
Set Style=%NameStyle%
)
If Not "%2" == "" (
Set Output=%Output%_%2
Set Style=%Style% %CSS_%%2%CSSExt%
)
If Not "%3" == "" (
Set Output=%Output%_%3
Set Style=%Style% %CSS_%%3%CSSExt%
)
Set HTMLExt=.html
Set HTMLOutput=%Output%%HTMLExt%
Call pandoc ..\source\%Book%.md -o %HTMLOutput% --standalone --toc %Style% --verbose
Call wkhtmltopdf.exe --margin-top 15 --header-spacing 5 --header-right [subsection] --header-line --margin-bottom 15 --footer-spacing 5 --footer-left "Dujing Academy" --footer-right [page]/[topage] --footer-line --footer-font-size 5 %HTMLOutput% %Output%.pdf |
Use REM for comments to avoid error messages on the DOS prompt for Windows users | # This is for windows users only.
# If you're on a mac or linux, just run `ant build` from this folder in Terminal
set MYDIR=%~dp0
set ANT_OPTS=-D"file.encoding=UTF-8"
ant build | REM # This is for windows users only.
REM # If you're on a mac or linux, just run `ant build` from this folder in Terminal
set MYDIR=%~dp0
set ANT_OPTS=-D"file.encoding=UTF-8"
ant build |
Correct output path for nuget pack command | copy ..\README.md ..\Output
copy ..\LICENSE ..\Output
copy ..\AUTHORS ..\Output
copy ..\CONTRIBUTORS ..\Output
mkdir ..\Output\lib
mkdir ..\Output\lib\MonoTouch
mkdir ..\Output\lib\MonoAndroid
mkdir ..\Output\lib\Xamarin.iOS10
copy ..\Output\XamarinIOS\OxyPlot.XamarinIOS.??? ..\Output\lib\MonoTouch
copy ..\Output\XamarinAndroid\OxyPlot.XamarinAndroid.??? ..\Output\lib\MonoAndroid
copy ..\Output\Xamarin.iOS\OxyPlot.Xamarin.iOS.??? ..\Output\lib\Xamarin.iOS10
copy ..\Source\OxyPlot.XamarinIOS\*.nuspec ..\Output
copy ..\Source\OxyPlot.XamarinAndroid\*.nuspec ..\Output
nuget pack ..\Output\OxyPlot.XamarinIOS.nuspec -OutputDirectory ..\Output
nuget pack ..\Output\OxyPlot.XamarinAndroid.nuspec -OutputDirectory ..\Output
nuget pack ..\Source\OxyPlot.XamarinForms/OxyPlot.XamarinForms.nuspec -OutputDirectory ../Output
pause | copy ..\README.md ..\Output
copy ..\LICENSE ..\Output
copy ..\AUTHORS ..\Output
copy ..\CONTRIBUTORS ..\Output
mkdir ..\Output\lib
mkdir ..\Output\lib\MonoTouch
mkdir ..\Output\lib\MonoAndroid
mkdir ..\Output\lib\Xamarin.iOS10
copy ..\Output\XamarinIOS\OxyPlot.XamarinIOS.??? ..\Output\lib\MonoTouch
copy ..\Output\XamarinAndroid\OxyPlot.XamarinAndroid.??? ..\Output\lib\MonoAndroid
copy ..\Output\Xamarin.iOS\OxyPlot.Xamarin.iOS.??? ..\Output\lib\Xamarin.iOS10
copy ..\Source\OxyPlot.XamarinIOS\*.nuspec ..\Output
copy ..\Source\OxyPlot.XamarinAndroid\*.nuspec ..\Output
nuget pack ..\Output\OxyPlot.XamarinIOS.nuspec -OutputDirectory ..\Output
nuget pack ..\Output\OxyPlot.XamarinAndroid.nuspec -OutputDirectory ..\Output
nuget pack ..\Source\OxyPlot.XamarinForms/OxyPlot.XamarinForms.nuspec -OutputDirectory ..\Output
pause |
Call the testing batch files, don't just go there permanently. | cd /d "%~dp0"
cd ..
rmdir /s /q install
rmdir /s /q build
mkdir build
cd build
cmake .. -G "Visual Studio 12" "-DCMAKE_INSTALL_PREFIX=%WORKSPACE%\install" %*
cmake --build . --config Debug
cmake --build . --config RelWithDebInfo
"%WORKSPACE%\vendor\jenkins-ctest-plugin\run-test-and-save.bat" -C Debug
"%WORKSPACE%\vendor\jenkins-ctest-plugin\run-test-and-save.bat" -C RelWithDebInfo
cmake --build . --config Debug --target INSTALL
cmake --build . --config RelWithDebInfo --target INSTALL
cmake --build . --config RelWithDebInfo --target ogvrPluginKit -- /p:RunCodeAnalysis=True
rem bin\Debug\LoadTest.exe --gtest_output=xml:test_details.Debug.xml
rem bin\RelWithDebInfo\LoadTest.exe --gtest_output=xml:test_details.RelWithDebInfo.xml
pause | cd /d "%~dp0"
cd ..
rmdir /s /q install
rmdir /s /q build
mkdir build
cd build
cmake .. -G "Visual Studio 12" "-DCMAKE_INSTALL_PREFIX=%WORKSPACE%\install" %*
cmake --build . --config Debug
cmake --build . --config RelWithDebInfo
call "%WORKSPACE%\vendor\jenkins-ctest-plugin\run-test-and-save.bat" -C Debug
call "%WORKSPACE%\vendor\jenkins-ctest-plugin\run-test-and-save.bat" -C RelWithDebInfo
cmake --build . --config Debug --target INSTALL
cmake --build . --config RelWithDebInfo --target INSTALL
cmake --build . --config RelWithDebInfo --target ogvrPluginKit -- /p:RunCodeAnalysis=True
rem bin\Debug\LoadTest.exe --gtest_output=xml:test_details.Debug.xml
rem bin\RelWithDebInfo\LoadTest.exe --gtest_output=xml:test_details.RelWithDebInfo.xml
pause |
Set NOSE_PROCESS_RESTARTWORKER for appveyor tests | set result=0
:top
if "%1" == "" goto :end
echo RUNNING TESTS FOR %1
cd %1 || exit /b 1
if exist tests (
nosetests -v --nologcapture tests || set result=1 && goto :continue
) else if exist test.py (
nosetests -v --nologcapture test.py || set result=1 && goto :continue
) else (
echo Unknown test configuration && set result=1 && goto :continue
)
:continue
cd ..
shift
echo ------------------------------------------
goto :top
:end
exit /b %result%
| set result=0
:top
if "%1" == "" goto :end
echo RUNNING TESTS FOR %1
cd %1 || exit /b 1
env set NOSE_PROCESS_RESTARTWORKER=1
if exist tests (
nosetests -v --nologcapture tests || set result=1 && goto :continue
) else if exist test.py (
nosetests -v --nologcapture test.py || set result=1 && goto :continue
) else (
echo Unknown test configuration && set result=1 && goto :continue
)
:continue
cd ..
shift
echo ------------------------------------------
goto :top
:end
exit /b %result%
|
Move output of teamcity plugin to root directory for easier urls in AppVeyor | RMDIR "%~dp0..\Drops" /S /Q
MKDIR "%~dp0..\Drops"
MKDIR "%~dp0..\Drops\Temp"
MKDIR "%~dp0..\Drops\Temp\agent"
MKDIR "%~dp0..\Drops\Temp\agent\bin"
XCOPY /E /Y "%~dp0..\Solutions\*.*" "%~dp0..\Drops\Temp"
XCOPY /E /Y "%~dp0..\..\src\OctopusPuppet.Cmd\bin\Release\*.*" "%~dp0..\Drops\Temp\agent\bin"
DEL "%~dp0..\Drops\Temp\agent\bin\*.xml"
DEL "%~dp0..\Drops\Temp\agent\bin\*.pdb"
@PowerShell -File %~dp0Create-Zip.ps1 %~dp0..\Drops\Temp\agent\ %~dp0..\Drops\Temp\agent\octopuspuppet-metarunner.zip
DEL "%~dp0..\Drops\Temp\agent\*.xml"
RMDIR "%~dp0..\Drops\Temp\agent\bin" /S /Q
@PowerShell -File "%~dp0Create-Zip.ps1" -target %~dp0..\Drops\Temp\ %~dp0..\Drops\octopuspuppet-metarunner.zip
RMDIR "%~dp0..\Drops\Temp\" /S /Q | RMDIR "%~dp0..\Drops" /S /Q
MKDIR "%~dp0..\Drops"
MKDIR "%~dp0..\Drops\Temp"
MKDIR "%~dp0..\Drops\Temp\agent"
MKDIR "%~dp0..\Drops\Temp\agent\bin"
XCOPY /E /Y "%~dp0..\Solutions\*.*" "%~dp0..\Drops\Temp"
XCOPY /E /Y "%~dp0..\..\src\OctopusPuppet.Cmd\bin\Release\*.*" "%~dp0..\Drops\Temp\agent\bin"
DEL "%~dp0..\Drops\Temp\agent\bin\*.xml"
DEL "%~dp0..\Drops\Temp\agent\bin\*.pdb"
@PowerShell -File %~dp0Create-Zip.ps1 %~dp0..\Drops\Temp\agent\ %~dp0..\Drops\Temp\agent\octopuspuppet-metarunner.zip
DEL "%~dp0..\Drops\Temp\agent\*.xml"
RMDIR "%~dp0..\Drops\Temp\agent\bin" /S /Q
@PowerShell -File "%~dp0Create-Zip.ps1" -target %~dp0..\Drops\Temp\ %~dp0..\..\octopuspuppet-metarunner.zip
RMDIR "%~dp0..\Drops\Temp\" /S /Q |
Upgrade Erai to use CMake 3.0.2 | @echo off
if exist "C:\Work\D\Vvmn\*" goto deleteDir
echo No existing build directory
goto updateScripts
:deleteDir
echo Delete directory
pushd "C:\Work\D\Vvmn"
for /d %%d in (*.*) do rmdir /s /q "%%d"
del /q *.*
popd
:updateScripts
cd C:\Work\VesselView\Dashboards\VesselView
"C:\Program Files (x86)\Git\bin\git" fetch origin
"C:\Program Files (x86)\Git\bin\git" reset --hard master
:startDashboards
echo Start dashboards
call "C:\Program Files (x86)\CMake 2.8.11.2\bin\ctest.exe" -S C:\Work\VesselView\Dashboards\VesselView\Utilities\Dashboards\VesselView-errai-master-nightly.cmake -V -C Release > C:\Work\VesselView\Dashboards\Logs\VesselView-errai-master-nightly.log 2>&1
| @echo off
if exist "C:\Work\D\Vvmn\*" goto deleteDir
echo No existing build directory
goto updateScripts
:deleteDir
echo Delete directory
pushd "C:\Work\D\Vvmn"
for /d %%d in (*.*) do rmdir /s /q "%%d"
del /q *.*
popd
:updateScripts
cd C:\Work\VesselView\Dashboards\VesselView
"C:\Program Files (x86)\Git\bin\git" fetch origin
"C:\Program Files (x86)\Git\bin\git" reset --hard master
:startDashboards
echo Start dashboards
call "C:\Program Files (x86)\CMake 3.0.2\bin\ctest.exe" -S C:\Work\VesselView\Dashboards\VesselView\Utilities\Dashboards\VesselView-errai-master-nightly.cmake -V -C Release > C:\Work\VesselView\Dashboards\Logs\VesselView-errai-master-nightly.log 2>&1
|
Update lit version to fix windows build | @ECHO off
@SET LIT_VERSION=1.1.4
IF NOT "x%1" == "x" GOTO :%1
:luvit
IF NOT EXIST lit.exe CALL make.bat lit
ECHO "Building luvit"
lit.exe make
GOTO :end
:lit
ECHO "Building lit"
PowerShell -NoProfile -ExecutionPolicy unrestricted -Command "iex ((new-object net.webclient).DownloadString('https://github.com/luvit/lit/raw/%LIT_VERSION%/get-lit.ps1'))"
GOTO :end
:test
IF NOT EXIST luvit.exe CALL make.bat luvit
ECHO "Testing luvit"
SET LUVI_APP=.
luvit.exe tests\run.lua
SET "LUVI_APP="
GOTO :end
:clean
IF EXIST luvit.exe DEL /F /Q luvit.exe
IF EXIST lit.exe DEL /F /Q lit.exe
:end
| @ECHO off
@SET LIT_VERSION=1.1.8
IF NOT "x%1" == "x" GOTO :%1
:luvit
IF NOT EXIST lit.exe CALL make.bat lit
ECHO "Building luvit"
lit.exe make
GOTO :end
:lit
ECHO "Building lit"
PowerShell -NoProfile -ExecutionPolicy unrestricted -Command "iex ((new-object net.webclient).DownloadString('https://github.com/luvit/lit/raw/%LIT_VERSION%/get-lit.ps1'))"
GOTO :end
:test
IF NOT EXIST luvit.exe CALL make.bat luvit
ECHO "Testing luvit"
SET LUVI_APP=.
luvit.exe tests\run.lua
SET "LUVI_APP="
GOTO :end
:clean
IF EXIST luvit.exe DEL /F /Q luvit.exe
IF EXIST lit.exe DEL /F /Q lit.exe
:end
|
Include a jade wrapper that emits an ".htm" file instead of ".html" | @echo off
REM Usage: BloomJade mytemplate.jade --someargument someargument
REM the %~2 %~3 here are just places for optional arguments to get
REM passed through to JADE. If they're missing, no problem.
REM The %~1 is the jade file name.
call jade --pretty %~2 %~3 %~1 >&2
if errorlevel 1 goto :eof
call del %~n1.htm
rename %~n1.html %~n1.htm
echo Saved as %~n1.htm | |
Use paket install instead of paket restore | @echo off
set fake_args=%*
cd "._fake"
call "paket.bat" "restore"
cd ".."
"._fake\packages\FAKE\tools\FAKE.exe" "build.fsx" %fake_args%
| @echo off
set fake_args=%*
cd "._fake"
call "paket.bat" "install"
cd ".."
"._fake\packages\FAKE\tools\FAKE.exe" "build.fsx" %fake_args%
|
Improve startup script for windows | set SPECWARE4=C:\Progra~1\Specware4
rem SWPATH needs /s rather than \s so URI parsing works
set SWPATH=/Progra~1/Specware4;/
set XEMACS=C:\Progra~1\XEmacs\XEmacs-21.4.6
rem Set allegro to the version you have
set ALLEGRO=C:\Progra~1\acl62
rem set ALLEGRO=C:\Progra~1\acl61
set SPECWARE_BIN=%SPECWARE4%\Applications\Specware\bin\windows
set LISP_EXECUTABLE=%ALLEGRO%\alisp.exe
set LISP_HEAP_IMAGE=%SPECWARE_BIN%\Specware4.dxl
set LISP_DIRECTORY=%Specware4%/
cd "%Specware4%"
%XEMACS%\i586-pc-win32\xemacs.exe -debug-init -l "%ALLEGRO%/xeli/fi-site-init" -l "%SPECWARE4%/Library/IO/Emacs/load" -f "run-specware4" &
| set SPECWARE4=C:\Progra~1\Specware4
rem SWPATH needs /s rather than \s so URI parsing works
set SWPATH=C:/Progra~1/Specware4;C:/
set XEMACS=C:\Progra~1\XEmacs\XEmacs-21.4.6
rem Set allegro to the version you have
set ALLEGRO=C:\Progra~1\acl62
rem set ALLEGRO=C:\Progra~1\acl61
set SPECWARE_BIN=%SPECWARE4%\Applications\Specware\bin\windows
set LISP_EXECUTABLE=%ALLEGRO%\alisp.exe
set LISP_HEAP_IMAGE=%SPECWARE_BIN%\Specware4.dxl
set LISP_DIRECTORY=%Specware4%/
cd "%Specware4%"
%XEMACS%\i586-pc-win32\xemacs.exe -debug-init -l "%ALLEGRO%/xeli/fi-site-init" -l "%SPECWARE4%/Library/IO/Emacs/load" -f "run-specware4" &
|
Add support for creating zip distributions to the install script | @ECHO OFF
TITLE 3RVX Installer Builder
ECHO " _____ ______ ____ _______ "
ECHO " |___ /| _ \ \ / /\ \/ /___ / "
ECHO " |_ \| |_) \ \ / / \ / |_ \ "
ECHO " ___) | _ < \ V / / \ ___) | "
ECHO " |____/|_| \_\ \_/ /_/\_\____/ "
ECHO " "
ECHO This script will generate a 3RVX installer.
set /p version= "Enter 3RVX Version (X.X): "
ECHO.
ECHO Setting Version: %version%
ECHO.
ECHO Setting PATH...
ECHO ON
set PATH=%PATH%;%WIX%\bin
heat dir ../Release -gg -srd -cg 3RVXComponents -dr INSTALLFOLDER -out 3RVXComponents.wxs
candle -pedantic -dProductVersion=%version%.0.0 ./3RVX.wxs ./3RVXComponents.wxs
light -b ../Release -ext WixUIExtension ./3RVX.wixobj ./3RVXComponents.wixobj -o 3RVX.msi
del 3RVX.wixobj 3RVX.wixpdb 3RVXComponents.wxs 3RVXComponents.wixobj
@PAUSE | @ECHO OFF
TITLE 3RVX Installer Builder
ECHO " _____ ______ ____ _______ "
ECHO " |___ /| _ \ \ / /\ \/ /___ / "
ECHO " |_ \| |_) \ \ / / \ / |_ \ "
ECHO " ___) | _ < \ V / / \ ___) | "
ECHO " |____/|_| \_\ \_/ /_/\_\____/ "
ECHO " "
ECHO This script will generate a 3RVX installer.
set /p version= "Enter 3RVX Version (X.X): "
ECHO.
ECHO Setting Version: %version%
ECHO.
ECHO Setting PATH...
ECHO ON
set PATH=%PATH%;%WIX%\bin
heat dir ../Release -gg -srd -cg 3RVXComponents -dr INSTALLFOLDER -out 3RVXComponents.wxs
candle -pedantic -dProductVersion=%version%.0.0 ./3RVX.wxs ./3RVXComponents.wxs
light -b ../Release -ext WixUIExtension ./3RVX.wixobj ./3RVXComponents.wixobj -o 3RVX.msi
del 3RVX.wixobj 3RVX.wixpdb 3RVXComponents.wxs 3RVXComponents.wixobj
@ECHO OFF
ECHO.
ECHO.
IF EXIST "7za.exe" (
ECHO Creating .zip distribution...
ECHO.
ECHO ON
del 3RVX-%version%.zip
copy "..\Assets\EmptySettings.xml" "..\Release\Settings.xml"
7za a -tzip -mx9 3RVX-%version%.zip ../Release/*
)
@ECHO OFF
ECHO.
PAUSE |
Copy style and images to output in edit documentation script | ..\Tools\Lynx\WikiPad.exe Index.wikiproj | copy style.css ..\Output\Documentation
copy Images ..\Output\Documentation\Images
..\Tools\Lynx\WikiPad.exe Index.wikiproj |
Build the GitHub.VisualStudio project and VSIX file | @if "%config%" == "" set config=Debug
call "%ProgramFiles(x86)%\Microsoft Visual Studio 14.0\Common7\Tools\VsDevCmd.bat"
msbuild GitHubVS.sln /p:Configuration=%Config%
| @if "%config%" == "" set config=Debug
call "%ProgramFiles(x86)%\Microsoft Visual Studio 14.0\Common7\Tools\VsDevCmd.bat"
@rem Build the GitHub.VisualStudio project / VSIX file
msbuild GitHubVS.sln /p:Configuration=%Config% /t:GitHub_VisualStudio |
Make prebuild more flexible by trying to find where git is installed | ECHO Get revision number from git
echo // Pre build automatically generated header file> GitRevision.h
REM We use SET/P to do an echo without newline
set /p="#define GITREVISION " >> GitRevision.h
REM Count number of commits (relies on Git being installed)
git rev-list HEAD | find /v /c "" >> GitRevision.h
| ECHO Get revision number from git
echo // Automatically generated header file created by Prebuild.bat > GitRevision.h
REM We use SET/P to do an echo without newline
set /p="#define GITREVISION " >> GitRevision.h
REM Count number of commits (relies on Git being installed somewhere)
IF NOT EXIST "C:\Program Files (x86)\Git\bin\git.exe" goto next1
"C:\Program Files (x86)\Git\bin\git.exe" rev-list HEAD | find /v /c "" >> GitRevision.h
goto end
:next1
IF NOT EXIST "C:\Program Files (x86)\SmartGit\git\bin\git.exe" goto next2
"C:\Program Files (x86)\SmartGit\git\bin\git.exe" rev-list HEAD | find /v /c "" >> GitRevision.h
goto end
:next2
REM Just try running git and hope it's in the path
git rev-list HEAD | find /v /c "" >> GitRevision.h
:end
|
Add Bach's DOS launch batch script | @ECHO OFF
:BEGIN
IF [%1]==[boot] GOTO :BOOT
IF [%1]==[clean] GOTO :CLEAN
IF [%1]==[describe] GOTO :DESCRIBE
IF [%1]==[/?] GOTO :HELP
IF [%1]==[help] GOTO :HELP
IF [%1]==[version] GOTO :VERSION
java --module-path .bach\cache --module com.github.sormuras.bach %*
GOTO :END
:BOOT
jshell https://github.com/sormuras/bach/raw/HEAD/.bach/boot.jsh
GOTO :END
:CLEAN
IF EXIST .bach\workspace rmdir /q/s .bach\workspace
SHIFT
IF [%1]==[] GOTO :END
GOTO :BEGIN
:VERSION
IF [%2]==[] GOTO :DESCRIBE
jshell -R-Dversion=%2 https://github.com/sormuras/bach/raw/HEAD/.bach/pull.jsh
GOTO :END
:DESCRIBE
java --module-path .bach\cache --describe-module com.github.sormuras.bach
GOTO :END
:HELP
ECHO.
ECHO Usage: %0 [action] [args...]
ECHO.
ECHO Where actions include:
ECHO.
ECHO boot
ECHO Launch an interactive JShell session with Bach's module on the module-path.
ECHO.
ECHO describe
ECHO Describe module com.github.sormuras.bach and exit.
ECHO.
ECHO version [tag]
ECHO Download Bach for the specified version tag.
ECHO Find released version tags at https://github.com/sormuras/bach/releases
ECHO If no tag is given a description of the current module is printed.
ECHO Example: %0 version 15-ea+2
ECHO.
:END
| |
Fix paths in CI script | echo Running Windows build and testscript %cd%/matlab/CIBuildAndTest.m
call "C:\Program Files\MATLAB\R2015b\bin\matlab.exe" -wait -nodisplay -nosplash -nodesktop -r "try, run('%cd%/matlab/CIBuildAndTest.m'), catch ex, disp(['Exception during CIBuildAndTest.m: ' ex.message]), exit(1), end, exit(0);"
if not "%ERRORLEVEL%" == "0" (
echo Exit Code = %ERRORLEVEL%
exit /b 1
) | echo Running Windows build and testscript %cd%/matlab/CIBuildAndTest.m
call "C:\Program Files\MATLAB\R2015b\bin\matlab.exe" -wait -nodisplay -nosplash -nodesktop -r "try, run('%cd%\matlab\CIBuildAndTest.m'), catch ex, disp(['Exception during CIBuildAndTest.m: ' ex.message]), exit(1), end, exit(0);"
if not "%ERRORLEVEL%" == "0" (
echo Exit Code = %ERRORLEVEL%
exit /b 1
) |
Delete model files from AS3 SDK for a cleaner build. | pushd ..
rem === BUILDING ActionScriptSDK ===
node generate.js ..\API_Specs actionscript=..\sdks\ActionScriptSDK\PfApiTest
popd
| rem === Cleaning existing files from ActionScriptSDK ===
pushd ../../sdks/ActionScriptSDK/PfApiTest/com/playfab
pushd AdminModels
del *.as >nul 2>&1
popd
pushd ClientModels
del *.as >nul 2>&1
popd
pushd MatchmakerModels
del *.as >nul 2>&1
popd
pushd ServerModels
del *.as >nul 2>&1
popd
popd
pushd ..
rem === BUILDING ActionScriptSDK ===
node generate.js ..\API_Specs actionscript=..\sdks\ActionScriptSDK\PfApiTest
popd
|
Use the latest experimental build settings. | REM Configure Jemalloc build with options
CMake -G "Visual Studio 12 Win64" -Ddisable-fill=1 -Ddisable-stats=1 -Ddisable-cache-oblivious=1 .. | REM Configure Jemalloc build with options
CMake -G "Visual Studio 12 Win64" -Ddisable-fill=1 -Dwith-malloc-conf=purge:decay ..
REM Debug build settings
REM CMake -G "Visual Studio 12 Win64" -Denable-debug=1 -Dwith-malloc-conf=junk:true .. |
Revert "Remove unnecessary uses of "%~1"" | @echo off
setlocal
set "output=nul"
set "times=1"
goto :parsePackage
:help
:: TODO: put something here.
goto :eof
:usage
call :help 1>&2
exit /b 1
:parsePackage
if "%~1" == "" goto usage
set "package=%~1"
shift
:parseArgs
if "%~1" == "" goto main
if /i %1 == "-?" goto help
if /i %1 == "-h" goto help
if /i %1 == "--help" goto help
if /i %1 == "-t" (
set "times=%~2"
shift
)
if /i %1 == "--times" (
set "times=%~2"
shift
)
if /i %1 == "-o" (
set "output=%~2"
shift
)
if /i %1 == "--output" (
set "output=%~2"
shift
)
shift
goto parseArgs
:curl
@powershell -NoProfile "iwr %~1 -OutFile %~2" 2> nul
goto :eof
:downloadPackage
set "url=https://www.nuget.org/api/v2/package/%~1"
call :curl "%url%" %2
goto :eof
:main
for /l %%i in (1, 1, %times%) do (
call :downloadPackage "%package%" "%output%"
)
| @echo off
setlocal
set "output=nul"
set "times=1"
goto :parsePackage
:help
:: TODO: put something here.
goto :eof
:usage
call :help 1>&2
exit /b 1
:parsePackage
if "%~1" == "" goto usage
set "package=%~1"
shift
:parseArgs
if "%~1" == "" goto main
if /i "%~1" == "-?" goto help
if /i "%~1" == "-h" goto help
if /i "%~1" == "--help" goto help
if /i "%~1" == "-t" (
set "times=%~2"
shift
)
if /i "%~1" == "--times" (
set "times=%~2"
shift
)
if /i "%~1" == "-o" (
set "output=%~2"
shift
)
if /i "%~1" == "--output" (
set "output=%~2"
shift
)
shift
goto parseArgs
:curl
@powershell -NoProfile "iwr %~1 -OutFile %~2" 2> nul
goto :eof
:downloadPackage
set "url=https://www.nuget.org/api/v2/package/%~1"
call :curl "%url%" %2
goto :eof
:main
for /l %%i in (1, 1, %times%) do (
call :downloadPackage "%package%" "%output%"
)
|
Switch build script to use visual studio msbuild instead 4.0 msbuild | @echo off
:: Arguments check
::if [%~1]==[] (
:: echo.
:: echo ERROR: Not enough Arguments
:: echo USAGE: build.bat [C:\path\to\project]
:: exit /b 1
::)
::set projectPath=%~f1
:: Set .NET 4.6 framework path
set msbuildPath="%WINDIR%\Microsoft.NET\Framework64\v4.0.30319\"
:: Run build command
cd..
%msbuildPath%\msbuild.exe PowerPing.sln /p:configuration=release /p:Platform="x86"
%msbuildPath%\msbuild.exe PowerPing.sln /p:configuration=release /p:Platform="x64"
pause | @echo off
cd "%~dp0"
:: Arguments check
::if [%~1]==[] (
:: echo.
:: echo ERROR: Not enough Arguments
:: echo USAGE: build.bat [C:\path\to\project]
:: exit /b 1
::)
::set projectPath=%~f1
:: Set .NET 4.6 framework path
set windows_msbuild_path="%WINDIR%\Microsoft.NET\Framework64\v4.0.30319\"
set vs_msbuild_path="C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin\amd64\msbuild.exe"
:: Run build command
cd..
::%windows_msbuild_path%\msbuild.exe PowerPing.sln /p:Configuration=Release /p:Platform="x86"
::%windows_msbuild_path%\msbuild.exe PowerPing.sln /p:Configuration=Release /p:Platform="x64"
%vs_msbuild_path% PowerPing.sln /p:Configuration=Release /p:Platform="x86"
%vs_msbuild_path% PowerPing.sln /p:Configuration=Release /p:Platform="x64" |
Include the cmd script for notebook execution | echo "Running the notebooks..."
jupyter nbconvert --to notebook --execute "Pulse Building Tutorial.ipynb"
jupyter nbconvert --to notebook --execute "Filter compensation.ipynb"
jupyter nbconvert --to notebook --execute "Subsequences.ipynb"
echo "Cleaning up the generated output..."
rm *nbconvert.ipynb
| |
Set correct default project name during the Windows-based Datastore emulator start. | gcloud beta emulators datastore start --project=spine --host-port=localhost:8080 --consistency 1.0 --no-store-on-disk
| gcloud beta emulators datastore start --project=spine-dev --host-port=localhost:8080 --consistency 1.0 --no-store-on-disk
|
Fix db creation in windows now it'd done by the dbserver and it's under oqdata | @echo off
setlocal
set mypath=%~dp0
set PATH=%PATH%;%mypath%\python2.7
set PYTHONPATH=%mypath%\lib
set OQ_SITE_CFG_PATH=%mypath%
REM Create the DB or update it
python.exe -m openquake.server.db.upgrade_manager "%HOMEPATH%\db.sqlite3"
echo Please wait ...
REM Start the DbServer in background but within the same context
start "OpenQuake DB server" /B python.exe -m openquake.server.dbserver
REM Make sure that the dbserver is up and running
call:sleep 5
REM Start the WebUI using django
start "OpenQuake WebUI server" /B python.exe -m openquake.server.manage runserver %*
REM Make sure that the dbserver is up and running
call:sleep 2
REM Start the browser
start http://localhost:8000
endlocal
exit /b 0
:sleep
setlocal
if exist C:\Windows\System32\timeout.exe (
timeout /t %~1 /nobreak > NUL
) else (
REM Windows XP hack
ping 192.0.2.2 -n %~1 -w 1000 > NUL
)
endlocal
| @echo off
setlocal
set mypath=%~dp0
set PATH=%PATH%;%mypath%\python2.7
set PYTHONPATH=%mypath%\lib
set OQ_SITE_CFG_PATH=%mypath%
echo Please wait ...
REM Start the DbServer in background but within the same context
start "OpenQuake DB server" /B python.exe -m openquake.server.dbserver
REM Make sure that the dbserver is up and running
call:sleep 5
REM Start the WebUI using django
start "OpenQuake WebUI server" /B python.exe -m openquake.server.manage runserver %*
REM Make sure that the dbserver is up and running
call:sleep 2
REM Start the browser
start http://localhost:8000
endlocal
exit /b 0
:sleep
setlocal
if exist C:\Windows\System32\timeout.exe (
timeout /t %~1 /nobreak > NUL
) else (
REM Windows XP hack
ping 192.0.2.2 -n %~1 -w 1000 > NUL
)
endlocal
|
Tweak to update version -- which will now work regardless of your checkout directory structure. | svn info c:\dev\sipXtapi | sed -n -e /Revision:/p | cut -c 11-
| svn info . | sed -n -e /Revision:/p | cut -c 11-
|
Fix for windows failure in example package |
mkdir %SCRIPTS%
echo "hello world" > %SCRIPTS%\example.txt
set >> %SCRIPTS%\example.txt
|
mkdir %SCRIPTS%
echo "hello world" > %SCRIPTS%\example.txt
set >> %SCRIPTS%\example.txt
echo "Finished" >> %SCRIPTS%\example.txt
|
Add NuGet restore to batch file | @echo off
"C:\Program Files (x86)\MSBuild\14.0\Bin\msbuild.exe"
mkdir Releases
copy GitMind\bin\Debug\GitMind.exe Releases\GitMindSetup.exe /Y
pause | @echo off
nuget restore
"C:\Program Files (x86)\MSBuild\14.0\Bin\msbuild.exe"
mkdir Releases
copy GitMind\bin\Debug\GitMind.exe Releases\GitMindSetup.exe /Y
pause |
Return exit code from batch script if build fails [full ci] | REM Using the artifacts plugin v1.3 on Windows seems to break the whole step
buildkite-agent artifact download "Bugsnag.unitypackage" .
cd features\scripts
C:\Progra~1\Git\bin\bash.exe build_maze_runner.sh windows
cd ..\fixtures\maze_runner\build
7z a -r Windows-%UNITY_VERSION%.zip Windows
| REM Using the artifacts plugin v1.3 on Windows seems to break the whole step
buildkite-agent artifact download "Bugsnag.unitypackage" .
cd features\scripts
C:\Progra~1\Git\bin\bash.exe build_maze_runner.sh windows
IF NOT [%ERRORLEVEL%] EQU [0] EXIT /B %ERRORLEVEL%
cd ..\fixtures\maze_runner\build
7z a -r Windows-%UNITY_VERSION%.zip Windows
|
Add port number to server output | @echo off
title PostgreSQL Portable
cls
:: set default code page
chcp 1252 > nul
:: initialise a new database on first use
if not exist "%PGDATA%" (
echo.
echo Initialising database for first use, please wait...
"%PGSQL%\bin\initdb" -U %PGUSER% -A trust -E utf8 --locale=C >nul
)
:: startup postgres server
echo.
"%PGSQL%\bin\pg_ctl" -D "%PGDATA%" -l "%PGLOG%" -w start
cls
echo.
echo Type \q to quit and shutdown server
echo.
"%PGSQL%\bin\psql.exe" --port=%PGPORT% --dbname="%PGDATABASE%" --username="%PGUSER%"
echo.
"%PGSQL%\bin\pg_ctl" -D "%PGDATA%" stop
| @echo off
title PostgreSQL Portable
cls
:: set default code page
chcp 1252 > nul
:: initialise a new database on first use
if not exist "%PGDATA%" (
echo.
echo Initialising database for first use, please wait...
"%PGSQL%\bin\initdb" -U %PGUSER% -A trust -E utf8 --locale=C >nul
)
:: startup postgres server
echo.
"%PGSQL%\bin\pg_ctl" -D "%PGDATA%" -l "%PGLOG%" -w start
cls
echo.
echo Running on port %PGPORT%. Type \q to quit and shutdown the server.
echo.
"%PGSQL%\bin\psql.exe" --port=%PGPORT% --dbname="%PGDATABASE%" --username="%PGUSER%"
echo.
"%PGSQL%\bin\pg_ctl" -D "%PGDATA%" stop
|
Make sure to update nuget | @echo off
cd %~dp0
SETLOCAL
SET CACHED_NUGET=%LocalAppData%\NuGet\NuGet.exe
IF EXIST %CACHED_NUGET% goto copynuget
echo Downloading latest version of NuGet.exe...
IF NOT EXIST %LocalAppData%\NuGet md %LocalAppData%\NuGet
@powershell -NoProfile -ExecutionPolicy unrestricted -Command "$ProgressPreference = 'SilentlyContinue'; Invoke-WebRequest 'https://www.nuget.org/nuget.exe' -OutFile '%CACHED_NUGET%'"
:copynuget
IF EXIST .nuget\nuget.exe goto restore
md .nuget
copy %CACHED_NUGET% .nuget\nuget.exe > nul
:restore
.nuget\NuGet.exe install FSharpSupport -ExcludeVersion -o packages -nocache -pre
.nuget\NuGet.exe install KoreBuild -ExcludeVersion -o packages -nocache -pre
.nuget\NuGet.exe install FAKE -ExcludeVersion -o packages
IF "%SKIP_KRE_INSTALL%"=="1" goto run
REM CALL packages\KoreBuild\build\kvm upgrade -svr50 -x86
REM CALL packages\KoreBuild\build\kvm install default -svrc50 -x86
:run
REM Run FAKE
packages\FAKE\tools\Fake.exe build.fsx %* | @echo off
cd %~dp0
SETLOCAL
SET CACHED_NUGET=%LocalAppData%\NuGet\NuGet.exe
IF EXIST %CACHED_NUGET% goto copynuget
echo Downloading latest version of NuGet.exe...
IF NOT EXIST %LocalAppData%\NuGet md %LocalAppData%\NuGet
@powershell -NoProfile -ExecutionPolicy unrestricted -Command "$ProgressPreference = 'SilentlyContinue'; Invoke-WebRequest 'https://www.nuget.org/nuget.exe' -OutFile '%CACHED_NUGET%'"
:copynuget
IF EXIST .nuget\nuget.exe goto restore
md .nuget
copy %CACHED_NUGET% .nuget\nuget.exe > nul
.nuget\NuGet.exe update -self
:restore
.nuget\NuGet.exe install FSharpSupport -ExcludeVersion -o packages -nocache -pre
.nuget\NuGet.exe install KoreBuild -ExcludeVersion -o packages -nocache -pre
.nuget\NuGet.exe install FAKE -ExcludeVersion -o packages
IF "%SKIP_KRE_INSTALL%"=="1" goto run
REM CALL packages\KoreBuild\build\kvm upgrade -svr50 -x86
REM CALL packages\KoreBuild\build\kvm install default -svrc50 -x86
:run
REM Run FAKE
packages\FAKE\tools\Fake.exe build.fsx %* |
Make HOME environment var permanent on Windows | :: Symbolically link to all of the dot files in this directory from the
:: home directory.
@echo off
net file >nul 2> nul && goto :Elevated
echo error: Administrator rights are required to make symbolic links on Windows.
exit /b 1
:Elevated
if not defined HOME (
set HOME=%USERPROFILE%
)
for %%f in (%~dp0.\.*) do (
if exist %HOME%\%%~nxf (
del /P %HOME%\%%~nxf
)
mklink %HOME%\%%~nxf %%f
)
| :: Symbolically link to all of the dot files in this directory from the
:: home directory.
@echo off
net file >nul 2> nul && goto :Elevated
echo error: Administrator rights are required to make symbolic links on Windows.
exit /b 1
:Elevated
if not defined HOME (
set HOME=%USERPROFILE%
)
setx HOME %HOME%
for %%f in (%~dp0.\.*) do (
if exist %HOME%\%%~nxf (
del /P %HOME%\%%~nxf
)
mklink %HOME%\%%~nxf %%f
)
|
Reduce installer and package size a little bit by excluding some unneeded wxWidgets files. | set app_title=WhackEd4
set app_description=A Windows Dehacked editor.
set app_name=WhackEd4
set app_name_lower=whacked4
set app_version=1.2.1
set app_version_value=1.2.1
set app_version_title=1.2.1
set build_path=".\build\exe.win32-2.7"
set python_interpreter="c:\python27\python.exe"
set setup_compiler="C:\Program Files (x86)\Inno Setup 5\ISCC.exe"
set zip=7za
rmdir .\build /S /Q
%python_interpreter% setup.py build
del %app_name_lower%-setup-*.exe
%setup_compiler% %app_name_lower%.iss
del %app_name_lower%-*.7z
%zip% a %app_name_lower%-%app_version%.7z %build_path%\* -r -mx=9 -ms=on
pause
| set app_title=WhackEd4
set app_description=A Windows Dehacked editor.
set app_name=WhackEd4
set app_name_lower=whacked4
set app_version=1.2.1
set app_version_value=1.2.1
set app_version_title=1.2.1
set build_path=".\build\exe.win32-2.7"
set python_interpreter="c:\python27\python.exe"
set setup_compiler="C:\Program Files (x86)\Inno Setup 5\ISCC.exe"
set zip=7za
rmdir .\build /S /Q
%python_interpreter% setup.py build
rmdir .\build\exe.win32-2.7\wx\tools /S /Q
del %app_name_lower%-setup-*.exe
%setup_compiler% %app_name_lower%.iss
del %app_name_lower%-*.7z
%zip% a %app_name_lower%-%app_version%.7z %build_path%\* -r -mx=9 -ms=on
pause
|
Fix dll path in Unity build script | "C:\Program Files (x86)\MSBuild\14.0\Bin\MSBuild.exe" ..\Yoga\Yoga.vcxproj /p:configuration=Release /property:Platform=x64
xcopy "..\Yoga\x64\Release\yoga.dll" %~dp0 /s /d /y
| "C:\Program Files (x86)\MSBuild\14.0\Bin\MSBuild.exe" ..\Yoga\Yoga.vcxproj /p:configuration=Release /property:Platform=x64
xcopy "..\Yoga\bin\x64\Release\yoga.dll" %~dp0 /s /d /y
|
Use sysroot var in py.exe invoke | @ECHO off
CHCP 65001 > NUL
CD /d "%~dp0"
SETLOCAL ENABLEEXTENSIONS
SET KEY_NAME="HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Advanced"
SET VALUE_NAME=HideFileExt
FOR /F "usebackq tokens=1-3" %%A IN (`REG QUERY %KEY_NAME% /v %VALUE_NAME% 2^>nul`) DO (
SET ValueName=%%A
SET ValueType=%%B
SET ValueValue=%%C
)
IF x%ValueValue:0x0=%==x%ValueValue% (
ECHO Unhiding file extensions...
START CMD /c REG ADD HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Advanced /v HideFileExt /t REG_DWORD /d 0 /f
)
ENDLOCAL
IF EXIST %SYSTEMROOT%\py.exe (
CMD /k py.exe -3.5 run.py
EXIT
)
python --version > NUL 2>&1
IF %ERRORLEVEL% NEQ 0 GOTO nopython
CMD /k python run.py
GOTO end
:nopython
ECHO ERROR: Python has either not been installed or not added to your PATH.
:end
PAUSE
| @ECHO off
CHCP 65001 > NUL
CD /d "%~dp0"
SETLOCAL ENABLEEXTENSIONS
SET KEY_NAME="HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Advanced"
SET VALUE_NAME=HideFileExt
FOR /F "usebackq tokens=1-3" %%A IN (`REG QUERY %KEY_NAME% /v %VALUE_NAME% 2^>nul`) DO (
SET ValueName=%%A
SET ValueType=%%B
SET ValueValue=%%C
)
IF x%ValueValue:0x0=%==x%ValueValue% (
ECHO Unhiding file extensions...
START CMD /c REG ADD HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Advanced /v HideFileExt /t REG_DWORD /d 0 /f
)
ENDLOCAL
IF EXIST %SYSTEMROOT%\py.exe (
CMD /k %SYSTEMROOT%\py.exe -3.5 run.py
EXIT
)
python --version > NUL 2>&1
IF %ERRORLEVEL% NEQ 0 GOTO nopython
CMD /k python run.py
GOTO end
:nopython
ECHO ERROR: Python has either not been installed or not added to your PATH.
:end
PAUSE
|
Set HOME to USERPROFILE by default | :: hard link to all of the dot files in this directory from the
:: home directory.
@echo off
setx HOME %HOME%
for %%f in (%~dp0.\.*) do (
if exist %HOME%\%%~nxf (
del /P %HOME%\%%~nxf
)
mklink /h %HOME%\%%~nxf %%f
)
| :: hard link to all of the dot files in this directory from the
:: home directory.
@echo off
if not defined HOME (
set HOME=%USERPROFILE%
)
setx HOME %HOME%
for %%f in (%~dp0.\.*) do (
if exist %HOME%\%%~nxf (
del /P %HOME%\%%~nxf
)
mklink /h %HOME%\%%~nxf %%f
)
|
Add cmd file to regenerate all bindings. | set ORIGINAL_DIR=%CD%
cd JavaScript\CoreBindings
call RegenerateCoreBindings.cmd
cd %ORIGINAL_DIR%
cd JavaScript\JavaScriptBindings
call RegenerateJavaScriptBindings.cmd
cd %ORIGINAL_DIR%
cd BulletPhysics\BulletPhysicsBindings
call RegenerateBulletPhysicsBindings.cmd
cd %ORIGINAL_DIR%
cd UrhoRenderer\UrhoRendererBindings
call RegenerateUrhoRendererBindings.cmd
cd %ORIGINAL_DIR%
cd TundraLogic\TundraLogicBindings
call RegenerateTundraLogicBindings.cmd
cd %ORIGINAL_DIR%
| |
Support case where settings are not stored in the Registry but on disk | REG DELETE "HKEY_CURRENT_USER\Software\MPC-HC\MPC-HC\Favorites\Files" /va /f | @echo off
CLS
ECHO.
ECHO =============================
ECHO Running Admin shell
ECHO =============================
:init
setlocal DisableDelayedExpansion
set cmdInvoke=1
set winSysFolder=System32
set "batchPath=%~0"
for %%k in (%0) do set batchName=%%~nk
set "vbsGetPrivileges=%temp%\OEgetPriv_%batchName%.vbs"
setlocal EnableDelayedExpansion
:checkPrivileges
NET FILE 1>NUL 2>NUL
if '%errorlevel%' == '0' ( goto gotPrivileges ) else ( goto getPrivileges )
:getPrivileges
if '%1'=='ELEV' (echo ELEV & shift /1 & goto gotPrivileges)
ECHO.
ECHO **************************************
ECHO Invoking UAC for Privilege Escalation
ECHO **************************************
ECHO Set UAC = CreateObject^("Shell.Application"^) > "%vbsGetPrivileges%"
ECHO args = "ELEV " >> "%vbsGetPrivileges%"
ECHO For Each strArg in WScript.Arguments >> "%vbsGetPrivileges%"
ECHO args = args ^& strArg ^& " " >> "%vbsGetPrivileges%"
ECHO Next >> "%vbsGetPrivileges%"
if '%cmdInvoke%'=='1' goto InvokeCmd
ECHO UAC.ShellExecute "!batchPath!", args, "", "runas", 1 >> "%vbsGetPrivileges%"
goto ExecElevation
:InvokeCmd
ECHO args = "/c """ + "!batchPath!" + """ " + args >> "%vbsGetPrivileges%"
ECHO UAC.ShellExecute "%SystemRoot%\%winSysFolder%\cmd.exe", args, "", "runas", 1 >> "%vbsGetPrivileges%"
:ExecElevation
"%SystemRoot%\%winSysFolder%\WScript.exe" "%vbsGetPrivileges%" %*
exit /B
:gotPrivileges
setlocal & cd /d %~dp0
if '%1'=='ELEV' (del "%vbsGetPrivileges%" 1>nul 2>nul & shift /1)
::::::::::::::::::::::::::::
::START
::::::::::::::::::::::::::::
SET startDirectory=%~dp0
SET iniFile="C:\Program Files\MPC-HC\mpc-hc64.ini"
SET iniFileModified="C:\Program Files\MPC-HC\mpc-hc64.ini.modified"
IF EXIST %iniFile% (
REM If favorites are stored in the INI file
node "%startDirectory%..\js\remove_mpc-hc_favorites.js" %iniFile% %iniFileModified%
) ELSE (
REM If favorites are stored in the Registry
REG DELETE "HKEY_CURRENT_USER\Software\MPC-HC\MPC-HC\Favorites\Files" /va /f
)
ECHO MPC-HC favorites deleted successfully |
Use IEX_WITH_WERL environment variable to enable --werl by default. | @if defined ELIXIR_CLI_ECHO (@echo on) else (@echo off)
call "%~dp0\elixir.bat" +iex --erl "-user Elixir.IEx.CLI" --no-halt %ELIXIR_IEX_FLAGS% %*
| @if defined ELIXIR_CLI_ECHO (@echo on) else (@echo off)
@if defined IEX_WITH_WERL (@set __ELIXIR_IEX_FLAGS=--werl) else (set __ELIXIR_IEX_FLAGS=)
call "%~dp0\elixir.bat" +iex --erl "-user Elixir.IEx.CLI" --no-halt %__ELIXIR_IEX_FLAGS% %*
@set __ELIXIR_IEX_FLAGS=
|
Copy fftw library to correct file-name | @echo off
set "INCLUDE=%LIBRARY_INC%;%INCLUDE%"
set "LIB=%LIBRARY_LIB%;%LIB%"
xcopy %LIBRARY_LIB%\fftw3.lib %LIBRARY_LIB%\libfftw3-3.lib
%PYTHON% setup.py build
%PYTHON% setup.py install --single-version-externally-managed --record=record.txt | @echo off
set "INCLUDE=%LIBRARY_INC%;%INCLUDE%"
set "LIB=%LIBRARY_LIB%;%LIB%"
xcopy /i %LIBRARY_LIB%\fftw3.lib %LIBRARY_LIB%\libfftw3-3.lib
%PYTHON% setup.py build
%PYTHON% setup.py install --single-version-externally-managed --record=record.txt |
Add missing `sonar:sonar` for windows script | mvn clean jacoco:prepare-agent verify jacoco:report -Dmaven.javadoc.failOnError=false -s dev\settings-sonarqube.xml %*
| mvn clean jacoco:prepare-agent verify jacoco:report sonar:sonar -Dmaven.javadoc.failOnError=false -s dev\settings-sonarqube.xml %*
|
Fix conda wrapper for Windows | @echo off
@REM This script was based on the original conda activate.bat
@setlocal
@set "CONDA_DEFAULT_ENV=__CONDA_ENV_DIR__"
@set PATH="%CONDA_DEFAULT_ENV%";"%CONDA_DEFAULT_ENV%\Scripts";"%CONDA_DEFAULT_ENV%\Library\bin";%PATH%
@REM Run any activate scripts
@if exist "%CONDA_DEFAULT_ENV%\etc\conda\activate.d" (
@pushd "%CONDA_DEFAULT_ENV%\etc\conda\activate.d"
@for %%g in (*.bat) do @call "%%g"
@popd
)
@REM Execute the given command
%*
@endlocal
| @echo off
@REM This script was based on the original conda activate.bat
@setlocal
@set "CONDA_DEFAULT_ENV=__CONDA_ENV_DIR__"
@set "PATH=%CONDA_DEFAULT_ENV%;%CONDA_DEFAULT_ENV%\Scripts;%CONDA_DEFAULT_ENV%\Library\bin;%PATH%"
@REM Run any activate scripts
@if exist "%CONDA_DEFAULT_ENV%\etc\conda\activate.d" (
@pushd "%CONDA_DEFAULT_ENV%\etc\conda\activate.d"
@for %%g in (*.bat) do @call "%%g"
@popd
)
@REM Execute the given command
%*
@endlocal
|
Use Windows environment variable substitution | SET GOPATH=%CD%\gopath
SET GATSPATH=%GOPATH%\src\code.cloudfoundry.org\cli-acceptance-tests
SET PATH=C:\Go\bin;%PATH%
SET PATH=C:\Program Files\Git\cmd\;%PATH%
SET PATH=%GOPATH%\bin;%PATH%
SET PATH=C:\Program Files\GnuWin32\bin;%PATH%
SET PATH=C:\Program Files\cURL\bin;%PATH%
SET PATH=%CD%;%PATH%
SET /p DOMAIN=<%CD%\bosh-lite-lock\name
SET CF_API=api.%DOMAIN%
call %CD%\cli-ci\ci\cli\tasks\create-cats-config.bat
SET CONFIG=%CD%\config.json
pushd %CD%\cf-cli-binaries
gzip -d cf-cli-binaries.tgz
tar -xvf cf-cli-binaries.tar
MOVE %CD%\cf-cli_winx64.exe ..\cf.exe
popd
go get -v github.com/onsi/ginkgo/ginkgo
cd %GATSPATH%
ginkgo.exe -r -nodes=4 $GINKGO_ARGS
| SET GOPATH=%CD%\gopath
SET GATSPATH=%GOPATH%\src\code.cloudfoundry.org\cli-acceptance-tests
SET PATH=C:\Go\bin;%PATH%
SET PATH=C:\Program Files\Git\cmd\;%PATH%
SET PATH=%GOPATH%\bin;%PATH%
SET PATH=C:\Program Files\GnuWin32\bin;%PATH%
SET PATH=C:\Program Files\cURL\bin;%PATH%
SET PATH=%CD%;%PATH%
SET /p DOMAIN=<%CD%\bosh-lite-lock\name
SET CF_API=api.%DOMAIN%
call %CD%\cli-ci\ci\cli\tasks\create-cats-config.bat
SET CONFIG=%CD%\config.json
pushd %CD%\cf-cli-binaries
gzip -d cf-cli-binaries.tgz
tar -xvf cf-cli-binaries.tar
MOVE %CD%\cf-cli_winx64.exe ..\cf.exe
popd
go get -v github.com/onsi/ginkgo/ginkgo
cd %GATSPATH%
ginkgo.exe -r -nodes=4 %GINKGO_ARGS%
|
Use "call" for running Gradle | @REM
@REM Copyright (c) 2013 mgm technology partners GmbH
@REM
@REM Licensed under the Apache License, Version 2.0 (the "License");
@REM you may not use this file except in compliance with the License.
@REM You may obtain a copy of the License at
@REM
@REM http://www.apache.org/licenses/LICENSE-2.0
@REM
@REM Unless required by applicable law or agreed to in writing, software
@REM distributed under the License is distributed on an "AS IS" BASIS,
@REM WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
@REM See the License for the specific language governing permissions and
@REM limitations under the License.
@REM
@echo off
@setlocal
cd %~dp0
if exist setenv.cmd call setenv.cmd
@echo Initializing...
gradlew -b DemoInstaller.gradle -q
pause
@endlocal
| @REM
@REM Copyright (c) 2013 mgm technology partners GmbH
@REM
@REM Licensed under the Apache License, Version 2.0 (the "License");
@REM you may not use this file except in compliance with the License.
@REM You may obtain a copy of the License at
@REM
@REM http://www.apache.org/licenses/LICENSE-2.0
@REM
@REM Unless required by applicable law or agreed to in writing, software
@REM distributed under the License is distributed on an "AS IS" BASIS,
@REM WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
@REM See the License for the specific language governing permissions and
@REM limitations under the License.
@REM
@echo off
@setlocal
cd %~dp0
if exist setenv.cmd call setenv.cmd
@echo Initializing...
call gradlew -b DemoInstaller.gradle -q
pause
@endlocal
|
Add missing license to wrapper batch. | @echo off
python "%~dp0\rossum.py" %*
| @echo off
REM
REM Copyright (c) 2016, G.A. vd. Hoorn
REM
REM Licensed under the Apache License, Version 2.0 (the "License");
REM you may not use this file except in compliance with the License.
REM You may obtain a copy of the License at
REM
REM http://www.apache.org/licenses/LICENSE-2.0
REM
REM Unless required by applicable law or agreed to in writing, software
REM distributed under the License is distributed on an "AS IS" BASIS,
REM WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
REM See the License for the specific language governing permissions and
REM limitations under the License.
REM
python "%~dp0\rossum.py" %*
|
Update azure-cli's kudu specific branch. | @echo off
pushd %1
set attempts=5
set counter=0
:retry
set /a counter+=1
echo Attempt %counter% out of %attempts%
if exist %1\node_modules\azure-cli\bin\azure (
cmd /c npm update https://github.com/amitapl/azure-sdk-tools-xplat/tarball/kudu
) else (
cmd /c npm install https://github.com/amitapl/azure-sdk-tools-xplat/tarball/kudu
)
IF %ERRORLEVEL% NEQ 0 goto error
goto end
:error
if %counter% GEQ %attempts% goto :lastError
goto retry
:lastError
popd
echo An error has occured during npm install.
exit /b 1
:end
popd
echo Finished successfully.
exit /b 0
| @echo off
pushd %1
set attempts=5
set counter=0
:retry
set /a counter+=1
echo Attempt %counter% out of %attempts%
if exist %1\node_modules\azure-cli\bin\azure (
cmd /c npm update https://github.com/amitapl/azure-sdk-tools-xplat/tarball/kudu_s20
) else (
cmd /c npm install https://github.com/amitapl/azure-sdk-tools-xplat/tarball/kudu_s20
)
IF %ERRORLEVEL% NEQ 0 goto error
goto end
:error
if %counter% GEQ %attempts% goto :lastError
goto retry
:lastError
popd
echo An error has occured during npm install.
exit /b 1
:end
popd
echo Finished successfully.
exit /b 0
|
Change script to install azure-cli from a private branch, so we have the latest fixes (not dependant on azure-cli schedule for them). | @echo off
pushd %1
if exist %1\node_modules\azure-cli\bin\azure (
cmd /c npm update azure-cli
) else (
cmd /c npm install azure-cli
)
IF %ERRORLEVEL% NEQ 0 goto error
if exist %1\node_modules\kudusync\bin\kudusync (
cmd /c npm update kudusync
) else (
cmd /c npm install kudusync
)
IF %ERRORLEVEL% NEQ 0 goto error
popd
goto end
:error
echo An error has occured during npm install.
exit /b 1
:end
echo Finished successfully.
| @echo off
pushd %1
if exist %1\node_modules\azure-cli\bin\azure (
cmd /c npm update https://github.com/amitapl/azure-sdk-tools-xplat/tarball/latest
) else (
cmd /c npm install https://github.com/amitapl/azure-sdk-tools-xplat/tarball/latest
)
IF %ERRORLEVEL% NEQ 0 goto error
if exist %1\node_modules\kudusync\bin\kudusync (
cmd /c npm update kudusync
) else (
cmd /c npm install kudusync
)
IF %ERRORLEVEL% NEQ 0 goto error
popd
goto end
:error
echo An error has occured during npm install.
exit /b 1
:end
echo Finished successfully.
|
Remove duplicate dost.jar from CLASSPATH - ID: 3499953 | @echo off
REM This file is part of the DITA Open Toolkit project hosted on
REM Sourceforge.net. See the accompanying license.txt file for
REM applicable licenses.
REM (c) Copyright IBM Corp. 2006 All Rights Reserved.
REM Get the absolute path of DITAOT's home directory
set DITA_DIR=%~dp0
REM Set environment variables
set ANT_OPTS=-Xmx512m %ANT_OPTS%
set ANT_OPTS=%ANT_OPTS% -Djavax.xml.transform.TransformerFactory=net.sf.saxon.TransformerFactoryImpl
set ANT_HOME=%DITA_DIR%tools\ant
set PATH=%DITA_DIR%tools\ant\bin;%PATH%
set CLASSPATH=%DITA_DIR%lib;%DITA_DIR%lib\dost.jar;%DITA_DIR%lib\commons-codec-1.4.jar;%DITA_DIR%lib\dost.jar;%DITA_DIR%lib\resolver.jar;%DITA_DIR%lib\icu4j.jar;%CLASSPATH%
set CLASSPATH=%DITA_DIR%lib\saxon\saxon9.jar;%DITA_DIR%lib\saxon\saxon9-dom.jar;%CLASSPATH%
start "DITA-OT" cmd.exe
| @echo off
REM This file is part of the DITA Open Toolkit project hosted on
REM Sourceforge.net. See the accompanying license.txt file for
REM applicable licenses.
REM (c) Copyright IBM Corp. 2006 All Rights Reserved.
REM Get the absolute path of DITAOT's home directory
set DITA_DIR=%~dp0
REM Set environment variables
set ANT_OPTS=-Xmx512m %ANT_OPTS%
set ANT_OPTS=%ANT_OPTS% -Djavax.xml.transform.TransformerFactory=net.sf.saxon.TransformerFactoryImpl
set ANT_HOME=%DITA_DIR%tools\ant
set PATH=%DITA_DIR%tools\ant\bin;%PATH%
set CLASSPATH=%DITA_DIR%lib;%DITA_DIR%lib\dost.jar;%DITA_DIR%lib\commons-codec-1.4.jar;%DITA_DIR%lib\resolver.jar;%DITA_DIR%lib\icu4j.jar;%CLASSPATH%
set CLASSPATH=%DITA_DIR%lib\saxon\saxon9.jar;%DITA_DIR%lib\saxon\saxon9-dom.jar;%CLASSPATH%
start "DITA-OT" cmd.exe
|
Add the script that is used to setup CI test server | @echo off
setlocal
if [%2]==[] goto :Usage
if [%1]==[/?] goto :Usage
if [%1]==[-?] goto :Usage
if [%1]==[/help] goto :Usage
if [%1]==[-help] goto :Usage
set _n=%1
set _exitCode=0
set _cmd=
set _cmd1=
:Loop
shift
if [%1]==[] goto :Continue
if [%1]==[#] (
set _cmd1=%_cmd1% %_cmd%
set _cmd=
goto :Loop
)
set _cmd=%_cmd% %1
goto :Loop
:Continue
for /L %%i in (1,1,%_n%) do (
echo Iteration: %%i
if defined _cmd1 (
call :Run %_cmd1% %%i %_cmd%
) else (
call :Run %_cmd%
)
if ERRORLEVEL 1 goto :Failed
echo.
)
echo All %_n% iterations completed successfully!
goto :Done
:Usage
echo.
echo Usage:
echo %~n0 n command [parameters]
echo n: [Required] The number of iterations to repeat the command
echo command: [Required] The command to run for n iterations
echo parameters: [Optional] The parameters of the command
echo #: When parameters contain #, the last occurance in the parameter
echo will be replace with the number of iteration.
echo.
echo Example:
echo %~n0 42 work.cmd # param
echo :The script 'work.cmd' will be called 42 times like
echo work.cmd 1 param, work.cmd 2 param, ..., work.cmd 42 param
goto :Done
:Run
set cmdLine=%*
echo %cmdLine%
call %cmdLine%
exit /b
:Failed
set _exitCode=1
echo.
echo Aborted! Failed to complete all iterations.
:Done
exit /b %_exitCode%
endlocal
| |
Use "python.exe" in PATH too, instead of only relying on fixed location. | @C:\Python26\python.exe %~dp0\clcache.py %*
| @echo off
if exist C:\Python26\python.exe (
C:\Python26\python.exe %~dp0\clcache.py %*
) else (
python.exe %~dp0\clcache.py %*
)
|
Revert "print detailed debug info when creating DB" | @echo off
echo [INFO] create db.
echo [INFO] please confirm db encoding utf-8.
echo [INFO] please confirm has modified es/web/pom.xml--^>profile--^>development---^>connection.admin.url/connection.username/password
cd %~dp0
cd ../web
call mvn db:create -e -X
cd ../bin
pause | @echo off
echo [INFO] create db.
echo [INFO] please confirm db encoding utf-8.
echo [INFO] please confirm has modified es/web/pom.xml--^>profile--^>development---^>connection.admin.url/connection.username/password
cd %~dp0
cd ../web
call mvn db:create
cd ../bin
pause |
Disable Python virtualenv on Jenkins | @ECHO OFF
SET BASEDIR=%~dp0..
SET USERINI=%BASEDIR%\user.ini
FOR /F "tokens=1,2 delims=:" %%a in ("%STEELTOE_PCF_CREDENTIALS%") do (
set CF_USER=%%a
set CF_PASS=%%b
)
SET PYTHON_HOME=C:\Python36
SET DOTNET_HOME=C:\Program Files\dotnet
SET JAVA_HOME=C:\opt\oracle-jdk-8
SET GIT_HOME=C:\Program Files\Git
SET MAVEN_HOME=C:\opt\apache-maven-3.3.9
SET CF_HOME=C:\ProgramData\chocolatey\bin
SET TEST_OUT=C:\st\%~nx1
ECHO [behave.userdata] > %USERINI%
ECHO cf_apiurl = api.run.pcfbeta.io >> %USERINI%
ECHO cf_org = STEELTOE >> %USERINI%
ECHO cf_username = %CF_USER% >> %USERINI%
ECHO cf_password = %CF_PASS% >> %USERINI%
ECHO cf_max_attempts = 250 >> %USERINI%
ECHO output = %TEST_OUT% >> %USERINI%
SET PATH=%PYTHON_HOME%;%PYTHON_HOME%\Scripts;%DOTNET_HOME%;%CF_HOME%;%JAVA_HOME%\bin;%GIT_HOME%\bin;%MAVEN_HOME%\bin;%PATH%
PATH
RMDIR /S /Q %TEST_OUT%
CALL %BASEDIR%\test-setup
CALL %BASEDIR%\test-run %*
| @ECHO OFF
SET BASEDIR=%~dp0..
SET USERINI=%BASEDIR%\user.ini
FOR /F "tokens=1,2 delims=:" %%a in ("%STEELTOE_PCF_CREDENTIALS%") do (
set CF_USER=%%a
set CF_PASS=%%b
)
SET PYTHON_HOME=C:\Python36
SET DOTNET_HOME=C:\Program Files\dotnet
SET JAVA_HOME=C:\opt\oracle-jdk-8
SET GIT_HOME=C:\Program Files\Git
SET MAVEN_HOME=C:\opt\apache-maven-3.3.9
SET CF_HOME=C:\ProgramData\chocolatey\bin
SET TEST_OUT=C:\st\%~nx1
ECHO [behave.userdata] > %USERINI%
ECHO cf_apiurl = api.run.pcfbeta.io >> %USERINI%
ECHO cf_org = STEELTOE >> %USERINI%
ECHO cf_username = %CF_USER% >> %USERINI%
ECHO cf_password = %CF_PASS% >> %USERINI%
ECHO cf_max_attempts = 250 >> %USERINI%
ECHO output = %TEST_OUT% >> %USERINI%
SET PATH=%PYTHON_HOME%;%PYTHON_HOME%\Scripts;%DOTNET_HOME%;%CF_HOME%;%JAVA_HOME%\bin;%GIT_HOME%\bin;%MAVEN_HOME%\bin;%PATH%
PATH
RMDIR /S /Q %TEST_OUT%
REM CALL %BASEDIR%\test-setup
REM CALL %BASEDIR%\test-run %*
behave %*
|
Remove echo so the API key doesn't appear on screen. | if "%NUGET_API_KEY%" == "" goto NO_KEY
if "%1" == "" goto MISSING_INPUT_FOLDER
REM dotnet nuget push %1\*.nupkg --api-key %NUGET_API_KEY%
for %%f in (%1\*.nupkg) do dotnet nuget push %%f --api-key %NUGET_API_KEY% --source https://nuget.org/
GOTO END
:NO_KEY
ECHO Couldn't find 'NUGET_API_KEY' environment variable.
EXIT /B 1
:MISSING_INPUT_FOLDER
ECHO You must supply the folder in which the nuget packages live.
EXIT /B 2
:END
| @ECHO OFF
if "%NUGET_API_KEY%" == "" goto NO_KEY
if "%1" == "" goto MISSING_INPUT_FOLDER
REM dotnet nuget push %1\*.nupkg --api-key %NUGET_API_KEY%
for %%f in (%1\*.nupkg) do dotnet nuget push %%f --api-key %NUGET_API_KEY% --source https://nuget.org/
GOTO END
:NO_KEY
ECHO Couldn't find 'NUGET_API_KEY' environment variable.
EXIT /B 1
:MISSING_INPUT_FOLDER
ECHO You must supply the folder in which the nuget packages live.
EXIT /B 2
:END
|
Make a Microsoft import library for the x64 csound64.dll. | @echo CREATING MICROSOFT IMPORT LIBRARY FOR CSOUND64.DLL FOR X64
dumpbin /exports csound-mingw64/csound64.dll > exports.txt
@echo LIBRARY CSOUND64 >> csound64.def
@echo EXPORTS >> csound64.def
FOR /F "skip=19 tokens=4" %%l in (exports.txt) do @echo %%l >> csound64.def
lib /def:csound64.def /out:csound64.lib /machine:x64
| |
Move luvit windows make to new style | @ECHO off
IF NOT "x%1" == "x" GOTO :%1
:luvit
IF NOT EXIST lit.exe CALL Make.bat lit
ECHO "Building luvit"
SET LUVI_APP=app/
SET LUVI_TARGET=luvit.exe
lit\luvi-binaries\Windows\luvi.exe
SET "LUVI_APP="
SET "LUVI_TARGET="
GOTO :end
:lit
ECHO "Building lit"
git clone --recursive --depth 10 https://github.com/luvit/lit.git lit
SET LUVI_APP=lit/
SET LUVI_TARGET=lit.exe
lit\luvi-binaries\Windows\luvi.exe
SET "LUVI_APP="
SET "LUVI_TARGET="
GOTO :end
:test
IF NOT EXIST luvit.exe CALL Make.bat luvit
SET LUVI_APP=app
luvit.exe tests\run.lua
SET "LUVI_APP="
GOTO :end
:clean
IF EXIST luvit.exe DEL /F /Q luvit.exe
IF EXIST lit.exe DEL /F /Q lit.exe
IF EXIST lit RMDIR /S /Q lit
IF EXIST luvi-binaries RMDIR /S /Q luvi-binaries
:end
| @ECHO off
IF NOT "x%1" == "x" GOTO :%1
:luvit
IF NOT EXIST lit.exe CALL Make.bat lit
ECHO "Building luvit"
lit.exe make
GOTO :end
:lit
ECHO "Building lit"
PowerShell -NoProfile -ExecutionPolicy unrestricted -Command "iex ((new-object net.webclient).DownloadString('https://github.com/luvit/lit/raw/0.9.8/web-install.ps1'))"
IF EXIST lit.zip DEL /F /Q lit.zip
GOTO :end
:test
IF NOT EXIST luvit.exe CALL Make.bat luvit
ECHO "Testing luvit"
SET LUVI_APP=.
luvit.exe tests\run.lua
SET "LUVI_APP="
GOTO :end
:clean
IF EXIST luvit.exe DEL /F /Q luvit.exe
IF EXIST lit.exe DEL /F /Q lit.exe
:end
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.