File tree Expand file tree Collapse file tree 5 files changed +72
-24
lines changed
.github/ISSUE_TEMPLATE/releases
tools-local/tasks/Microsoft.DotNet.SourceBuild.Tasks.XPlat Expand file tree Collapse file tree 5 files changed +72
-24
lines changed Original file line number Diff line number Diff line change 37
37
- [ 3.1 / 5.0]
38
38
- [ ] Verify that the ` PrivateSourceBuiltArtifactsPackageVersion ` in ` eng/Versions.props ` matches N-1 release artifacts.
39
39
- [ ] Update the ` global.json ` SDK version to N-1: the latest released "3.1.XYY" SDK version, where "3.1.X" matches the SDK we're building.
40
+ - [ ] Update the ` eng/Versions.props ` with the latest product versions.
40
41
1 . - [ ] [ 2.1] Fetch internal git data for submodules.
41
42
1 . Run ` git submodule update --init --recursive ` and see errors due to missing commits.
42
43
1 . Run ` fetch-vsts-commits.sh ` with a PAT to automatically fetch internal refs.
Original file line number Diff line number Diff line change 1
1
<?xml version =" 1.0" encoding =" utf-8" ?>
2
2
<Project ToolsVersion =" 4.0" xmlns =" http://schemas.microsoft.com/developer/msbuild/2003" >
3
+ <!-- SDK/Runtime Version Information -->
4
+ <PropertyGroup >
5
+ <MajorVersion >5</MajorVersion >
6
+ <MinorVersion >0</MinorVersion >
7
+ <RuntimePatchVersion >2</RuntimePatchVersion >
8
+ <SdkPatchVersion >102</SdkPatchVersion >
9
+ <RuntimeProductVersion >$(MajorVersion).$(MinorVersion).$(RuntimePatchVersion)</RuntimeProductVersion >
10
+ <AspNetCoreProductVersion >$(MajorVersion).$(MinorVersion).$(RuntimePatchVersion)</AspNetCoreProductVersion >
11
+ <SdkProductVersion >$(MajorVersion).$(MinorVersion).$(SdkPatchVersion)</SdkProductVersion >
12
+ </PropertyGroup >
13
+
3
14
<!-- Repo Version Information -->
4
15
<PropertyGroup >
5
16
<VersionPrefix >0.1.0</VersionPrefix >
Load Diff This file was deleted.
Original file line number Diff line number Diff line change 65
65
<EnvironmentVariables Include =" DotNetPackageVersionPropsPath=$(PackageVersionPropsPath)" />
66
66
</ItemGroup >
67
67
68
+ <UsingTask AssemblyFile =" $(XPlatSourceBuildTasksAssembly)" TaskName =" ReplaceRegexInFiles" />
69
+
70
+ <Target Name =" FixAspNetCoreVersion"
71
+ AfterTargets =" ApplyPatches" >
72
+
73
+ <ItemGroup >
74
+ <MinifiedJavascriptFile Include =" $(ProjectDirectory)**\blazor.server.js" />
75
+ </ItemGroup >
76
+
77
+ <!--
78
+ Patch the version embedded in minified js files. Because they are
79
+ minified files, git patch doesn't work too well and produces unreadable
80
+ binary patches.
81
+ -->
82
+ <ReplaceRegexInFiles
83
+ InputFiles =" @(MinifiedJavascriptFile)"
84
+ OldTextRegex =" ,l=" 5\.0\.\d+" }]\);"
85
+ NewText =" ,l=" $(AspNetCoreProductVersion)" }]);" />
86
+
87
+ </Target >
88
+
68
89
<Target Name =" SetOutputList" AfterTargets =" Package" BeforeTargets =" GatherBuiltPackages" >
69
90
<ItemGroup >
70
91
<PackagesOutputList Include =" $(ShippingPackagesOutput)" />
Original file line number Diff line number Diff line change
1
+ // Licensed to the .NET Foundation under one or more agreements.
2
+ // The .NET Foundation licenses this file to you under the MIT license.
3
+ // See the LICENSE file in the project root for more information.
4
+
5
+ using System ;
6
+ using System . IO ;
7
+ using System . Text . RegularExpressions ;
8
+ using Microsoft . Build . Framework ;
9
+ using Microsoft . Build . Utilities ;
10
+
11
+ namespace Microsoft . DotNet . Build . Tasks
12
+ {
13
+ public class ReplaceRegexInFiles : Task
14
+ {
15
+ [ Required ]
16
+ public string [ ] InputFiles { get ; set ; }
17
+
18
+ [ Required ]
19
+ public string OldTextRegex { get ; set ; }
20
+
21
+ [ Required ]
22
+ public string NewText { get ; set ; }
23
+
24
+ public override bool Execute ( )
25
+ {
26
+ Log . LogMessage ( $ "Replacing '{ OldTextRegex } ' with '{ NewText } '") ;
27
+ foreach ( string file in InputFiles )
28
+ {
29
+ string fileContents = File . ReadAllText ( file ) ;
30
+
31
+ fileContents = Regex . Replace ( fileContents , OldTextRegex , NewText ) ;
32
+
33
+ File . WriteAllText ( file , fileContents ) ;
34
+ }
35
+
36
+ return true ;
37
+ }
38
+ }
39
+ }
You can’t perform that action at this time.
0 commit comments