Skip to content

Instantly share code, notes, and snippets.

View jazzdelightsme's full-sized avatar

Dan Thompson jazzdelightsme

View GitHub Profile
@jazzdelightsme
jazzdelightsme / ResourceEmitter.cs
Created December 30, 2016 07:39
C# code that can emit a .res file with native version info (VS_FIXEDFILEINFO et al)
// This class is used to generate a compiled win32 resource (.res) file containing version
// information for use during compilation. (it's sort of a substitute for rc.exe and a .rc
// file)
static class ResourceEmitter
{
/// <summary>
/// Similar to the Version class, but uses ushorts instead of ints (because the
/// full version needs to be able to fit into 64 bits).
/// </summary>
public class ResourceVersion : IComparable< ResourceVersion >,