Skip to content

Instantly share code, notes, and snippets.

@binki
Created December 17, 2014 05:51
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save binki/2f443bc7a22cb5d5d2f2 to your computer and use it in GitHub Desktop.
Save binki/2f443bc7a22cb5d5d2f2 to your computer and use it in GitHub Desktop.
<Import Project="Neko2k.RandomBuildString.targets"/>
using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
// General Information about an assembly is controlled through the following
// set of attributes. Change these attribute values to modify the information
// associated with an assembly.
[assembly: AssemblyTitle("Neko2k.RandomBuildString")]
[assembly: AssemblyDescription("")]
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("")]
[assembly: AssemblyProduct("Neko2k.RandomBuildString")]
[assembly: AssemblyCopyright("Copyright © 2014")]
[assembly: AssemblyTrademark("")]
[assembly: AssemblyCulture("")]
// Setting ComVisible to false makes the types in this assembly not visible
// to COM components. If you need to access a type in this assembly from
// COM, set the ComVisible attribute to true on that type.
[assembly: ComVisible(false)]
// The following GUID is for the ID of the typelib if this project is exposed to COM
[assembly: Guid("5ec5790b-f451-4b20-95b4-89a72ca64a7e")]
// Version information for an assembly consists of the following four values:
//
// Major Version
// Minor Version
// Build Number
// Revision
//
// You can specify all the values or you can default the Build and Revision Numbers
// by using the '*' as shown below:
// [assembly: AssemblyVersion("1.0.*")]
[assembly: AssemblyVersion("1.0.0.0")]
[assembly: AssemblyFileVersion("1.0.0."+Neko2k.BuildStrings.RandomBuildString)]
<?xml version="1.0" encoding="utf-8" ?>
<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup>
<Neko2kRandomBuildStringFile>.neko2k.RandomBuildString.cs</Neko2kRandomBuildStringFile>
<Neko2kRandomBuildString>$([System.Guid]::NewGuid())</Neko2kRandomBuildString>
</PropertyGroup>
<ItemGroup>
<Compile Include="$(Neko2kRandomBuildStringFile)">
<Visible>false</Visible>
</Compile>
</ItemGroup>
<Target BeforeTargets="BeforeCompile" Name="WriteNeko2kRandomBuildString">
<Delete Files="$(Neko2kRandomBuildStringFile).new"/>
<WriteLinesToFile File="$(Neko2kRandomBuildStringFile).new" Lines="namespace Neko2k { internal static partial class BuildStrings { public const string RandomBuildString = &quot;$(Neko2kRandomBuildString.Replace('\', '\\').Replace('&quot;', '\&quot;'))&quot;%3b; } }"/>
<Move DestinationFiles="$(Neko2kRandomBuildStringFile)" SourceFiles="$(Neko2kRandomBuildStringFile).new"/>
</Target>
</Project>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment