Skip to content

Commit 68f7e3a

Browse files
authored
Fix discrepancy between Version.Details.xml and Versions.props (#7314)
* Fix discrepancy between Version.Details.xml and Versions.props * Add step to CodeCheck to ensure Version.Details.xml and Versions.props match
1 parent 075612b commit 68f7e3a

File tree

4 files changed

+252
-172
lines changed

4 files changed

+252
-172
lines changed

docs/ReferenceResolution.md

Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,3 +33,37 @@ The requirements that led to this system are:
3333
* [eng/PatchConfig.props](/eng/PatchConfig.props) - lists which assemblies or packages are patching in the current build.
3434
* [eng/ProjectReferences.props](/eng/ProjectReferences.props) - lists which assemblies or packages might be available to be referenced as a local project
3535
* [eng/Versions.props](/eng/Versions.props) - contains a list of versions which may be updated by automation.
36+
37+
## Example: adding a new project
38+
39+
Steps for adding a new project to this repo.
40+
41+
1. Create the .csproj
42+
2. Run `eng/scripts/GenerateProjectList.ps1`
43+
3. Add it to Extensions.sln
44+
45+
## Example: adding a new dependency
46+
47+
Steps for adding a new package dependency to an existing project. Let's say I'm adding a dependency on System.Banana.
48+
49+
1. Add the package to the .csproj file using `<Reference Include="System.Banana" />`
50+
2. Add an entry to [eng/Dependencies.props](/eng/Dependencies.props), `<LatestPackageReference Include="System.Banana" Version="0.0.1-beta-1" />`
51+
3. If this package comes from another dotnet team and should be updated automatically by our bot...
52+
1. Change the LatestPackageReference entry to `Version="$(SystemBananaPackageVersion)"`.
53+
2. Add an entry to [eng/Versions.props](/eng/Versions.props) like this `<SystemBananaPackageVersion>0.0.1-beta-1</SystemBananaPackageVersion>`.
54+
3. Add an entry to [eng/Version.Details.xml](/eng/Version.Details.xml) like this:
55+
56+
```xml
57+
<ProductDependencies>
58+
<!-- ... -->
59+
</Dependency>
60+
<Dependency Name="System.Banana" Version="0.0.1-beta-1">
61+
<Uri>https://github.com/dotnet/corefx</Uri>
62+
<Sha>000000</Sha>
63+
</Dependency>
64+
<!-- ... -->
65+
</ProductDependencies>
66+
```
67+
68+
If you don't know the commit hash of the source code used to produce "0.0.1-beta-1", you can use `000000` as a placeholder for `Sha`
69+
as its value is unimportant and will be updated the next time the bot runs.

0 commit comments

Comments
 (0)