Skip to content

Commit

Permalink
Add pre/post build events to the Build page
Browse files Browse the repository at this point in the history
  • Loading branch information
drewnoakes committed Apr 13, 2021
1 parent 133b8a8 commit a25a97f
Show file tree
Hide file tree
Showing 14 changed files with 581 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,10 @@
Description="Configures the output options for the build process."
DisplayName="Output" />

<Category Name="Events"
Description="Configures custom events that run before and after build."
DisplayName="Events" />

<Category Name="StrongNaming"
Description="Configures strong name signing of build outputs."
DisplayName="Strong naming" />
Expand Down Expand Up @@ -275,6 +279,63 @@
</StringProperty.Metadata>
</StringProperty>

<!-- TODO create fwlink -->
<StringProperty Name="PreBuildEvent"
DisplayName="Pre-build event"
Description="Specifies commands that run before the build starts. Does not run if the project is up-to-date. A non-zero exit code will fail the build before it runs."
HelpUrl="https://docs.microsoft.com/en-us/visualstudio/ide/how-to-specify-build-events-csharp?view=vs-2019"
Category="Events">
<StringProperty.DataSource>
<DataSource HasConfigurationCondition="False"
Persistence="ProjectFileWithInterception"
SourceOfDefaultValue="AfterContext" />
</StringProperty.DataSource>
<StringProperty.ValueEditors>
<ValueEditor EditorType="MultiLineString">
<ValueEditor.Metadata>
<NameValuePair Name="UseMonospaceFont" Value="True" />
</ValueEditor.Metadata>
</ValueEditor>
</StringProperty.ValueEditors>
</StringProperty>

<!-- TODO create fwlink -->
<StringProperty Name="PostBuildEvent"
DisplayName="Post-build event"
Description="Specifies commands that run after the build completes. Does not run if the build failed. Use 'call' to invoke .bat files. A non-zero exit code will fail the build."
HelpUrl="https://docs.microsoft.com/en-us/visualstudio/ide/how-to-specify-build-events-csharp?view=vs-2019"
Category="Events">
<StringProperty.DataSource>
<DataSource HasConfigurationCondition="False"
Persistence="ProjectFileWithInterception"
SourceOfDefaultValue="AfterContext" />
</StringProperty.DataSource>
<StringProperty.ValueEditors>
<ValueEditor EditorType="MultiLineString">
<ValueEditor.Metadata>
<NameValuePair Name="UseMonospaceFont" Value="True" />
</ValueEditor.Metadata>
</ValueEditor>
</StringProperty.ValueEditors>
</StringProperty>

<!-- TODO create fwlink -->
<EnumProperty Name="RunPostBuildEvent"
DisplayName="When to run the post-build event"
Description="Specifies under which condition the post-build event will be executed."
HelpUrl="https://docs.microsoft.com/en-us/visualstudio/ide/how-to-specify-build-events-csharp?view=vs-2019"
Category="Events">
<EnumProperty.DataSource>
<DataSource HasConfigurationCondition="False"
PersistedName="RunPostBuildEvent"
Persistence="ProjectFile"
SourceOfDefaultValue="AfterContext" />
</EnumProperty.DataSource>
<EnumValue Name="Always" />
<EnumValue Name="OnBuildSuccess" IsDefault="True" />
<EnumValue Name="OnOutputUpdated" />
</EnumProperty>

<BoolProperty Name="SignAssembly"
Description="Sign the output assembly to give it a strong name."
HelpUrl="https://go.microsoft.com/fwlink/?linkid=2147136"
Expand Down

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit a25a97f

Please sign in to comment.