|
57 | 57 | `OTelLatestStableVer` property in `Directory.Packages.props` has been
|
58 | 58 | updated to the latest stable core version.
|
59 | 59 |
|
60 |
| - 2. Run the following PowerShell from the root of the repo to get combined |
61 |
| - changelog (to be used later). |
| 60 | + 2. Generate combined CHANGELOG |
62 | 61 |
|
63 |
| - ```powershell |
64 |
| - $changelogs = Get-ChildItem -Path . -Recurse -Filter changelog.md |
65 |
| - foreach ($changelog in $changelogs) |
66 |
| - { |
67 |
| - Add-Content -Path .\combinedchangelog.md -Value "**$($changelog.Directory.Name)**" |
68 |
| - $lines = Get-Content -Path $changelog.FullName |
69 |
| - $started = $false |
70 |
| - $ended = $false |
71 |
| - foreach ($line in $lines) |
72 |
| - { |
73 |
| - if($line -like "## Unreleased" -and $started -ne $true) |
74 |
| - { |
75 |
| - $started = $true |
76 |
| - } |
77 |
| - elseif($line -like "## *" -and $started -eq $true) |
78 |
| - { |
79 |
| - $ended = $true |
80 |
| - break |
81 |
| - } |
82 |
| - else |
83 |
| - { |
84 |
| - if ($started -eq $true) |
85 |
| - { |
86 |
| - Add-Content -Path .\combinedchangelog.md $line |
87 |
| - } |
88 |
| - } |
89 |
| - } |
90 |
| - } |
91 |
| - ``` |
| 62 | + Run the PowerShell script `.\build\generate-combined-changelog.ps1 |
| 63 | + -minVerTagPrefix [MinVerTagPrefix]`. Where `[MinVerTagPrefix]` is the tag |
| 64 | + prefix (eg `core-`) for the components being released. This generates a |
| 65 | + combined changelog file to be used in GitHub release. The file is created in |
| 66 | + the repo root but should not be checked in. Move it or copy the contents off |
| 67 | + and then delete the file. |
92 | 68 |
|
93 |
| - This generates combined changelog to be used in GitHub release. Once |
94 |
| - contents of combined changelog is saved somewhere, delete the file. |
| 69 | + 3. Update CHANGELOG files |
95 | 70 |
|
96 |
| - 3. Run the following PowerShell script from the root of the repo. This updates |
97 |
| - all the changelog to have release date for the current version being |
98 |
| - released. Replace the version with actual version. In the script below, |
99 |
| - replace `1.4.0-beta.1` with the tag name chosen for the package in Step 1. |
100 |
| -
|
101 |
| - ```powershell |
102 |
| - $changelogs = Get-ChildItem -Path . -Recurse -Filter changelog.md |
103 |
| - foreach ($changelog in $changelogs) |
104 |
| - { |
105 |
| - (Get-Content -Path $changelog.FullName) -replace "Unreleased", "Unreleased |
106 |
| -
|
107 |
| - ## 1.4.0-beta.1 |
108 |
| -
|
109 |
| - Released $(Get-Date -UFormat '%Y-%b-%d')" | Set-Content -Path $changelog.FullName |
110 |
| - } |
111 |
| - ``` |
| 71 | + Run the PowerShell script `.\build\update-changelogs.ps1 -minVerTagPrefix |
| 72 | + [MinVerTagPrefix] -version [Version]`. Where `[MinVerTagPrefix]` is the tag |
| 73 | + prefix (eg `core-`) for the components being released and `[Version]` is the |
| 74 | + version being released (eg `1.9.0`). This will update `CHANGELOG.md` files |
| 75 | + for the projects being released. |
112 | 76 |
|
113 |
| - 4. Normalize PublicApi files (Stable Release Only): Run the PowerShell script |
114 |
| - `.\build\finalize-publicapi.ps1`. This will merge the contents of |
115 |
| - Unshipped.txt into the Shipped.txt. |
| 77 | + 4. **Stable releases only**: Normalize PublicApi files |
116 | 78 |
|
117 |
| - 5. The scripts in steps 2-4 run over the entire repo. Remove and undo changes |
118 |
| - under projects which are not being released. Submit a PR with the final |
119 |
| - changes and get it merged. |
| 79 | + Run the PowerShell script `.\build\finalize-publicapi.ps1 -minVerTagPrefix |
| 80 | + [MinVerTagPrefix]`. Where `[MinVerTagPrefix]` is the tag prefix (eg `core-`) |
| 81 | + for the components being released. This will merge the contents of any |
| 82 | + detected `PublicAPI.Unshipped.txt` files in the `.publicApi` folder into the |
| 83 | + corresponding `PublicAPI.Shipped.txt` files for the projects being released. |
120 | 84 |
|
121 |
| - 6. Tag Git with version to be released. We use |
| 85 | + 5. Tag Git with version to be released. We use |
122 | 86 | [MinVer](https://github.com/adamralph/minver) to do versioning, which
|
123 | 87 | produces version numbers based on git tags.
|
124 | 88 |
|
|
151 | 115 | git push origin Instrumentation.AspNetCore-1.6.0
|
152 | 116 | ```
|
153 | 117 |
|
154 |
| - 7. Go to the [list of |
| 118 | + 6. Go to the [list of |
155 | 119 | tags](https://github.com/open-telemetry/opentelemetry-dotnet/tags) and find
|
156 | 120 | the tag(s) which were pushed. Click the three dots next to the tag and
|
157 | 121 | choose `Create release`.
|
|
164 | 128 | MyGet
|
165 | 129 | workflow](https://github.com/open-telemetry/opentelemetry-dotnet/actions/workflows/publish-packages-1.0.yml).
|
166 | 130 |
|
167 |
| - 8. Validate using MyGet packages. Basic sanity checks :) |
| 131 | + 7. Validate using MyGet packages. Basic sanity checks :) |
168 | 132 |
|
169 |
| - 9. From the above build, get the artifacts from the drop, which has all the |
| 133 | + 8. From the above build, get the artifacts from the drop, which has all the |
170 | 134 | NuGet packages.
|
171 | 135 |
|
172 |
| -10. Copy all the NuGet files and symbols for the packages being released into a |
| 136 | + 9. Copy all the NuGet files and symbols for the packages being released into a |
173 | 137 | local folder.
|
174 | 138 |
|
175 |
| -11. Download latest [nuget.exe](https://www.nuget.org/downloads) into the same |
176 |
| - folder from Step 10. |
| 139 | +10. Download latest [nuget.exe](https://www.nuget.org/downloads) into the same |
| 140 | + folder from Step 9. |
177 | 141 |
|
178 |
| -12. Create or regenerate an API key from nuget.org (only maintainers have |
| 142 | +11. Create or regenerate an API key from nuget.org (only maintainers have |
179 | 143 | access). When creating API keys make sure it is set to expire in 1 day or
|
180 | 144 | less.
|
181 | 145 |
|
182 |
| -13. Run the following commands from PowerShell from local folder used in Step 10: |
| 146 | +12. Run the following commands from PowerShell from local folder used in Step 9: |
183 | 147 |
|
184 | 148 | ```powershell
|
185 | 149 | .\nuget.exe setApiKey <actual api key>
|
186 | 150 |
|
187 | 151 | get-childitem -Recurse | where {$_.extension -eq ".nupkg"} | foreach ($_) {.\nuget.exe push $_.fullname -Source https://api.nuget.org/v3/index.json}
|
188 | 152 | ```
|
189 | 153 |
|
190 |
| -14. Validate that the package(s) are uploaded. Packages are available |
| 154 | +13. Validate that the package(s) are uploaded. Packages are available |
191 | 155 | immediately to maintainers on nuget.org but aren't publicly visible until
|
192 | 156 | scanning completes. This process usually takes a few minutes.
|
193 | 157 |
|
194 |
| -15. If a new stable version of the core packages was released, open a PR to |
| 158 | +14. If a new stable version of the core packages was released, open a PR to |
195 | 159 | update the `OTelLatestStableVer` property in `Directory.Packages.props` to
|
196 | 160 | the just released stable version.
|
197 | 161 |
|
198 |
| -16. If a new stable version of a package with a dedicated `MinVerTagPrefix` was |
| 162 | +15. If a new stable version of a package with a dedicated `MinVerTagPrefix` was |
199 | 163 | released (typically instrumentation packages) open a PR to update
|
200 | 164 | `PackageValidationBaselineVersion` in the project file to reflect the stable
|
201 | 165 | version which was just released.
|
202 | 166 |
|
203 |
| -17. If a new stable version of the core packages was released, open an issue in |
| 167 | +16. If a new stable version of the core packages was released, open an issue in |
204 | 168 | the
|
205 | 169 | [opentelemetry-dotnet-contrib](https://github.com/open-telemetry/opentelemetry-dotnet-contrib)
|
206 | 170 | repo to notify maintainers to begin upgrading dependencies.
|
207 | 171 |
|
208 |
| -18. Once the packages are available on nuget.org post an announcement in the |
| 172 | +17. Once the packages are available on nuget.org post an announcement in the |
209 | 173 | [Slack channel](https://cloud-native.slack.com/archives/C01N3BC2W7Q). Note
|
210 | 174 | any big or interesting new features as part of the announcement.
|
0 commit comments