/// <summary>
        /// Sets the platform target.
        /// </summary>
        /// <param name="settings">The settings.</param>
        /// <param name="target">The target.</param>
        /// <returns>The same <see cref="MSBuildSettings"/> instance so that multiple calls can be chained.</returns>
        public static MSBuildSettings SetPlatformTarget(this MSBuildSettings settings, string target)
        {
            if (settings == null)
            {
                throw new ArgumentNullException(nameof(settings));
            }

            settings.WithProperty("Platform", target);
            return(settings);
        }
Exemple #2
0
 /// <summary>
 /// Sets the package version.
 /// </summary>
 /// <param name="settings">The settings.</param>
 /// <param name="packageVersion">The package version.</param>
 /// <returns>The same <see cref="MSBuildSettings"/> instance so that multiple calls can be chained.</returns>
 public static MSBuildSettings SetPackageVersion(this MSBuildSettings settings, string packageVersion)
 => settings.WithProperty("PackageVersion", packageVersion);
Exemple #3
0
 /// <summary>
 /// Sets the package release notes.
 /// </summary>
 /// <param name="settings">The settings.</param>
 /// <param name="packageReleaseNotes">The package release notes.</param>
 /// <returns>The same <see cref="MSBuildSettings"/> instance so that multiple calls can be chained.</returns>
 public static MSBuildSettings SetPackageReleaseNotes(this MSBuildSettings settings, string packageReleaseNotes)
 => settings.WithProperty("PackageReleaseNotes", packageReleaseNotes);
Exemple #4
0
 /// <summary>
 /// Sets the informational version.
 /// </summary>
 /// <param name="settings">The settings.</param>
 /// <param name="informationalVersion">The informational version.</param>
 /// <returns>The same <see cref="MSBuildSettings"/> instance so that multiple calls can be chained.</returns>
 public static MSBuildSettings SetInformationalVersion(this MSBuildSettings settings, string informationalVersion)
 => settings.WithProperty("InformationalVersion", informationalVersion);
Exemple #5
0
 /// <summary>
 /// Sets the assembly version.
 /// </summary>
 /// <param name="settings">The settings.</param>
 /// <param name="assemblyVersion">The assembly version.</param>
 /// <returns>The same <see cref="MSBuildSettings"/> instance so that multiple calls can be chained.</returns>
 public static MSBuildSettings SetAssemblyVersion(this MSBuildSettings settings, string assemblyVersion)
 => settings.WithProperty("AssemblyVersion", assemblyVersion);
Exemple #6
0
 /// <summary>
 /// Sets the file version.
 /// </summary>
 /// <param name="settings">The settings.</param>
 /// <param name="fileVersion">The file version.</param>
 /// <returns>The same <see cref="MSBuildSettings"/> instance so that multiple calls can be chained.</returns>
 public static MSBuildSettings SetFileVersion(this MSBuildSettings settings, string fileVersion)
 => settings.WithProperty("FileVersion", fileVersion);
Exemple #7
0
 /// <summary>
 /// Sets the version suffix.
 /// </summary>
 /// <param name="settings">The settings.</param>
 /// <param name="versionSuffix">The version suffix.</param>
 /// <returns>The same <see cref="MSBuildSettings"/> instance so that multiple calls can be chained.</returns>
 public static MSBuildSettings SetVersionSuffix(this MSBuildSettings settings, string versionSuffix)
 => settings.WithProperty("VersionSuffix", versionSuffix);
Exemple #8
0
 /// <summary>
 /// Sets the version.
 /// </summary>
 /// <param name="settings">The settings.</param>
 /// <param name="version">The version.</param>
 /// <returns>The same <see cref="MSBuildSettings"/> instance so that multiple calls can be chained.</returns>
 /// <remarks>
 /// Version will override VersionPrefix and VersionSuffix if set.
 /// This may also override version settings during packaging.
 /// </remarks>
 public static MSBuildSettings SetVersion(this MSBuildSettings settings, string version)
 => settings.WithProperty("Version", version);