-
Notifications
You must be signed in to change notification settings - Fork 9
/
Copy pathpackage.bat
59 lines (43 loc) · 1.56 KB
/
package.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
set /p versionNumber=
REM clean up
del builds\FsEye-%versionNumber%.zip
del builds\FsEye.%versionNumber%.nupkg
rd /q /s builds\FsEye-%versionNumber%
rd /q /s builds\FsEye
REM preparing staging dir
mkdir staging
mkdir staging\plugins
copy LICENSE staging
copy NOTICE staging
copy FsEye\bin\Release\FsEye.fsx staging
copy FsEye\bin\Release\FsEye.dll staging
copy FsEye\bin\Release\FsEye.xml staging
copy "FsEye.PropertyGrid.Plugin\bin\Release\FsEye.PropertyGrid.Plugin.dll" staging\plugins
copy "FsEye.TreeView.Plugin\bin\Release\FsEye.TreeView.Plugin.dll" staging\plugins
copy "FsEye.DataGridView.Plugin\bin\Release\FsEye.DataGridView.Plugin.dll" staging\plugins
REM zip staging files
cd staging
"..\tools\7z\7za.exe" a -tzip "..\builds\FsEye-%versionNumber%.zip" *
cd ..
REM extract build
"tools\7z\7za.exe" x "builds\FsEye-%versionNumber%.zip" -o"builds\FsEye-%versionNumber%"
"tools\7z\7za.exe" x "builds\FsEye-%versionNumber%.zip" -o"builds\FsEye"
REM preparing nuget dirs
mkdir nuget
mkdir nuget\content
mkdir nuget\lib
mkdir nuget\lib\net40
mkdir nuget\lib\net40\plugins
copy FsEye.nuspec nuget
REM copy staging builds to nuget package...
copy staging\FsEye.dll nuget\lib\net40\FsEye.dll
copy staging\plugins\* nuget\lib\net40\plugins\
copy FsEye\bin\Release\FsEye.NuGet.fsx nuget\content\FsEye.fsx
REM create nuget package...
".nuget\nuget.exe" pack nuget\FsEye.nuspec -Version %versionNumber%
copy FsEye.%versionNumber%.nupkg builds
del FsEye.%versionNumber%.nupkg
REM cleanup...
rd /q /s staging
rd /q /s nuget
pause