Exemplo n.º 1
0
        public static BuildTargetResult ReplaceCoreHostPackaging(BuildTargetContext c)
        {
            ReplaceFileContents(@"pkg\dir.props", contents =>
            {
                DependencyInfo coreFXInfo = c.GetCoreFXDependency();
                Regex regex = new Regex(@"Microsoft\.NETCore\.Platforms\\(?<version>\d\.\d\.\d)-(?<release>.*)\\runtime\.json");

                return regex.ReplaceGroupValue(contents, "release", coreFXInfo.NewReleaseVersion);
            });

            return c.Success();
        }
Exemplo n.º 2
0
        public static BuildTargetResult ReplaceCrossGen(BuildTargetContext c)
        {
            ReplaceFileContents(@"scripts\dotnet-cli-build\CompileTargets.cs", compileTargetsContent =>
            {
                DependencyInfo coreFXInfo = c.GetCoreFXDependency();
                Regex regex = new Regex(@"CoreCLRVersion = ""(?<version>\d.\d.\d)-(?<release>.*)"";");

                return regex.ReplaceGroupValue(compileTargetsContent, "release", coreFXInfo.NewReleaseVersion);
            });

            return c.Success();
        }