Skip to content

doc: stop writing the version into the release instructions - #371

Merged
deemar merged 2 commits into
HardySimpson:masterfrom
yegorich:doc/release-no-version-churn
Oct 8, 2026
Merged

deemar merged 2 commits into
HardySimpson:masterfrom
yegorich:doc/release-no-version-churn

Conversation

@yegorich

Copy link
Copy Markdown
Contributor

The RELEASE section used the version of the day as its worked example, in five places, so it was wrong the moment that release was cut -- it still said 1.2.19 with 1.2.20 in the tree.

The commands now read the version out of src/version.h instead of repeating it:

zlog_version() { sed -n 's/^#define ZLOG_VERSION "\(.*\)"/\1/p' src/version.h; }
git tag -a "$(zlog_version)" -m "version: $(zlog_version)"

which is also harder to get wrong than copying a number into three commands, and the prose says MAJOR.MINOR.PATCH where it used to name a release. Nothing in the section needs touching at release time now.

The note about zlog.spec keeping its own Version: moves up into step 1, where it is actionable, rather than sitting at the end as a caveat.

Checked that the documented sed prints 1.2.20 against the current tree.

yegorich and others added 2 commits September 30, 2026 10:43
The RELEASE section used the version of the day as its worked example, in
five places, so it was wrong the moment that release was cut -- it still
said 1.2.19 with 1.2.20 in the tree.

The commands now read the version out of src/version.h instead of
repeating it:

    zlog_version() { sed -n 's/^#define ZLOG_VERSION "\(.*\)"/\1/p' src/version.h; }
    git tag -a "$(zlog_version)" -m "version: $(zlog_version)"

which is also harder to get wrong than copying a number into three
commands, and the prose says MAJOR.MINOR.PATCH where it used to name a
release. Nothing in the section needs touching at release time now.

The note about zlog.spec keeping its own Version: moves up into step 1,
where it is actionable, rather than sitting at the end as a caveat.

Checked that the documented sed prints 1.2.20 against the current tree.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Nothing in the tree referenced it. CPack writes its own spec from the
CPACK_RPM_* variables in cpack/CMakeLists.txt -- CPackRPM.cmake puts it in
SPECS/<name>.spec and only takes a hand written one through
CPACK_RPM_USER_BINARY_SPECFILE, which is not set here. Debian, the one
distribution that ships zlog, packages it from its own debian/ directory,
and there is no Fedora package at all.

So the only way this file was used is someone running rpmbuild on it by
hand, and it would not have served them well:

    %define _builddir %(echo $PWD)   # no Source0, builds the current directory
    AIRTAME Web Service is powering the setup page.   # not this project
    install -d '%{buildroot}/usr/lib'   # lib64 on every x86_64 RPM distro
    cp src/libzlog.so.1.2 ...           # not the soname file, libzlog.so.1.2.20
    make clean all                      # ignores the CMake build

with no devel subpackage and none of the pkg-config or CMake files
packaged. It had also sat at 1.2.8 for eleven releases, which is what drew
attention to it.

Making it correct would mean a zlog.spec.in generated from src/version.h,
with Source0, %{_libdir}, a devel split and the %cmake macros. That is
worth doing if someone wants zlog in Fedora; until then this is a wrong
file that looks authoritative. The release instructions lose the step that
kept it in step.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
@deemar
deemar merged commit 06f9f3d into HardySimpson:master Oct 8, 2026
32 checks passed
@yegorich
yegorich deleted the doc/release-no-version-churn branch October 8, 2026 07:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants