Skip to content

Commit afdf9a5

Browse files
committed
Merge pull request #401 from Microsoft/master
merging latest changes from master to branch-1.6
2 parents 2a8aa56 + 6da4fe4 commit afdf9a5

File tree

2 files changed

+29
-2
lines changed

2 files changed

+29
-2
lines changed

.gitignore

+1
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,7 @@
3030
scala/dependency-reduced-pom.xml
3131
build/runtime/
3232
build/tools/
33+
build/examples/
3334
*.log
3435
lib/
3536

build/Build.cmd

+28-2
Original file line numberDiff line numberDiff line change
@@ -133,6 +133,32 @@ popd
133133
pushd "%CMDHOME%\..\examples"
134134
call Clean.cmd
135135
call Build.cmd
136+
137+
set EXAMPLES_HOME=%CMDHOME%\examples
138+
@echo set EXAMPLES_HOME=%EXAMPLES_HOME%
139+
140+
if EXIST "%EXAMPLES_HOME%" (
141+
@echo Delete existing %EXAMPLES_HOME% ...
142+
rd /s /q "%EXAMPLES_HOME%"
143+
)
144+
if NOT EXIST "%EXAMPLES_HOME%" mkdir "%EXAMPLES_HOME%"
145+
146+
set CURRDIR=%cd%
147+
for /f "delims=" %%D in ('dir /b /s bin') do call :copyexamples %%D
148+
goto :copyscripts
149+
150+
:copyexamples
151+
set EXAMPLES_SRC=%1
152+
set EXAMPLES_TARGET=%1
153+
call set EXAMPLES_TARGET=%%EXAMPLES_TARGET:%CURRDIR%=%EXAMPLES_HOME%%%
154+
set EXAMPLES_TARGET=%EXAMPLES_TARGET:~0,-3%
155+
156+
@echo mkdir %EXAMPLES_TARGET%
157+
if NOT EXIST "%EXAMPLES_TARGET%" mkdir "%EXAMPLES_TARGET%"
158+
copy /y "%EXAMPLES_SRC%\Release\*" "%EXAMPLES_TARGET%"
159+
goto :eof
160+
161+
:copyscripts
136162
popd
137163

138164
@echo Assemble SparkCLR script components
@@ -150,8 +176,8 @@ if not defined ProjectVersion (
150176
set SPARKCLR_NAME=spark-clr_2.10-%ProjectVersion%
151177

152178
@rem Create the zip file
153-
@echo 7z a .\target\%SPARKCLR_NAME%.zip runtime localmode ..\examples
154-
7z a .\target\%SPARKCLR_NAME%.zip runtime localmode ..\examples
179+
@echo 7z a .\target\%SPARKCLR_NAME%.zip runtime localmode examples
180+
7z a .\target\%SPARKCLR_NAME%.zip runtime localmode examples
155181

156182
:distdone
157183
popd

0 commit comments

Comments
 (0)