Skip to content

Update Cake version supported criteria to follow major versions #804

@AdmiringWorm

Description

@AdmiringWorm

Currently the criteria for checking if the cake version being used by the user is restricted to check if both major+minor versions of the tool is matching the one we build Cake.Recipe with.
This was done due to cake being in a pre 1.0 state and could include breaking changes in any minor release.

Now that cake have reached 1.0, this criteria should be updated to only factor in the major version of cake itself instead of the major+minor check already implemented.

Reference to the place that needs to be updated:

public bool IsSupportedCakeVersion(string supportedVersion, string currentVersion)
{
var twoPartSupported = Version.Parse(supportedVersion).ToString(2);
var twoPartCurrent = Version.Parse(currentVersion).ToString(2);
return twoPartCurrent == twoPartSupported;
}

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions