This repository has been archived by the owner on Oct 13, 2020. It is now read-only.
forked from apache/chemistry-dotcmis
-
Notifications
You must be signed in to change notification settings - Fork 4
/
release.bat
93 lines (75 loc) · 2.72 KB
/
release.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
93
@echo off
rem
rem Licensed to the Apache Software Foundation (ASF) under one
rem or more contributor license agreements. See the NOTICE file
rem distributed with this work for additional information
rem regarding copyright ownership. The ASF licenses this file
rem to you under the Apache License, Version 2.0 (the
rem "License"); you may not use this file except in compliance
rem with the License. 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,
rem software distributed under the License is distributed on an
rem "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
rem KIND, either express or implied. See the License for the
rem specific language governing permissions and limitations
rem under the License.
rem
rem This batch file creates a release.
rem It requires Cygwin.
set DOTCMISVERSION=0.7
set DOTCMISZIPSRC=chemistry-dotcmis-%DOTCMISVERSION%-src.zip
set DOTCMISZIPBIN=chemistry-dotcmis-%DOTCMISVERSION%-bin.zip
set DOTCMISRC=RC2
set CYGWIN=ntea
echo Building...
cd DotCMIS
call build.bat
cd ..
echo Creating release directories...
rmdir /S /Q release-src
mkdir release-src
rmdir /S /Q release-bin
mkdir release-bin
echo Copying readme, etc...
copy LICENSE release-src
copy LICENSE release-bin
copy NOTICE release-src
copy NOTICE release-bin
copy DEPENDENCIES release-src
copy DEPENDENCIES release-bin
copy README release-src
copy README release-bin
echo Copying binaries ...
copy DotCMIS\bin\Release\DotCMIS.dll release-bin
copy DotCMIS\doc\DotCMISDoc.chm release-bin
chmod -R a+rwx release-bin
echo Copying source...
mkdir release-src\src
xcopy DotCMIS release-src\src /E
rmdir /S /Q release-src\src\bin
rmdir /S /Q release-src\src\obj
rmdir /S /Q release-src\src\doc
chmod -R a+rwx release-src
echo Creating release file...
rmdir /S /Q artifacts
mkdir artifacts
cd release-src
zip -r ../artifacts/%DOTCMISZIPSRC% *
cd ..
cd release-bin
zip -r ../artifacts/%DOTCMISZIPBIN% *
cd ..
echo Signing release file...
cd artifacts
gpg --armor --output %DOTCMISZIPSRC%.asc --detach-sig %DOTCMISZIPSRC%
gpg --print-md MD5 %DOTCMISZIPSRC% > %DOTCMISZIPSRC%.md5
gpg --print-md SHA512 %DOTCMISZIPSRC% > %DOTCMISZIPSRC%.sha
gpg --armor --output %DOTCMISZIPBIN%.asc --detach-sig %DOTCMISZIPBIN%
gpg --print-md MD5 %DOTCMISZIPBIN% > %DOTCMISZIPBIN%.md5
gpg --print-md SHA512 %DOTCMISZIPBIN% > %DOTCMISZIPBIN%.sha
cd ..
echo Creating RC tag
rem svn copy https://svn.apache.org/repos/asf/chemistry/dotcmis/trunk https://svn.apache.org/repos/asf/chemistry/dotcmis/tags/chemistry-dotcmis-%DOTCMISVERSION%-%DOTCMISRC%