Skip to content

Commit

Permalink
And more on versioning.
Browse files Browse the repository at this point in the history
  • Loading branch information
Mihara committed Jun 24, 2014
1 parent e76a0b9 commit e2f60b5
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 2 deletions.
6 changes: 5 additions & 1 deletion RasterPropMonitor/Core/PropMonitorComputer.cs
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
using System.Collections.Generic;
using UnityEngine;
using System.Reflection;
using System.Diagnostics;

namespace JSI
{
Expand Down Expand Up @@ -1923,7 +1924,10 @@ private object VariableToObject(string input, out bool cacheable)

// Meta.
case "RPMVERSION":
return Assembly.GetExecutingAssembly().GetName().Version.ToString();
return FileVersionInfo.GetVersionInfo(Assembly.GetExecutingAssembly().Location).FileVersion;
// That would return only the "AssemblyVersion" version which in our case does not change anymore.
// We use "AsssemblyFileVersion" for actual version numbers now to facilitate hardlinking.
// return Assembly.GetExecutingAssembly().GetName().Version.ToString();

// Compound variables which exist to stave off the need to parse logical and arithmetic expressions. :)
case "GEARALARM":
Expand Down
11 changes: 10 additions & 1 deletion SharedAssemblyInfo.cs
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,16 @@
// The assembly version has the format "{Major}.{Minor}.{Build}.{Revision}".
// The form "{Major}.{Minor}.*" will automatically update the build and revision,
// and "{Major}.{Minor}.{Build}.*" will update just the revision.
[assembly: AssemblyVersion("0.17.*")]

// From now on this is the version-number-for-linking, and is no longer expected to change, for the benefit of people who need to hardlink to RPM anyway.
[assembly: AssemblyVersion("0.17.0.0")]

// Now this is the actual version number with build number.
// As I release newer ones, I'll bump them. Unfortunately I can't make automatic build number bumping
// without jumping through a lot of hoops.
// The 8888 is temporary here.
[assembly: AssemblyFileVersion("0.17.8888.0")]

// The following attributes are used to specify the signing key for the assembly,
// if desired. See the Mono documentation for more information about signing.
//[assembly: AssemblyDelaySign(false)]
Expand Down

0 comments on commit e2f60b5

Please sign in to comment.