-
Notifications
You must be signed in to change notification settings - Fork 112
/
Snapshot.ps1
125 lines (97 loc) · 5.51 KB
/
Snapshot.ps1
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
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
git archive --format=zip -o C:\Temp\BLToolkitSnapshot\bltoolkit_dev.zip master
$revision = 0
git rev-list master |
Foreach-Object {
$revision = $revision + 1
}
Write-Host "BLToolkit revision: $revision"
Write-Host ""
c:
if (!([System.IO.DirectoryInfo]"c:\temp\").Exists) { md c:\temp }
if (!([System.IO.DirectoryInfo]"c:\temp\BLToolkitSnapshot\").Exists) { md c:\temp\BLToolkitSnapshot }
cd c:\temp\BLToolkitSnapshot\
if (([System.IO.DirectoryInfo]"c:\temp\BLToolkitSnapshot\bl-toolkit\").Exists) {
rd bl-toolkit\* -recurse
} else {
md bl-toolkit
}
cd bl-toolkit
$rar = '"' + ${env:ProgramFiles(x86)} + '\WinRAR\WinRar.exe" x ..\bltoolkit_dev.zip'
cmd /c $rar
del ..\*.zip
$rev_file = '// Autogenerated. Do not modify!
namespace BLToolkit
{
partial class BLToolkitConstants
{
// <summary>
// Revision component of version.
// <summary>
public const string Revision = "' + $revision + '";
}
}'
del Source\Properties\Revision.generated.cs
$rev_file >> Source\Properties\Revision.generated.cs
$rar = '"' + ${env:ProgramFiles(x86)} + '\WinRAR\WinRar.exe" a -m5 -md1024 -s -r -rr -AFzip -x*\_svn\* c:\temp\BLToolkitSnapshot\bltoolkit_dev *.*'
cmd /c $rar
$rar = '"' + ${env:ProgramFiles(x86)} + '\WinRAR\WinRar.exe" a -m5 -md1024 -s -r -rr -AFzip -x*\_svn\* c:\temp\BLToolkitSnapshot\bltoolkit Source\*.*'
cmd /c $rar
cd Source
$comp = "$env:windir\Microsoft.NET\Framework\v3.5\MSBuild.exe BLToolkit.3.csproj /property:Configuration=Release"
cmd /c $comp
$comp = "$env:windir\Microsoft.NET\Framework\v4.0.30319\MSBuild.exe BLToolkit.4.csproj /property:Configuration=Release"
cmd /c $comp
$comp = "$env:windir\Microsoft.NET\Framework\v4.0.30319\MSBuild.exe BLToolkit.Data.4.csproj /property:Configuration=Release"
cmd /c $comp
$comp = "$env:windir\Microsoft.NET\Framework\v4.0.30319\MSBuild.exe BLToolkit.SL.4.csproj /property:Configuration=Release"
cmd /c $comp
copy bin\Release\*.dll .
md DataProviders
cd ..\Tools\BLTgen
$comp = "$env:windir\Microsoft.NET\Framework\v3.5\MSBuild.exe BLTgen.2008.csproj /property:Configuration=Release"
cmd /c $comp
$comp = "$env:windir\Microsoft.NET\Framework\v4.0.30319\MSBuild.exe BLTgen.2010.csproj /property:Configuration=Release"
cmd /c $comp
copy bin\Release\*.exe ..\..\Source
cd ..\..\DataProviders
$comp = "$env:windir\Microsoft.NET\Framework\v3.5\MSBuild.exe BLToolkit.Data.DataProvider.DB2.3.csproj /property:Configuration=Release"
cmd /c $comp
$comp = "$env:windir\Microsoft.NET\Framework\v3.5\MSBuild.exe BLToolkit.Data.DataProvider.Firebird.3.csproj /property:Configuration=Release"
cmd /c $comp
$comp = "$env:windir\Microsoft.NET\Framework\v3.5\MSBuild.exe BLToolkit.Data.DataProvider.Informix.3.csproj /property:Configuration=Release"
cmd /c $comp
$comp = "$env:windir\Microsoft.NET\Framework\v3.5\MSBuild.exe BLToolkit.Data.DataProvider.MySql.3.csproj /property:Configuration=Release"
cmd /c $comp
$comp = "$env:windir\Microsoft.NET\Framework\v3.5\MSBuild.exe BLToolkit.Data.DataProvider.Oracle.3.csproj /property:Configuration=Release"
cmd /c $comp
$comp = "$env:windir\Microsoft.NET\Framework\v3.5\MSBuild.exe BLToolkit.Data.DataProvider.PostgreSQL.3.csproj /property:Configuration=Release"
cmd /c $comp
$comp = "$env:windir\Microsoft.NET\Framework\v3.5\MSBuild.exe BLToolkit.Data.DataProvider.SqlCe.3.csproj /property:Configuration=Release"
cmd /c $comp
$comp = "$env:windir\Microsoft.NET\Framework\v3.5\MSBuild.exe BLToolkit.Data.DataProvider.SQLite.3.csproj /property:Configuration=Release"
cmd /c $comp
$comp = "$env:windir\Microsoft.NET\Framework\v3.5\MSBuild.exe BLToolkit.Data.DataProvider.Sybase.3.csproj /property:Configuration=Release"
cmd /c $comp
$comp = "$env:windir\Microsoft.NET\Framework\v4.0.30319\MSBuild.exe BLToolkit.Data.DataProvider.DB2.4.csproj /property:Configuration=Release"
cmd /c $comp
$comp = "$env:windir\Microsoft.NET\Framework\v4.0.30319\MSBuild.exe BLToolkit.Data.DataProvider.Firebird.4.csproj /property:Configuration=Release"
cmd /c $comp
$comp = "$env:windir\Microsoft.NET\Framework\v4.0.30319\MSBuild.exe BLToolkit.Data.DataProvider.Informix.4.csproj /property:Configuration=Release"
cmd /c $comp
$comp = "$env:windir\Microsoft.NET\Framework\v4.0.30319\MSBuild.exe BLToolkit.Data.DataProvider.MySql.4.csproj /property:Configuration=Release"
cmd /c $comp
$comp = "$env:windir\Microsoft.NET\Framework\v4.0.30319\MSBuild.exe BLToolkit.Data.DataProvider.Oracle.4.csproj /property:Configuration=Release"
cmd /c $comp
$comp = "$env:windir\Microsoft.NET\Framework\v4.0.30319\MSBuild.exe BLToolkit.Data.DataProvider.PostgreSQL.4.csproj /property:Configuration=Release"
cmd /c $comp
$comp = "$env:windir\Microsoft.NET\Framework\v4.0.30319\MSBuild.exe BLToolkit.Data.DataProvider.SqlCe.4.csproj /property:Configuration=Release"
cmd /c $comp
$comp = "$env:windir\Microsoft.NET\Framework\v4.0.30319\MSBuild.exe BLToolkit.Data.DataProvider.SQLite.4.csproj /property:Configuration=Release"
cmd /c $comp
$comp = "$env:windir\Microsoft.NET\Framework\v4.0.30319\MSBuild.exe BLToolkit.Data.DataProvider.Sybase.4.csproj /property:Configuration=Release"
cmd /c $comp
copy bin\Release\BLToolkit.Data.*.dll ..\Source\DataProviders
cd ..\Source
$rar = '"' + ${env:ProgramFiles(x86)} + '\WinRAR\WinRar.exe" a -m5 -md1024 -s -r -rr -AFzip -x*\_svn\* -x*\bin\* -x*\obj\* c:\temp\BLToolkitSnapshot\bltoolkit_bin *.exe *.dll DataProvider\ Data\DataProvider\'
cmd /c $rar
ftp -s:e:\documents\copybltsnapshot.txt ftp.bltoolkit.net