1 /** @page releases Release Processes
3 This page provides an introduction to the OpenOCD Release Processes:
5 - @ref releasewhy - Explain the motivations for producing
6 releases on a regular basis.
7 - @ref releasewho - Describes the responsibilities and
8 authority required to produce official OpenOCD releases.
9 - @ref releasewhen - Provides guidelines for scheduling
10 activities for each release cycle.
11 - @ref releasehow - Outlines all of the steps for the
12 processes used to produce and release the package source archives.
13 - @ref releasescriptcmds - Introduces the automated @c release.sh script.
15 @section releasewhy Why Produce Releases?
17 The OpenOCD maintainers produce <i>releases</i> periodically for many
18 reasons. This section provides the key reasons for making releases on a
19 regular basis and why a set of <i>release processes</i> should be used
22 At any time, <i>source archives</i> can be produced by running
23 <code>make dist</code> in the OpenOCD project tree. With the 0.2.0
24 release, this command will package the tree into several popular archive
25 formats: <code>openocd-\<version\>.{tar.gz,tar.bz2,zip}</code>. If
26 produced properly, these files are suitable for release to the public.
28 When properly versioned and released for users, these archives present
29 several important advantages compared to using the source repository
30 (including snapshots downloaded from that repository using gitweb):
32 -# They allow others to package and distribute the code using
33 consistent version labels. Users won't normally need to care
34 whose package they use, just the version of OpenOCD.
35 -# They contain a working configure script and makefiles, which
36 were produced as part of creating the archive.
37 -# Because they have been formally released by the project, users
38 don't need to try a random work-in-process revision. Releasing
39 involves spending some time specifically on quality improvments,
40 including bugfixing source code and documentation.
41 -# They provide developers with the flexibility needed to address
42 larger issues, which sometimes involves temporary breakage.
44 Hopefully, this shows several good reasons to produce regular releases,
45 but the release processes were developed with some additional design
46 goals in mind. Specifically, the releases processes should have the
49 -# Produce successive sets of archives cleanly and consistently.
50 -# Implementable as a script that automates the critical steps.
51 -# Prevent human operators from producing broken packages, when possible.
52 -# Allow scheduling and automation of building and publishing milestones.
54 The current release processes are documented in the following sections.
55 They attempt to meet these design goals, but improvements may still
58 @subsection version_labels Version Labels
60 Users can display the OpenOCD version string in at least two
61 ways. The command line <code>openocd -v</code> invocation
62 displays it; as does the Tcl <code>version</code> command.
64 Labels for released versions look like <em>0.3.0</em>, or
65 <em>0.3.0-rc1</em> for a preliminary release.
66 Non-released (developer) versions look like <em>0.3.0-dev</em>,
67 or <em>0.3.0-rc1-dev</em>.
68 In all cases, additional tags may be appended to those base
69 release version labels.
71 The <code>tools/release/version.sh</code> script is used to
72 manipulate version IDs found in the source tree.
74 @subsubsection releaseversions Release Versions and Tags
76 The OpenOCD version string is composed of three numeric components
77 separated by two decimal points: @c x.y.z, where @c x is the @a major
78 version number, @c y is the @a minor number, and @c z is the @a micro.
79 For any <em>bug-fix</em> release, the micro version number will be non-zero
80 (<code>z > 0</code>). For a <i>minor release</i>, the micro version
81 number will be zero (<code>z = 0</code>). For a <i>major releases</i>,
82 the minor version will @a also be zero (<code>y = 0, z = 0</code>).
84 After these required numeric components, release version strings
85 may contain tags such as as <em>-rc1</em> or <em>-rc2</em>.
86 These 'rc' tags indicate "release candidate" versions of the package.
87 Like major/minor/micro numbers, these are updated
88 as part of the release process.
90 The release process includes version number manipulations to the tree
91 being released, ensuring that all numbers are incremented (or rolled
92 over) at the right time and in the proper locations of the repository.
93 One of those manipulations creates a repository tag matching that
94 release's version label.
96 @subsubsection releaseversionsdist Packager Versions
98 Distributors of patched versions of OpenOCD are encouraged to extend the
99 version string with a unique version tag when producing external
100 releases, as this helps to identify your particular distribution series.
101 Knowing that a release has such patches can be essential to tracking
102 down and fixing bugs.
104 Packager version tags should always be suffixes to the version
105 code from the OpenOCD project, signifying modifications to the
106 original code base. Each packager release should have a unique
109 For example, the following command will add a 'foo' tag to the
110 configure.in script of a local copy of the source tree, giving
111 a version label like <em>0.3.0-foo</em>:
114 tools/release/version.sh version tag add foo
117 This command will modify the configure.in script in your working copy
118 only. After running the @c bootstrap sequence, the tree can be patched
119 and used to produce your own derived versions. You might check that
120 change into a private branch of your git tree, along with the other
121 patches you are providing.
123 You can also "bump" those tags (so "foo1" becomes "foo2" etc)
124 each time a derived package is released, incrementing the tag's
125 version to facilitate tracking the changes you have distributed.
128 tools/release/version.sh version bump tag foo
131 Of course, any patches in your branches must be provided to
132 your customers, and be in conformance with the GPL. In most
133 cases you should also work to merge your improvements to the
136 @subsubsection version_tags Development Versions and Tags
138 Everything except formal releases should have the tag <em>-dev</em>
139 in their version number. This helps developers identify reports
140 created from non-release versions, and it can be detected and
141 manipulated by the release script. Specifically, this tag will be
142 removed and re-added during the release process; it should never be
143 manipulated by developers in submitted patches.
145 Versions built from developer trees may have additional tags.
146 Trees built from git snapshots have <em>snapshot</em> tags.
147 When built from a "live" git tree, tags specify
148 specific git revisions:
150 0.3.0-rc1-dev-00015-gf37c9b8-dirty
152 indicates a development tree based on git revison f37c9b8
153 (a truncated version of a SHA1 hash) with some non-git
154 patches applied (the <em>dirty</em> tag). This information
155 can be useful when tracking down bugs.
156 (Note that at this writing, the tags do not directly
157 correspond to <code>git describe</code> output. The
158 hash ID can be used with <code>git show</code>, but
159 the relevant repository tag isn't <em>0.3.0-rc1-dev</em>;
160 this might change in the future.)
162 @section releasewho Release Manager
164 OpenOCD archive releases will be produced by an individual filling the
165 role of <i>Release Manager</i>, hereafter abbreviated as <i>RM</i>. This
166 individual determines the schedule and executes the release processes
169 @subsection releasewhohow RM Authority
171 Each release requires one individual to fulfill the RM role; however,
172 graceful transitions of this authority may take place at any time. The
173 current RM may transfer their authority to another contributor in a post
174 to the OpenOCD development mailing list. Such delegation of authority
175 must be approved by the individual that will receive it and the
176 community of maintainers. Initial arrangements with the new RM should
177 be made off-list, as not every contributor wants these responsibilities.
179 @subsection releasewhowhat RM Responsibilities
181 In addition to the actual process of producing the releases, the RM is
182 responsible for keeping the community informed of all progress through
183 the release cycle(s) being managed. The RM is responsible for managing
184 the changes to the package version, though the release tools should
185 manage the tasks of adding or removing any required development branch
186 tags and incrementing the version.
188 These responsibilities matter most towards the end of the release
189 cycle, when the RM creates the first RC and all contributors enter
190 a quality-improvement mode. The RM works with other contributors
191 to make sure everyone knows what kinds of fixes should merge, the
192 status of major issues, and the release timetable.
194 In particular, the RM has the final decision on whether a given
195 bug should block the release.
197 @section releasewhen Release Schedule
199 The OpenOCD release process must be carried out on a periodic basis, so
200 the project can realize the benefits presented in answer to the question,
203 Starting with the 0.2.0 release, the OpenOCD project expects to produce
204 new releases every few months.
205 Bug fix releases could be provided more frequently. These release
206 schedule goals may be adjusted in the future, after the project
207 maintainers and distributors receive feedback and experience.
209 More importantly, the statements made in this section do not create an
210 obligation by any member of the OpenOCD community to produce new
211 releases on regular schedule, now or in the future.
213 @subsection releasewhenexample Sample Schedule
215 The RM must pro-actively communicate with the community from the
216 beginning of the development cycle through the delivery of the new
217 release. This section presents guidelines for scheduling key points
218 where the community must be informed of changing conditions.
220 If Tn is the time of release n, then the following schedule
221 might describe some key T0-to-T1 release cycle milestones.
223 - T0 ... End of T0 release cycle. T1 cycle starts, with merge
224 window opening. Developers begin to merge queued work.
225 - <em>... several weeks of merge window ...</em>
226 - RC1 ... Close mainline to new work. Produce RC1
227 release, begin testing phase; developers are in "bugfix mode",
228 all other work is queued; send out planned endgame schedule.
229 - RC2 ... Produce RC2 and send schedule update to
230 mailing list, listing priorities for remaining fixes
231 - <em>... more RC milestones, until ready ...</em>
232 - T1: End of T1 release cycle. T2 cycle starts, with merge
233 window opening. Developers begin to merge queued work.
235 Note that until it happens, any date for T1 is just a goal.
236 Critical bugs prevent releases from happening. We are just
237 beginning to use this window-plus-RCs process, so the lengths
238 of the merge windows versus the RC phase is subject to change.
239 Most projects have RC phases of a month or more.
241 Some additional supplemental communication will be desirable. The above
242 list omits the step-by-step instructions to daily release management.
243 Individuals performing release management need to have the ability to
244 interact proactively with the community as a whole, anticipating when
245 such interaction will be required and giving ample notification.
247 The next section explains why the OpenOCD project allows significant
248 flexibility in the part of the development that precedes the release
251 @subsection releasewhenflex Schedule Flexibility
253 The Release Manager should attempt to follow the guidelines in this
254 document, but the process of scheduling each release milestone should be
255 community driven at the start. Features that don't complete before
256 the merge window closes can be held (perhaps in some branch) until
257 the next merge window opens, rather than delaying the release cycle.
260 Manager cannot schedule the work that will be done on the project,
261 when it will be submitted, reviewed, and deemed suitable to be committed.
262 That is, the RM cannot act as a priest in a cathedral; OpenOCD uses
263 the bazaar development model. The release schedule must adapt
264 continuously in response to changes in the rate of work.
265 Fewer releases may be
266 required if developers contribute less patches, and more releases may be
267 desirable if the project continues to grow and experience high rates of
268 community contribution. During each cycle, the RM should be tracking
269 the situation and gathering feedback from the community.
271 @section releasehow Release Process: Step-by-Step
273 The release process is not final; it may need more iterations
275 While there are release scripts, key steps require community
276 support; the Release Manager isn't the only participant.
278 The following steps should be followed to produce each release:
280 -# Produce final patches using a local clone of mainline. Nobody
281 except the RM should be committing anything. <em>Everyone with commit
282 privileges needs to know and agree to this in advance!</em> Even the RM
283 only commits a handful of updates as part of the release process
284 itself ... to files which are part of the version identification scheme
285 or release process; and to create the version tag; and then to open the
286 merge window for the next release cycle.
287 -# Finalize @c the NEWS file to describe the changes in the release
288 - This file is used to automatically post "blurbs" about the project.
289 - This material should have been produced during the development cycle,
290 by adding items for each @c NEWS-worthy contribution, when committed
291 during the merge window. (One part of closing the merge window, by
292 opening the RC phase of the release, is the commitment to hold all
293 further such contributions until the next merge window opens.)
294 - The RM should make sure nothing important was omitted, as part of
295 the RC1 cycle. From then on, no more updates to NEWS content should
296 be needed (except to seed the process for the next release, or maybe
297 if a significant and longstanding bug is fixed late in the RC phase).
298 -# Bump library version if our API changed (not yet required)
299 -# Update and commit the final package version in @c configure.in:
300 (The <code>tools/release/version.sh</code> script might help ensure
301 the versions are named properly.):
302 -# Remove @c -dev tag.
303 -# Update any @c -rc tag:
304 - If producing the final release from an -rc series, remove it
305 - If producing the first RC in a series, add rc1
306 - If producing the next RC in a series, bump the rc number
307 -# Commit that version change, with a good descriptive comment.
308 -# Create a git tag for the final commit, with a tag name matching
309 the version string in <code>configure.in</code> (including <em>-rcN</em>
312 PACKAGE_VERSION="x.y.z"
313 PACKAGE_TAG="v${PACKAGE_VERSION}"
314 git tag -m "The openocd-${PACKAGE_VERSION} release." "${PACKAGE_TAG}"
316 -# Do not push those changes to mainline yet; only builds using the
317 source archives you will be creating should ever be labeled as
318 official releases (with no "-dev" suffix). Since mainline is a
319 development tree, these will be pushed later, as part of opening
320 the merge window for the next release cycle (restoring the "-dev"
321 suffix for that next release.) Those version and tag updates are
322 the last ones to be included in the release being made.
323 -# Produce the release files, using the local clone of the source
324 tree which holds the release's tag and updated version in
325 @c configure.in ... this is used only to produce the release, and
326 all files should already be properly checked out.
327 -# Run <code>tools/release.sh package</code> to produce the
328 source archives. This automatically bootstraps and
329 configures the process.
330 -# Run <code>tools/release.sh stage</code> to create an @c archives
331 directory with the release data, including MD5 and SHA1
332 checksum files (which are used with Berlios).
333 -# Sanity check at least one of those archives, by extracting and
334 configuring its contents, using them to build a copy of OpenOCD,
335 and verifying that the result prints the correct release version
336 in its startup banner. (For example,
337 "configure --enable-ft2232_libftdi --enable-parport"
338 then "make" and run "src/openocd -v" as a sanity check.)
339 -# Run <code>make docs</code> to create the
340 documentation which will be published.
341 -# Upload packages and post announcements of their availability:
342 -# Release packages into files section of project sites:
344 -# Under "Project Admin", use the "File Manager"
345 -# Create a new folder under "openocd" named "${PACKAGE_VERSION}"
346 -# Upload the @c NEWS file and mark it as the release notes.
347 -# Upload the three source archive files, using the Web interface,
348 into that folder. Verify the upload worked OK by checking the
349 MD5 and SHA1 checksums computed by SourceForge against the
350 versions created as part of staging the release.
351 -# Also upload doc/openocd.pdf (the User's Guide) so the version
352 matching each release will be easily available.
353 -# Select each file in the release, and use the property panel
354 to set its type and select the right release notes.
355 - .tar.bz2: Linux, Mac
356 - .tar.gz: BSD, Solaris, Others
358 - For openocd.pdf just associate it with the right release notes.
359 -# Create an SF.net project news update.
361 -# Provide @c NEWS file, as requested.
362 -# Upload the release files via FTP to ftp://ftp.berlios.de/incoming/
363 -# Edit descriptions for each file (one at a time) Note that Berlios
364 does not automatically checksum files, and it uses a very old
365 version of the SourceForge code with user interface issues.
366 -# Click button to send E-mail Release Notice.
367 -# Depending on how paranoid you're feeling today, verify the images by
368 downloading them from the websites and making sure there are no
369 differences between the downloaded copies and your originals.
370 -# Publish User's and Developer's Guides to the project web sites:
371 -# Use SCP to update the SF.net web site with PDF and HTML for the
372 User's Guide, and HTML for the developer's guide ... you can
373 instantiate a shell.sourceforge.net instance and set up symlinks
374 from your home directory, to simplify this process.
375 -# (How to update the Berlios web site with the same data?)
376 -# Post announcement e-mail to the openocd-development list.
378 -# Post an update on the Berlios blog (if it lets you)
379 -# Announce updates on freshmeat.net and other trackers.
380 -# Submit updates to news feeds (e.g. Digg, Reddit, etc.).
381 -# Resume normal development on mainline, by opening the merge window for
382 the next major or minor release cycle. (You might want to do this
383 before all the release bits are fully published.)
384 - Update the version label in the @c configure.in file:
385 - Restore @c -dev version tag.
386 - For a new minor release cycle, increment the release's minor number
387 - For a new major release cycle, increment the release's major number
388 and zero its minor number
389 - Archive @c NEWS file as "<code>doc/news/NEWS-${PACKAGE_VERSION}</code>".
390 - Create a new @c NEWS file for the next release
391 - Commit those changes.
392 - Push all the updates to mainline.
393 - Last updates for the release, including the release tag (you
394 will need to "git push --tags").
395 - Updates opening the merge window
396 - At this point, it's OK for commiters to start pushing changes
397 which have been held off until the next release. (Any bugfixes to
398 this release will be against a bug-fix release branch starting from
399 the commit you tagged as this release, not mainline.)
400 - Announce to the openocd-development list. Ideally, you will also
401 be able to say who is managing the next release cycle.
403 To start a bug-fix release branch:
404 -# Create a new branch, starting from a major or
406 -# Restore @c -dev version tag.
407 -# Bump micro version number in configure.in
408 -# Backport bugfix patches from mainline into that branch.
409 (Always be sure mainline has the fix first, so it's hard
410 to just lose a bugfix.)
411 -# Commit and push those patches.
412 -# When desired, release as above ... except note that the next
413 release of a bugfix branch is never a new major or minor release
415 @subsection releasescriptcmds Release Script Commands
417 The @c release.sh script automates some of the steps involved
418 in making releases, simplifying the Release Manager's work.
420 The release script can be used for two tasks:
421 - Creating releases and starting a new release cycle:
424 tools/release.sh --type=minor --final --start-rc release
426 - Creating a development branch from a tagged release:
428 git checkout 'v0.2.0'
429 tools/release.sh --type=micro branch
432 Both of these variations make automatic commits and tags in your
433 repository, so you should be sure to run it on a cloned copy before
434 proceding with a live release.
436 @subsection releasescriptopts Release Script Options
438 The @c release.sh script recognizes some command-line options that
441 - The @c --start-rc indicates that the new development release cycle
442 should start with @c -rc0. Without this, the @c -rc tag will be omitted,
443 leading to non-monotonic versioning of the in-tree version numbers.
444 - The @c --final indicates that the release should drop the @c -rc tag,
445 to going from @c x.y.z-rcN-dev to x.y.z.
447 @subsection releasescriptenv Release Script Environment
449 The @c release.sh script recognizes some environment variables which
452 - @c CONFIG_OPTS : Passed as options to the configure script.
453 - @c MAKE_OPTS : Passed as options to the 'make' processes.
455 @section releasetutorial Release Tutorials
457 This section should contain a brief tutorial for using the Release
458 Script to perform release tasks, but the new script needs to be
461 @section releasetodo Release Script Shortcomings
463 Improved automated packaging and distribution of OpenOCD requires more
464 patching of the configure script. The final release script should be
465 able to manage most steps of the processes. The steps requiring user
466 input could be guided by an "assistant" that walks the Release Manager
467 through the process from beginning to end, performing basic sanity
468 checks on their various inputs (e.g. the @c NEWS blurb).
472 This file contains the @ref releases page.