-
Notifications
You must be signed in to change notification settings - Fork 519
/
build.bat
92 lines (75 loc) · 2.1 KB
/
build.bat
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
@REM
@REM Copyright Lealone Database Group.
@REM Licensed under the Server Side Public License, v 1.
@REM Initial Developer: zhh
@echo off
if "%OS%" == "Windows_NT" setlocal
set ARG=%1
if /i "%ARG%" == "" goto usage
if /i "%ARG%" == "-e" goto e
if /i "%ARG%" == "-ec" goto ec
if /i "%ARG%" == "-es" goto es
if /i "%ARG%" == "-p" goto p
if /i "%ARG%" == "-pc" goto pc
if /i "%ARG%" == "-pd" goto pd
if /i "%ARG%" == "-pad" goto pad
if /i "%ARG%" == "-i" goto i
if /i "%ARG%" == "-c" goto c
if /i "%ARG%" == "-dt" goto dt
if /i "%ARG%" == "-vu" goto vu
goto usage
:usage
echo usage: build [options]
echo options:
echo -e mvn eclipse:eclipse
echo -ec mvn eclipse:clean
echo -es mvn eclipse:eclipse -DdownloadSources=true
echo -p mvn package assembly:assembly -Dmaven.test.skip=true
echo -pc mvn clean package assembly:assembly -Dmaven.test.skip=true
echo -pd mvn package -Dmaven.test.skip=true -P database
echo -pad mvn package assembly:assembly -Dmaven.test.skip=true -P database
echo -i mvn install -DskipTests
echo -c mvn clean
echo -dt mvn dependency:tree
echo -vu version pom.xml version update
goto end
:e
call mvn eclipse:eclipse
goto end
:ec
call mvn eclipse:clean
goto end
:es
call mvn eclipse:eclipse -DdownloadSources=true
goto end
:p
call mvn package assembly:assembly -Dmaven.test.skip=true
goto end
:pc
call mvn clean package assembly:assembly -Dmaven.test.skip=true
goto end
:pd
call mvn package -Dmaven.test.skip=true -P database
goto end
:pad
call mvn package assembly:assembly -Dmaven.test.skip=true -P database
goto end
:c
call mvn clean
goto end
:i
call mvn install -DskipTests
goto end
:dt
call mvn dependency:tree
goto end
:vu
set VERSION=%2
if /i "%VERSION%" == "" goto usage
call mvn versions:set -DnewVersion=%VERSION%
call mvn versions:commit
set VERSION_FILE=lealone-common\src\main\resources\com\lealone\common\resources\version.properties
echo lealoneVersion=%VERSION%>%VERSION_FILE%
echo buildDate=%date:~0,4%-%date:~5,2%-%date:~8,2%>>%VERSION_FILE%
goto end
:end