uppercutbuild 0.9.0.346.20100805 → 1.0.0.0.20100806

Sign up to get free protection for your applications and to get access to all the features.
Files changed (39) hide show
  1. data/docs/README +7 -2
  2. data/lib/build.sh +23 -0
  3. data/lib/build/UppercuT.xml +1 -1
  4. data/lib/build/analyze.step +78 -77
  5. data/lib/build/analyzers/gallio.test.step +25 -26
  6. data/lib/build/analyzers/mbunit2.test.step +25 -28
  7. data/lib/build/analyzers/moma.step +29 -31
  8. data/lib/build/analyzers/ncover.step +32 -34
  9. data/lib/build/analyzers/ndepend.step +19 -12
  10. data/lib/build/analyzers/nitriq.step +19 -22
  11. data/lib/build/analyzers/nunit.test.step +37 -37
  12. data/lib/build/analyzers/test.step +99 -98
  13. data/lib/build/compile.step +68 -50
  14. data/lib/build/customize.build +76 -75
  15. data/lib/build/customizers/item.template +50 -49
  16. data/lib/build/default.build +171 -167
  17. data/lib/build/deploymentBuilder.step +103 -102
  18. data/lib/build/environmentBuilder.step +119 -118
  19. data/lib/build/gemsBuild.step +113 -112
  20. data/lib/build/gemsPrepare.step +157 -156
  21. data/lib/build/generateBuildInfo.step +108 -105
  22. data/lib/build/ilmerge.build +183 -182
  23. data/lib/build/open.build +115 -102
  24. data/lib/build/package.step +234 -233
  25. data/lib/build/policyChecks.step +81 -80
  26. data/lib/build/updateAssemblies.build +107 -106
  27. data/lib/build/uppercut.dll +0 -0
  28. data/lib/build/uppercut.tasks.dll +0 -0
  29. data/lib/build/versionBuilder.step +149 -147
  30. data/lib/build/versioners/git.step +106 -105
  31. data/lib/build/versioners/hg.step +106 -105
  32. data/lib/build/versioners/svn.step +112 -111
  33. data/lib/build/versioners/tfs.step +104 -103
  34. data/lib/build/zip.build +134 -162
  35. data/lib/deployment/scripts/database.deploy +37 -36
  36. data/lib/open.sh +7 -0
  37. data/lib/settings/UppercuT.config +76 -73
  38. data/lib/zip.sh +9 -0
  39. metadata +9 -6
@@ -1,157 +1,158 @@
1
- <?xml version="1.0" encoding="utf-8" ?>
2
- <project name="GemsPrepare" default="go">
3
- <!-- Project UppercuT - http://projectuppercut.org -->
4
- <!-- DO NOT EDIT THIS FILE - Add custom tasks in BuildTasks.Custom folder with file by the same name - find out more at http://uppercut.pbwiki.com -->
5
- <property name="build.config.settings" value="__NONE__" overwrite="false" />
6
- <include buildfile="${build.config.settings}" if="${file::exists(build.config.settings)}" />
7
- <property name="file.current.no_extension" value="gemsPrepare" />
8
- <property name="dirs.current" value="${directory::get-parent-directory(project::get-buildfile-path())}" />
9
- <property name="path.to.toplevel" value=".." />
10
- <property name="folder.build_scripts" value="build" overwrite="false" />
11
- <property name="folder.build_scripts_custom" value="build.custom" overwrite="false" />
12
- <property name="dirs.build_scripts_custom" value="${dirs.current}\${path.to.toplevel}\${folder.build_scripts_custom}" />
13
- <property name="folder.code_build" value="build_output" overwrite="false" />
14
- <property name="dirs.build" value="${dirs.current}\${path.to.toplevel}\${folder.code_build}" />
15
- <property name="folder.code_drop" value="code_drop" overwrite="false" />
16
- <property name="dirs.drop" value="${dirs.current}\${path.to.toplevel}\${folder.code_drop}" overwrite="false" />
17
- <property name="folder.build_artifacts" value="build_artifacts" overwrite="false" />
18
- <property name="folder.app.drop" value="${project.name}" overwrite="false" />
19
- <property name="folder.database" value="__DATABASE_FOLDER_NAME__" overwrite="false" />
20
- <property name="folder.reports" value="${project.name}.Reports" overwrite="false" />
21
- <property name="folder.file_server" value="file.server" overwrite="false" />
22
- <property name="folder.environment_files" value="environment.files" overwrite="false" />
23
- <property name="folder.deployment" value="deployment" overwrite="false" />
24
- <property name="folder.settings" value="settings" overwrite="false" />
25
- <property name="folder.documentation" value="docs" overwrite="false" />
26
- <property name="folder.gems" value="gems" overwrite="false" />
27
- <property name="dirs.gems" value="${path.to.toplevel}\${folder.gems}" overwrite="false" />
28
- <property name="dirs.drop.gems" value="${dirs.drop}\${folder.gems}" overwrite="false" />
29
- <property name="folder.gems.exists" value="${directory::exists(dirs.gems)}" />
30
- <property name="version.major" value="1" overwrite="false" />
31
- <property name="version.minor" value="0" overwrite="false" />
32
- <property name="version.build" value="0" overwrite="false" />
33
- <property name="version.revision" value="0" overwrite="false" />
34
- <property name="assembly.version.full" value="${version.major}.${version.minor}.${version.build}.${version.revision}" />
35
- <property name="gem.build.date" value="20100801" overwrite="false" />
36
- <property name="file.gems.version" value="${dirs.drop.gems}\VERSION" />
37
-
38
-
39
- <property name="file.custom.step.before" value="${dirs.build_scripts_custom}\${file.current.no_extension}.pre.step" />
40
- <property name="file.custom.step.after" value="${dirs.build_scripts_custom}\${file.current.no_extension}.post.step" />
41
- <property name="file.custom.step.replace" value="${dirs.build_scripts_custom}\${file.current.no_extension}.replace.step" />
42
- <property name="is.replaced" value="false" />
43
- <property name="fail.build.on.error" value="true" />
44
-
45
- <target name="go" depends="run_tasks" if="${folder.gems.exists}" />
46
-
47
- <target name="run_tasks" if="${folder.gems.exists}">
48
- <echo message="Running ${project::get-name()} tasks." />
49
- <call target="custom_tasks_before" if="${target::exists('custom_tasks_before')}" />
50
- <call target="custom_tasks_replace" if="${target::exists('custom_tasks_replace')}" />
51
- <call target="run_normal_tasks" if="${not is.replaced}" />
52
- <call target="custom_tasks_after" if="${target::exists('custom_tasks_after')}" />
53
- </target>
54
-
55
- <target name="run_normal_tasks"
56
- depends="prepare, copy_gems_folder, copy_app_drop_to_lib_folder, copy_docs_to_doc_folder, copy_notices_to_doc_folder, update_gem_build_date, generate_version_file"
57
- description="Packaging gems." />
58
-
59
- <target name="prepare">
60
- <echo message="Removing and adding ${dirs.drop.gems}."/>
61
- <delete dir="${dirs.drop.gems}" failonerror="false" />
62
- <mkdir dir="${dirs.drop.gems}" />
63
- </target>
64
-
65
- <target name="custom_tasks_before">
66
- <echo message="Running custom tasks if ${file.custom.step.before} exists." />
67
- <nant buildfile="${file.custom.step.before}" inheritall="true" if="${file::exists(file.custom.step.before)}" failonerror="${fail.build.on.error}" />
68
- <exec program="powershell.exe" if="${file::exists(file.custom.step.before + '.ps1')}" failonerror="${fail.build.on.error}">
69
- <arg value="${path::get-full-path(file.custom.step.before + '.ps1')}" />
70
- </exec>
71
- <exec program="ruby.exe" if="${file::exists(file.custom.step.before + '.rb')}" failonerror="${fail.build.on.error}">
72
- <arg value="${path::get-full-path(file.custom.step.before + '.rb')}" />
73
- </exec>
74
- </target>
75
-
76
- <target name="custom_tasks_replace">
77
- <echo message="Running custom tasks instead of normal tasks if ${file.custom.step.replace} exists." />
78
- <property name="is.replaced" value="true" if="${file::exists(file.custom.step.replace)}" />
79
- <nant buildfile="${file.custom.step.replace}" inheritall="true" if="${file::exists(file.custom.step.replace)}" failonerror="${fail.build.on.error}" />
80
- <property name="is.replaced" value="true" if="${file::exists(file.custom.step.replace + '.ps1')}" />
81
- <exec program="powershell.exe" if="${file::exists(file.custom.step.replace + '.ps1')}" failonerror="${fail.build.on.error}" >
82
- <arg value="${path::get-full-path(file.custom.step.replace + '.ps1')}" />
83
- </exec>
84
- <property name="is.replaced" value="true" if="${file::exists(file.custom.step.replace + '.rb')}" />
85
- <exec program="ruby.exe" if="${file::exists(file.custom.step.replace + '.rb')}" failonerror="${fail.build.on.error}" >
86
- <arg value="${path::get-full-path(file.custom.step.replace + '.rb')}" />
87
- </exec>
88
- </target>
89
-
90
- <target name="copy_gems_folder">
91
- <echo message="Packaging gem specifications and special files from ${dirs.gems} to ${dirs.drop.gems}."/>
92
- <copy todir="${dirs.drop.gems}">
93
- <fileset basedir="${dirs.gems}">
94
- <include name="**/**" />
95
- </fileset>
96
- </copy>
97
- </target>
98
-
99
- <target name="copy_app_drop_to_lib_folder">
100
- <echo message="Packaging application gem pieces into ${dirs.drop.gems}\lib from ${dirs.drop}\${folder.app.drop}."/>
101
- <copy todir="${dirs.drop.gems}\lib">
102
- <fileset basedir="${dirs.drop}\${folder.app.drop}">
103
- <include name="**/**" />
104
- </fileset>
105
- </copy>
106
- </target>
107
-
108
- <target name="copy_docs_to_doc_folder">
109
- <echo message="Packaging docs to ${dirs.drop.gems}\docs."/>
110
- <copy todir="${dirs.drop.gems}\docs" failonerror="false">
111
- <fileset basedir="${dirs.drop}\${folder.documentation}">
112
- <include name="**/**" />
113
- </fileset>
114
- </copy>
115
- </target>
116
-
117
- <target name="copy_notices_to_doc_folder">
118
- <echo message="Packaging readme file to ${dirs.drop.gems}\docs."/>
119
- <copy file="${dirs.current}\..\README.markdown" tofile="${dirs.drop.gems}\docs\README" failonerror="false" />
120
-
121
- <echo message="Packaging other legal stuff to ${dirs.drop.gems}\docs."/>
122
- <copy todir="${dirs.drop.gems}\docs" failonerror="false">
123
- <fileset basedir="${dirs.drop}\LEGAL">
124
- <include name="**/*" />
125
- </fileset>
126
- </copy>
127
- </target>
128
-
129
- <target name="update_gem_build_date">
130
- <property name="gem.current.date" value="${datetime::now()}" />
131
- <property name="gem.current.date.year" value="${datetime::get-year(gem.current.date)}" />
132
- <property name="gem.current.date.month" value="${datetime::get-month(gem.current.date)}" />
133
- <property name="gem.current.date.month" value="${'0' + gem.current.date.month}" if="${string::get-length(gem.current.date.month) == 1}" />
134
- <property name="gem.current.date.month" value="${'0' + gem.current.date.month}" if="${string::get-length(gem.current.date.month) == 1}" />
135
- <property name="gem.current.date.day" value="${datetime::get-day(gem.current.date)}" />
136
- <property name="gem.current.date.day" value="${'0' + gem.current.date.day}" if="${string::get-length(gem.current.date.day) == 1}" />
137
- <property name="gem.build.date" value="${'' + gem.current.date.year + gem.current.date.month + gem.current.date.day}" />
138
- </target>
139
-
140
- <target name="generate_version_file">
141
-
142
- <echo message="Generating ${file.gems.version} with ${assembly.version.full} and ${gem.build.date} for the version" />
143
- <echo file="${file.gems.version}" append="false" failonerror="false">${assembly.version.full}.${gem.build.date}</echo>
144
- </target>
145
-
146
- <target name="custom_tasks_after">
147
- <echo message="Running custom tasks if ${file.custom.step.after} exists." />
148
- <nant buildfile="${file.custom.step.after}" inheritall="true" if="${file::exists(file.custom.step.after)}" failonerror="${fail.build.on.error}" />
149
- <exec program="powershell.exe" if="${file::exists(file.custom.step.after + '.ps1')}" failonerror="${fail.build.on.error}" >
150
- <arg value="${path::get-full-path(file.custom.step.after + '.ps1')}" />
151
- </exec>
152
- <exec program="ruby.exe" if="${file::exists(file.custom.step.after + '.rb')}" failonerror="${fail.build.on.error}" >
153
- <arg value="${path::get-full-path(file.custom.step.after + '.rb')}" />
154
- </exec>
155
- </target>
156
-
1
+ <?xml version="1.0" encoding="utf-8" ?>
2
+ <project name="GemsPrepare" default="go">
3
+ <!-- Project UppercuT - http://projectuppercut.org -->
4
+ <!-- DO NOT EDIT THIS FILE - Add custom tasks in BuildTasks.Custom folder with file by the same name - find out more at http://uppercut.pbwiki.com -->
5
+ <property name="build.config.settings" value="__NONE__" overwrite="false" />
6
+ <include buildfile="${build.config.settings}" if="${file::exists(build.config.settings)}" />
7
+ <property name="path.separator" value="${string::trim(path::combine(' ', ' '))}" />
8
+ <property name="file.current.no_extension" value="gemsPrepare" />
9
+ <property name="dirs.current" value="${directory::get-parent-directory(project::get-buildfile-path())}" />
10
+ <property name="path.to.toplevel" value=".." />
11
+ <property name="folder.build_scripts" value="build" overwrite="false" />
12
+ <property name="folder.build_scripts_custom" value="build.custom" overwrite="false" />
13
+ <property name="dirs.build_scripts_custom" value="${dirs.current}${path.separator}${path.to.toplevel}${path.separator}${folder.build_scripts_custom}" />
14
+ <property name="folder.code_build" value="build_output" overwrite="false" />
15
+ <property name="dirs.build" value="${dirs.current}${path.separator}${path.to.toplevel}${path.separator}${folder.code_build}" />
16
+ <property name="folder.code_drop" value="code_drop" overwrite="false" />
17
+ <property name="dirs.drop" value="${dirs.current}${path.separator}${path.to.toplevel}${path.separator}${folder.code_drop}" overwrite="false" />
18
+ <property name="folder.build_artifacts" value="build_artifacts" overwrite="false" />
19
+ <property name="folder.app.drop" value="${project.name}" overwrite="false" />
20
+ <property name="folder.database" value="__DATABASE_FOLDER_NAME__" overwrite="false" />
21
+ <property name="folder.reports" value="${project.name}.Reports" overwrite="false" />
22
+ <property name="folder.file_server" value="file.server" overwrite="false" />
23
+ <property name="folder.environment_files" value="environment.files" overwrite="false" />
24
+ <property name="folder.deployment" value="deployment" overwrite="false" />
25
+ <property name="folder.settings" value="settings" overwrite="false" />
26
+ <property name="folder.documentation" value="docs" overwrite="false" />
27
+ <property name="folder.gems" value="gems" overwrite="false" />
28
+ <property name="dirs.gems" value="${path.to.toplevel}${path.separator}${folder.gems}" overwrite="false" />
29
+ <property name="dirs.drop.gems" value="${dirs.drop}${path.separator}${folder.gems}" overwrite="false" />
30
+ <property name="folder.gems.exists" value="${directory::exists(dirs.gems)}" />
31
+ <property name="version.major" value="1" overwrite="false" />
32
+ <property name="version.minor" value="0" overwrite="false" />
33
+ <property name="version.patch" value="0" overwrite="false" />
34
+ <property name="version.build" value="0" overwrite="false" />
35
+ <property name="version.revision" value="0" overwrite="false" />
36
+ <property name="assembly.version.full" value="${version.major}.${version.minor}.${version.patch}.0" />
37
+ <property name="gem.build.date" value="20100801" overwrite="false" />
38
+ <property name="file.gems.version" value="${dirs.drop.gems}${path.separator}VERSION" />
39
+
40
+
41
+ <property name="file.custom.step.before" value="${dirs.build_scripts_custom}${path.separator}${file.current.no_extension}.pre.step" />
42
+ <property name="file.custom.step.after" value="${dirs.build_scripts_custom}${path.separator}${file.current.no_extension}.post.step" />
43
+ <property name="file.custom.step.replace" value="${dirs.build_scripts_custom}${path.separator}${file.current.no_extension}.replace.step" />
44
+ <property name="is.replaced" value="false" />
45
+ <property name="fail.build.on.error" value="true" />
46
+
47
+ <target name="go" depends="run_tasks" if="${folder.gems.exists}" />
48
+
49
+ <target name="run_tasks" if="${folder.gems.exists}">
50
+ <echo message="Running ${project::get-name()} tasks." />
51
+ <call target="custom_tasks_before" if="${target::exists('custom_tasks_before')}" />
52
+ <call target="custom_tasks_replace" if="${target::exists('custom_tasks_replace')}" />
53
+ <call target="run_normal_tasks" if="${not is.replaced}" />
54
+ <call target="custom_tasks_after" if="${target::exists('custom_tasks_after')}" />
55
+ </target>
56
+
57
+ <target name="run_normal_tasks"
58
+ depends="prepare, copy_gems_folder, copy_app_drop_to_lib_folder, copy_docs_to_doc_folder, copy_notices_to_doc_folder, update_gem_build_date, generate_version_file"
59
+ description="Packaging gems." />
60
+
61
+ <target name="prepare">
62
+ <echo message="Removing and adding ${dirs.drop.gems}."/>
63
+ <delete dir="${dirs.drop.gems}" failonerror="false" />
64
+ <mkdir dir="${dirs.drop.gems}" />
65
+ </target>
66
+
67
+ <target name="custom_tasks_before">
68
+ <echo message="Running custom tasks if ${file.custom.step.before} exists." />
69
+ <nant buildfile="${file.custom.step.before}" inheritall="true" if="${file::exists(file.custom.step.before)}" failonerror="${fail.build.on.error}" />
70
+ <exec program="powershell.exe" if="${file::exists(file.custom.step.before + '.ps1')}" failonerror="${fail.build.on.error}">
71
+ <arg value="${path::get-full-path(file.custom.step.before + '.ps1')}" />
72
+ </exec>
73
+ <exec program="ruby.exe" if="${file::exists(file.custom.step.before + '.rb')}" failonerror="${fail.build.on.error}">
74
+ <arg value="${path::get-full-path(file.custom.step.before + '.rb')}" />
75
+ </exec>
76
+ </target>
77
+
78
+ <target name="custom_tasks_replace">
79
+ <echo message="Running custom tasks instead of normal tasks if ${file.custom.step.replace} exists." />
80
+ <property name="is.replaced" value="true" if="${file::exists(file.custom.step.replace)}" />
81
+ <nant buildfile="${file.custom.step.replace}" inheritall="true" if="${file::exists(file.custom.step.replace)}" failonerror="${fail.build.on.error}" />
82
+ <property name="is.replaced" value="true" if="${file::exists(file.custom.step.replace + '.ps1')}" />
83
+ <exec program="powershell.exe" if="${file::exists(file.custom.step.replace + '.ps1')}" failonerror="${fail.build.on.error}" >
84
+ <arg value="${path::get-full-path(file.custom.step.replace + '.ps1')}" />
85
+ </exec>
86
+ <property name="is.replaced" value="true" if="${file::exists(file.custom.step.replace + '.rb')}" />
87
+ <exec program="ruby.exe" if="${file::exists(file.custom.step.replace + '.rb')}" failonerror="${fail.build.on.error}" >
88
+ <arg value="${path::get-full-path(file.custom.step.replace + '.rb')}" />
89
+ </exec>
90
+ </target>
91
+
92
+ <target name="copy_gems_folder">
93
+ <echo message="Packaging gem specifications and special files from ${dirs.gems} to ${dirs.drop.gems}."/>
94
+ <copy todir="${dirs.drop.gems}">
95
+ <fileset basedir="${dirs.gems}">
96
+ <include name="**/**" />
97
+ </fileset>
98
+ </copy>
99
+ </target>
100
+
101
+ <target name="copy_app_drop_to_lib_folder">
102
+ <echo message="Packaging application gem pieces into ${dirs.drop.gems}${path.separator}lib from ${dirs.drop}${path.separator}${folder.app.drop}."/>
103
+ <copy todir="${dirs.drop.gems}${path.separator}lib">
104
+ <fileset basedir="${dirs.drop}${path.separator}${folder.app.drop}">
105
+ <include name="**/**" />
106
+ </fileset>
107
+ </copy>
108
+ </target>
109
+
110
+ <target name="copy_docs_to_doc_folder">
111
+ <echo message="Packaging docs to ${dirs.drop.gems}${path.separator}docs."/>
112
+ <copy todir="${dirs.drop.gems}${path.separator}docs" failonerror="false">
113
+ <fileset basedir="${dirs.drop}${path.separator}${folder.documentation}">
114
+ <include name="**/**" />
115
+ </fileset>
116
+ </copy>
117
+ </target>
118
+
119
+ <target name="copy_notices_to_doc_folder">
120
+ <echo message="Packaging readme file to ${dirs.drop.gems}${path.separator}docs."/>
121
+ <copy file="${dirs.current}${path.separator}..${path.separator}README.markdown" tofile="${dirs.drop.gems}${path.separator}docs${path.separator}README" failonerror="false" />
122
+
123
+ <echo message="Packaging other legal stuff to ${dirs.drop.gems}${path.separator}docs."/>
124
+ <copy todir="${dirs.drop.gems}${path.separator}docs" failonerror="false">
125
+ <fileset basedir="${dirs.drop}${path.separator}LEGAL">
126
+ <include name="**/*" />
127
+ </fileset>
128
+ </copy>
129
+ </target>
130
+
131
+ <target name="update_gem_build_date">
132
+ <property name="gem.current.date" value="${datetime::now()}" />
133
+ <property name="gem.current.date.year" value="${datetime::get-year(gem.current.date)}" />
134
+ <property name="gem.current.date.month" value="${datetime::get-month(gem.current.date)}" />
135
+ <property name="gem.current.date.month" value="${'0' + gem.current.date.month}" if="${string::get-length(gem.current.date.month) == 1}" />
136
+ <property name="gem.current.date.month" value="${'0' + gem.current.date.month}" if="${string::get-length(gem.current.date.month) == 1}" />
137
+ <property name="gem.current.date.day" value="${datetime::get-day(gem.current.date)}" />
138
+ <property name="gem.current.date.day" value="${'0' + gem.current.date.day}" if="${string::get-length(gem.current.date.day) == 1}" />
139
+ <property name="gem.build.date" value="${'' + gem.current.date.year + gem.current.date.month + gem.current.date.day}" />
140
+ </target>
141
+
142
+ <target name="generate_version_file">
143
+ <echo message="Generating ${file.gems.version} with ${assembly.version.full} and ${gem.build.date} for the version" />
144
+ <echo file="${file.gems.version}" append="false" failonerror="false">${assembly.version.full}.${gem.build.date}</echo>
145
+ </target>
146
+
147
+ <target name="custom_tasks_after">
148
+ <echo message="Running custom tasks if ${file.custom.step.after} exists." />
149
+ <nant buildfile="${file.custom.step.after}" inheritall="true" if="${file::exists(file.custom.step.after)}" failonerror="${fail.build.on.error}" />
150
+ <exec program="powershell.exe" if="${file::exists(file.custom.step.after + '.ps1')}" failonerror="${fail.build.on.error}" >
151
+ <arg value="${path::get-full-path(file.custom.step.after + '.ps1')}" />
152
+ </exec>
153
+ <exec program="ruby.exe" if="${file::exists(file.custom.step.after + '.rb')}" failonerror="${fail.build.on.error}" >
154
+ <arg value="${path::get-full-path(file.custom.step.after + '.rb')}" />
155
+ </exec>
156
+ </target>
157
+
157
158
  </project>
@@ -1,106 +1,109 @@
1
- <?xml version="1.0" encoding="utf-8" ?>
2
- <project name="BuildInformation" default="go">
3
- <!-- Project UppercuT - http://projectuppercut.org -->
4
- <!-- DO NOT EDIT THIS FILE - This creates the assembly file to be used by the rest of the application - find out more at http://uppercut.pbwiki.com -->
5
- <property name="build.config.settings" value="__NONE__" overwrite="false" />
6
- <include buildfile="${build.config.settings}" if="${file::exists(build.config.settings)}" />
7
- <property name="file.current.no_extension" value="generateBuildInfo" />
8
- <property name="dirs.current" value="${directory::get-parent-directory(project::get-buildfile-path())}" />
9
- <property name="path.to.toplevel" value=".." />
10
- <property name="folder.build_scripts" value="build" overwrite="false" />
11
- <property name="folder.build_scripts_custom" value="build.custom" overwrite="false" />
12
- <property name="dirs.build_scripts_custom" value="${dirs.current}\${path.to.toplevel}\${folder.build_scripts_custom}" />
13
- <property name="folder.code_build" value="build_output" overwrite="false" />
14
- <property name="dirs.build" value="${dirs.current}\${path.to.toplevel}\${folder.code_build}" />
15
- <property name="file.build_info" value="${dirs.build}\_BuildInfo.xml" />
16
- <property name="project.name" value="__SOLUTION_NAME_WITHOUT_SLN_EXTENSION__" overwrite="false" />
17
- <property name="company.name" value="__COMPANY_NAME__" overwrite="false" />
18
- <property name="version.major" value="1" overwrite="false" />
19
- <property name="version.minor" value="0" overwrite="false" />
20
- <property name="version.build" value="0" overwrite="false" />
21
- <property name="version.revision" value="0" overwrite="false" />
22
- <property name="version.full" value="${version.major}.${version.minor}.${version.build}.${version.revision}" />
23
- <property name="repository.path" value="__REPOSITORY_PATH__" overwrite="false" />
24
- <property name="microsoft.framework" value="net-3.5" overwrite="false" />
25
- <property name="msbuild.configuration" value="Release" overwrite="false" />
26
- <property name="msbuild.platform" value="Any CPU" overwrite="false" />
27
- <property name="version.uppercut" value="0" overwrite="false" />
28
- <property name="file.custom.step.before" value="${dirs.build_scripts_custom}\${file.current.no_extension}.pre.step" />
29
- <property name="file.custom.step.after" value="${dirs.build_scripts_custom}\${file.current.no_extension}.post.step" />
30
- <property name="file.custom.step.replace" value="${dirs.build_scripts_custom}\${file.current.no_extension}.replace.step" />
31
- <property name="is.replaced" value="false" />
32
- <property name="fail.build.on.error" value="false" />
33
-
34
- <target name="go" depends="run_tasks" />
35
-
36
- <target name="run_tasks">
37
- <echo message="Running ${project::get-name()} tasks." />
38
- <call target="prepare" if="${target::exists('prepare')}" />
39
- <call target="custom_tasks_before" if="${target::exists('custom_tasks_before')}" />
40
- <call target="custom_tasks_replace" if="${target::exists('custom_tasks_replace')}" />
41
- <call target="run_normal_tasks" if="${not is.replaced}" />
42
- <call target="custom_tasks_after" if="${target::exists('custom_tasks_after')}" />
43
- </target>
44
-
45
- <target name="run_normal_tasks"
46
- depends="generate_build_info_file"
47
- description="Generating Build Information File." />
48
-
49
- <target name="custom_tasks_before">
50
- <echo message="Running custom tasks if ${file.custom.step.before} exists." />
51
- <nant buildfile="${file.custom.step.before}" inheritall="true" if="${file::exists(file.custom.step.before)}" failonerror="${fail.build.on.error}" />
52
- <exec program="powershell.exe" if="${file::exists(file.custom.step.before + '.ps1')}" failonerror="${fail.build.on.error}">
53
- <arg value="${path::get-full-path(file.custom.step.before + '.ps1')}" />
54
- </exec>
55
- <exec program="ruby.exe" if="${file::exists(file.custom.step.before + '.rb')}" failonerror="${fail.build.on.error}">
56
- <arg value="${path::get-full-path(file.custom.step.before + '.rb')}" />
57
- </exec>
58
- </target>
59
-
60
- <target name="custom_tasks_replace">
61
- <echo message="Running custom tasks instead of normal tasks if ${file.custom.step.replace} exists." />
62
- <property name="is.replaced" value="true" if="${file::exists(file.custom.step.replace)}" />
63
- <nant buildfile="${file.custom.step.replace}" inheritall="true" if="${file::exists(file.custom.step.replace)}" failonerror="${fail.build.on.error}" />
64
- <property name="is.replaced" value="true" if="${file::exists(file.custom.step.replace + '.ps1')}" />
65
- <exec program="powershell.exe" if="${file::exists(file.custom.step.replace + '.ps1')}" failonerror="${fail.build.on.error}" >
66
- <arg value="${path::get-full-path(file.custom.step.replace + '.ps1')}" />
67
- </exec>
68
- <property name="is.replaced" value="true" if="${file::exists(file.custom.step.replace + '.rb')}" />
69
- <exec program="ruby.exe" if="${file::exists(file.custom.step.replace + '.rb')}" failonerror="${fail.build.on.error}" >
70
- <arg value="${path::get-full-path(file.custom.step.replace + '.rb')}" />
71
- </exec>
72
- </target>
73
-
74
- <target name="generate_build_info_file">
75
- <echo message="Generating XML file with some information to possibly get merged in at ${file.build_info}."/>
76
- <echo file="${file.build_info}" append="false" failonerror="false">
77
- <![CDATA[<?xml version="1.0" ?>
78
- <buildInfo>
79
- <projectName>${project.name}</projectName>
80
- <companyName>${string::replace(string::replace(company.name,'&amp;','&'),'&','&amp;')}</companyName>
81
- <versionMajor>${version.major}</versionMajor>
82
- <versionMinor>${version.minor}</versionMinor>
83
- <buildNumber>${version.build}</buildNumber>
84
- <revision>${version.revision}</revision>
85
- <version>${version.full}</version>
86
- <repositoryPath>${repository.path}</repositoryPath>
87
- <microsoftNetFramework>${microsoft.framework}</microsoftNetFramework>
88
- <msbuildConfiguration>${msbuild.configuration}</msbuildConfiguration>
89
- <msbuildPlatform>${msbuild.platform}</msbuildPlatform>
90
- <builtWith>UppercuT v. ${version.uppercut}</builtWith>
91
- </buildInfo>]]>
92
- </echo>
93
- </target>
94
-
95
- <target name="custom_tasks_after">
96
- <echo message="Running custom tasks if ${file.custom.step.after} exists." />
97
- <nant buildfile="${file.custom.step.after}" inheritall="true" if="${file::exists(file.custom.step.after)}" failonerror="${fail.build.on.error}" />
98
- <exec program="powershell.exe" if="${file::exists(file.custom.step.after + '.ps1')}" failonerror="${fail.build.on.error}" >
99
- <arg value="${path::get-full-path(file.custom.step.after + '.ps1')}" />
100
- </exec>
101
- <exec program="ruby.exe" if="${file::exists(file.custom.step.after + '.rb')}" failonerror="${fail.build.on.error}" >
102
- <arg value="${path::get-full-path(file.custom.step.after + '.rb')}" />
103
- </exec>
104
- </target>
105
-
1
+ <?xml version="1.0" encoding="utf-8" ?>
2
+ <project name="BuildInformation" default="go">
3
+ <!-- Project UppercuT - http://projectuppercut.org -->
4
+ <!-- DO NOT EDIT THIS FILE - This creates the assembly file to be used by the rest of the application - find out more at http://uppercut.pbwiki.com -->
5
+ <property name="build.config.settings" value="__NONE__" overwrite="false" />
6
+ <include buildfile="${build.config.settings}" if="${file::exists(build.config.settings)}" />
7
+ <property name="path.separator" value="${string::trim(path::combine(' ', ' '))}" />
8
+ <property name="file.current.no_extension" value="generateBuildInfo" />
9
+ <property name="dirs.current" value="${directory::get-parent-directory(project::get-buildfile-path())}" />
10
+ <property name="path.to.toplevel" value=".." />
11
+ <property name="folder.build_scripts" value="build" overwrite="false" />
12
+ <property name="folder.build_scripts_custom" value="build.custom" overwrite="false" />
13
+ <property name="dirs.build_scripts_custom" value="${dirs.current}${path.separator}${path.to.toplevel}${path.separator}${folder.build_scripts_custom}" />
14
+ <property name="folder.code_build" value="build_output" overwrite="false" />
15
+ <property name="dirs.build" value="${dirs.current}${path.separator}${path.to.toplevel}${path.separator}${folder.code_build}" />
16
+ <property name="file.build_info" value="${dirs.build}${path.separator}_BuildInfo.xml" />
17
+ <property name="project.name" value="__SOLUTION_NAME_WITHOUT_SLN_EXTENSION__" overwrite="false" />
18
+ <property name="company.name" value="__COMPANY_NAME__" overwrite="false" />
19
+ <property name="version.major" value="1" overwrite="false" />
20
+ <property name="version.minor" value="0" overwrite="false" />
21
+ <property name="version.patch" value="0" overwrite="false" />
22
+ <property name="version.build" value="0" overwrite="false" />
23
+ <property name="version.revision" value="0" overwrite="false" />
24
+ <property name="version.full" value="${version.major}.${version.minor}.${version.patch}.0" />
25
+ <property name="repository.path" value="__REPOSITORY_PATH__" overwrite="false" />
26
+ <property name="microsoft.framework" value="net-3.5" overwrite="false" />
27
+ <property name="msbuild.configuration" value="Release" overwrite="false" />
28
+ <property name="msbuild.platform" value="Any CPU" overwrite="false" />
29
+ <property name="version.uppercut" value="0" overwrite="false" />
30
+ <property name="file.custom.step.before" value="${dirs.build_scripts_custom}${path.separator}${file.current.no_extension}.pre.step" />
31
+ <property name="file.custom.step.after" value="${dirs.build_scripts_custom}${path.separator}${file.current.no_extension}.post.step" />
32
+ <property name="file.custom.step.replace" value="${dirs.build_scripts_custom}${path.separator}${file.current.no_extension}.replace.step" />
33
+ <property name="is.replaced" value="false" />
34
+ <property name="fail.build.on.error" value="false" />
35
+
36
+ <target name="go" depends="run_tasks" />
37
+
38
+ <target name="run_tasks">
39
+ <echo message="Running ${project::get-name()} tasks." />
40
+ <call target="prepare" if="${target::exists('prepare')}" />
41
+ <call target="custom_tasks_before" if="${target::exists('custom_tasks_before')}" />
42
+ <call target="custom_tasks_replace" if="${target::exists('custom_tasks_replace')}" />
43
+ <call target="run_normal_tasks" if="${not is.replaced}" />
44
+ <call target="custom_tasks_after" if="${target::exists('custom_tasks_after')}" />
45
+ </target>
46
+
47
+ <target name="run_normal_tasks"
48
+ depends="generate_build_info_file"
49
+ description="Generating Build Information File." />
50
+
51
+ <target name="custom_tasks_before">
52
+ <echo message="Running custom tasks if ${file.custom.step.before} exists." />
53
+ <nant buildfile="${file.custom.step.before}" inheritall="true" if="${file::exists(file.custom.step.before)}" failonerror="${fail.build.on.error}" />
54
+ <exec program="powershell.exe" if="${file::exists(file.custom.step.before + '.ps1')}" failonerror="${fail.build.on.error}">
55
+ <arg value="${path::get-full-path(file.custom.step.before + '.ps1')}" />
56
+ </exec>
57
+ <exec program="ruby.exe" if="${file::exists(file.custom.step.before + '.rb')}" failonerror="${fail.build.on.error}">
58
+ <arg value="${path::get-full-path(file.custom.step.before + '.rb')}" />
59
+ </exec>
60
+ </target>
61
+
62
+ <target name="custom_tasks_replace">
63
+ <echo message="Running custom tasks instead of normal tasks if ${file.custom.step.replace} exists." />
64
+ <property name="is.replaced" value="true" if="${file::exists(file.custom.step.replace)}" />
65
+ <nant buildfile="${file.custom.step.replace}" inheritall="true" if="${file::exists(file.custom.step.replace)}" failonerror="${fail.build.on.error}" />
66
+ <property name="is.replaced" value="true" if="${file::exists(file.custom.step.replace + '.ps1')}" />
67
+ <exec program="powershell.exe" if="${file::exists(file.custom.step.replace + '.ps1')}" failonerror="${fail.build.on.error}" >
68
+ <arg value="${path::get-full-path(file.custom.step.replace + '.ps1')}" />
69
+ </exec>
70
+ <property name="is.replaced" value="true" if="${file::exists(file.custom.step.replace + '.rb')}" />
71
+ <exec program="ruby.exe" if="${file::exists(file.custom.step.replace + '.rb')}" failonerror="${fail.build.on.error}" >
72
+ <arg value="${path::get-full-path(file.custom.step.replace + '.rb')}" />
73
+ </exec>
74
+ </target>
75
+
76
+ <target name="generate_build_info_file">
77
+ <echo message="Generating XML file with some information to possibly get merged in at ${file.build_info}."/>
78
+ <echo file="${file.build_info}" append="false" failonerror="false">
79
+ <![CDATA[<?xml version="1.0" ?>
80
+ <buildInfo>
81
+ <projectName>${project.name}</projectName>
82
+ <companyName>${string::replace(string::replace(company.name,'&amp;','&'),'&','&amp;')}</companyName>
83
+ <versionMajor>${version.major}</versionMajor>
84
+ <versionMinor>${version.minor}</versionMinor>
85
+ <versionPatch>${version.patch}</versionPatch>
86
+ <buildNumber>${version.build}</buildNumber>
87
+ <revision>${version.revision}</revision>
88
+ <version>${version.full}</version>
89
+ <repositoryPath>${repository.path}</repositoryPath>
90
+ <microsoftNetFramework>${microsoft.framework}</microsoftNetFramework>
91
+ <msbuildConfiguration>${msbuild.configuration}</msbuildConfiguration>
92
+ <msbuildPlatform>${msbuild.platform}</msbuildPlatform>
93
+ <builtWith>UppercuT v. ${version.uppercut}</builtWith>
94
+ </buildInfo>]]>
95
+ </echo>
96
+ </target>
97
+
98
+ <target name="custom_tasks_after">
99
+ <echo message="Running custom tasks if ${file.custom.step.after} exists." />
100
+ <nant buildfile="${file.custom.step.after}" inheritall="true" if="${file::exists(file.custom.step.after)}" failonerror="${fail.build.on.error}" />
101
+ <exec program="powershell.exe" if="${file::exists(file.custom.step.after + '.ps1')}" failonerror="${fail.build.on.error}" >
102
+ <arg value="${path::get-full-path(file.custom.step.after + '.ps1')}" />
103
+ </exec>
104
+ <exec program="ruby.exe" if="${file::exists(file.custom.step.after + '.rb')}" failonerror="${fail.build.on.error}" >
105
+ <arg value="${path::get-full-path(file.custom.step.after + '.rb')}" />
106
+ </exec>
107
+ </target>
108
+
106
109
  </project>