Skip to content

Commit eace03b

Browse files
committed
initial commit to build tsqlt on containers
1 parent b9b9052 commit eace03b

File tree

2 files changed

+30
-6
lines changed

2 files changed

+30
-6
lines changed

Build/LocalBuild.bat

Lines changed: 10 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -10,22 +10,26 @@ ECHO SQLCMDPath: "%~3"
1010
ECHO SQLVersion: "deprecated"
1111
ECHO SQLInstanceName: "%~4"
1212
ECHO DBName: "%~5"
13-
IF "%~6"=="-v" ECHO Verbose ON ELSE ECHO Verbose OFF
13+
ECHO DBLogin: "%~6"
14+
SET DBLogin -E
15+
IF "%~6"!="-v" && "%~6"!="" SET DBLogin %~6
16+
IF "%~7"=="-v" ECHO Verbose ON ELSE ECHO Verbose OFF
17+
1418

1519
REM CALL "%~1\bin\ant" -buildfile Build\tSQLt.experiments.build.xml -Dmsbuild.path="%~2" -verbose || goto :error
1620
REM goto :EOF
1721

1822
ECHO +-------------------------+
1923
ECHO : Starting CLR BUILD :
2024
ECHO +-------------------------+
21-
IF "%~6"=="-v" @ECHO ON
25+
IF "%~7"=="-v" @ECHO ON
2226
CALL "%~1\bin\ant" -buildfile Build\tSQLt.buildCLR.xml -Dmsbuild.path="%~2" || goto :error
2327
@ECHO OFF
2428

2529
ECHO +-------------------------+
2630
ECHO : Starting tSQLt BUILD :
2731
ECHO +-------------------------+
28-
IF "%~6"=="-v" @ECHO ON
32+
IF "%~7"=="-v" @ECHO ON
2933
CALL "%~1\bin\ant" -buildfile Build\tSQLt.build.xml || goto :error
3034
@ECHO OFF
3135

@@ -34,15 +38,15 @@ ECHO : Copying BUILD :
3438
ECHO +-------------------------+
3539
ECHO :- THIS STEP IS OPTIONAL -:
3640
ECHO +-------------------------+
37-
IF "%~6"=="-v" @ECHO ON
41+
IF "%~7"=="-v" @ECHO ON
3842
CALL "%~1\bin\ant" -buildfile Build\tSQLt.copybuild.xml || goto :error
3943
@ECHO OFF
4044

4145
ECHO +-------------------------+
4246
ECHO : Validating BUILD :
4347
ECHO +-------------------------+
44-
IF "%~6"=="-v" @ECHO ON
45-
CALL "%~1\bin\ant" -buildfile Build\tSQLt.validatebuild.xml -Ddb.server=%~4 -Ddb.name=%~5 -Ddb.login="-E" -Dsqlcmd.path="\"%~3\"" || goto :error
48+
IF "%~7"=="-v" @ECHO ON
49+
CALL "%~1\bin\ant" -buildfile Build\tSQLt.validatebuild.xml -Ddb.server=%~4 -Ddb.name=%~5 -Ddb.login="%DBLogin%" -Dsqlcmd.path="\"%~3\"" || goto :error
4650
@ECHO OFF
4751

4852
ECHO +-------------------------+

CI/containerbuildtSQLt.txt

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
# Where is msbuild? Note the path. Don't have it? Install it by installing Visual Studio Community Edition (I'm using 2019 at the moment)
2+
#- C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\MSBuild\Current\Bin\msbuild.exe
3+
# OBTW, you need a java jdk, so that you can run ant.
4+
#- https://www.oracle.com/java/technologies/javase-jdk15-downloads.html
5+
#- Setup JAVA_HOME env variable and check that you have it setup properly "Get-ChildItem Env:JAVA_HOME"
6+
# Do you have ant installed? No? You need it.
7+
#- https://ant.apache.org/bindownload.cgi
8+
# What about sqlcmd? You need that too.
9+
#- https://docs.microsoft.com/en-us/sql/tools/sqlcmd-utility
10+
#- Setup ANT_HOME env variable and check that you have it setup properly "Get-ChildItem Env:ANT_HOME"
11+
# Set some variables
12+
#- SQLCMD_HOME
13+
#- ANT_HOME
14+
#- MSBUILD_HOME
15+
# Go to SSMS and setup your External Tools
16+
#- tSQLt local Dev_tSQLt (ANT)
17+
#- $(SolutionDir)\Build\localBuild.bat
18+
#- "%ANT_HOME%" "%MSBUILD_HOME%" "%SQLCMD_HOME%" <SERVERNAME eg Dev_tSQLt> tSQLt_dev -v
19+
#- $(SolutionDir)
20+
# Open the solution from the repo

0 commit comments

Comments
 (0)