Permalink
Browse files

Latest local version that works

  • Loading branch information...
ehelin committed Jul 8, 2018
1 parent 06b7c33 commit 0d19e619ab46e3a33b94a27285f5800f1429af0a
Showing with 21 additions and 5 deletions.
  1. +21 −5 tgimbaNetCoreBuild.bat
View
@@ -1,3 +1,4 @@
rem Tgimba .Net Core local build file.
@echo off
echo "BuildScript >>>>> Starting build!"
@@ -26,7 +27,6 @@ IF EXIST %workingDirectory%\.nuget (
echo "BuildScript >>>>> Creating needed directories..."
mkdir %workingDirectory%\PublishOutput
rem mkdir %workingDirectory%\.nuget
echo "BuildScript >>>>> Checking out source code from git..."
git clone https://github.com/ehelin/TGIMBANetCore.git
@@ -48,8 +48,6 @@ cd..
copy %workingDirectory%\FolderProfile.pubxml %workingDirectory%\TGIMBANetCore\TgimbaNetCoreWeb\Properties\PublishProfiles\FolderProfile.pubxml
echo "BuildScript >>>>> Nuget restore..."
rem nuget config -set repositoryPath=%workingDirectory%\.nuget
rem nuget config repositoryPath
nuget.exe restore %workingDirectory%\TGIMBANetCore\
cd %workingDirectory%\TGIMBANetCore\TgimbaNetCoreWeb
@@ -63,13 +61,31 @@ echo "BuildScript >>>>> Inside %workingDirectory%"
echo "BuildScript >>>>> Build tgimbaNetCore solution..."
msbuild %workingDirectory%\TGIMBANetCore\TgimbaNetCore.sln /t:Build
rem rem TODO - run angular tests - failure, halt build
rem rem TODO - run .net core tests - failure, halt build
rem c# tests
echo "BuildScript >>>>> Running TestAPI tests..."
call dotnet test "%cd%\TGIMBANetCore\TestAPI" /verbosity:quiet /nologo
echo "BuildScript >>>>> Running TestsDAL tests..."
call dotnet test "%cd%\TGIMBANetCore\TestsDAL"
echo "BuildScript >>>>> Running TestShared tests..."
call dotnet test "%cd%\TGIMBANetCore\TestShared"
echo "BuildScript >>>>> Running TestTgimbaNetCoreWeb tests..."
call dotnet test "%cd%\TGIMBANetCore\TestTgimbaNetCoreWeb"
echo "BuildScript >>>>> Publish tgimbaNetCore..."
msbuild %workingDirectory%\TGIMBANetCore\TgimbaNetCoreWeb\TgimbaNetCoreWeb.csproj /p:DeployOnBuild=true /p:PublishProfile=FolderProfile.pubxml /p:Configuration=Release
echo "BuildScript >>>>> Copy node_modules to PublishOutput..."
xcopy /E /I /q %workingDirectory%\TGIMBANetCore\TgimbaNetCoreWeb\node_modules %workingDirectory%\PublishOutput\node_modules
rem Angular 4 tests put here because I have not found a way to exit the karma process (yet)
echo "BuildScript >>>>> Running Angular 4 tests..."
cd TGIMBANetCore
cd TgimbaNetCoreWeb
cd ClientApp
cd test
karma start karma.conf.js
echo "BuildScript >>>>> Build Complete :)"

0 comments on commit 0d19e61

Please sign in to comment.