Skip to content

Commit 6713284

Browse files
committed
Release 2.9.8: Fix tarball to include all necessary files
- Fixed release tarball generation to include bash completion script, Makefile, source files, and other essential components - Improved tarball generation to use git archive as source of truth, eliminating manual file inventory - Added bash completion information to man page
1 parent 9566df0 commit 6713284

File tree

9 files changed

+62
-34
lines changed

9 files changed

+62
-34
lines changed

.github/workflows/release.yml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,9 @@ jobs:
2121
uses: actions/checkout@v4
2222
with:
2323
fetch-depth: 0
24+
- name: Fix git ownership for container
25+
run: |
26+
git config --global --add safe.directory "$GITHUB_WORKSPACE"
2427
- name: Verify tag/version consistency
2528
id: ver
2629
run: |
@@ -52,7 +55,7 @@ jobs:
5255
with:
5356
name: keychain-${{ steps.ver.outputs.version }}-artifacts
5457
path: |
55-
keychain-${{ steps.ver.outputs.version }}.tar.gz
58+
dist/keychain-${{ steps.ver.outputs.version }}.tar.gz
5659
keychain
5760
keychain.1
5861
.release-notes.md

.gitignore

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,4 +7,4 @@ keychain.txt
77
keychain.spec
88
.specstory/
99
.ci-artifacts*/
10-
/keychain-*.tar.gz
10+
dist/

ChangeLog.md

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,22 @@
11
# ChangeLog for Keychain - https://github.com/danielrobbins/keychain
22

3+
## keychain 2.9.8 (2 Nov 2025)
4+
5+
This release fixes the release tarball to include all necessary files for building and using keychain.
6+
7+
Bug fixes:
8+
9+
* Fixed release tarball generation to include bash completion script (`completions/keychain.bash`),
10+
Makefile, source files, and other essential components. Previous release (2.9.7) tarball was
11+
missing these files.
12+
* Improved tarball generation to use `git archive` as source of truth, eliminating manual file
13+
inventory and preventing future omissions.
14+
* Updated release logic to use `dist/` directory for archive generation.
15+
16+
Documentation:
17+
18+
* Added bash completion information to keychain man page (NOTES section).
19+
320
## keychain 2.9.7 (31 Oct 2025)
421

522
This release fixes critical issues with spaces in HOME directories and usernames, and adds official Git Bash on Windows compatibility.

Makefile

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,6 @@ Y ?= $(shell date +'%Y')
1111
PREFIX ?= /usr/local
1212
COMPLETIONSDIR ?= $(PREFIX)/share/bash-completion/completions
1313

14-
TARBALL_CONTENTS=keychain README.md ChangeLog.md COPYING.txt MAINTAINERS.txt keychain.pod keychain.1 keychain.spec
15-
1614
all: keychain.1 keychain keychain.spec
1715

1816
.PHONY : tmpclean
@@ -61,17 +59,19 @@ keychain: keychain.sh keychain.txt VERSION MAINTAINERS.txt
6159
keychain.txt: keychain.pod
6260
pod2text keychain.pod keychain.txt
6361
64-
keychain-$V.tar.gz: $(TARBALL_CONTENTS)
65-
mkdir keychain-$V
66-
cp $(TARBALL_CONTENTS) keychain-$V
67-
/bin/tar czvf keychain-$V.tar.gz keychain-$V
68-
rm -rf keychain-$V
69-
ls -l keychain-$V.tar.gz
62+
keychain-$V.tar.gz: keychain keychain.1 keychain.spec
63+
mkdir -p dist
64+
rm -rf dist/keychain-$V
65+
git archive --format=tar --prefix=keychain-$V/ HEAD | tar -xf - -C dist/
66+
cp keychain keychain.1 keychain.spec dist/keychain-$V/
67+
tar -C dist -czf dist/keychain-$V.tar.gz keychain-$V
68+
rm -rf dist/keychain-$V
69+
ls -l dist/keychain-$V.tar.gz
7070
7171
# --- Release Automation Helpers ---
7272
.PHONY: release release-refresh
7373
74-
RELEASE_ASSETS=keychain-$V.tar.gz keychain keychain.1
74+
RELEASE_ASSETS=dist/keychain-$V.tar.gz keychain keychain.1
7575
7676
# "release" will orchestrate a tagged release with CI artifact validation & confirmation.
7777
release: $(RELEASE_ASSETS)

VERSION

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
2.9.7
1+
2.9.8

keychain.pod

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -737,5 +737,11 @@ Keychain was created and is currently maintained by Daniel Robbins. To report a
737737
bug or request an enhancement, use the issue tracker at
738738
L<https://github.com/danielrobbins/keychain>.
739739

740+
Keychain includes bash completion support for command-line options, SSH keys,
741+
GPG keys, and extended mode prefixes (C<sshk:>, C<gpgk:>, C<host:>). The
742+
completion script is included in the source tarball at
743+
C<completions/keychain.bash>. For installation instructions, see the README
744+
file or run C<make install-completions>.
745+
740746
The former Funtoo Linux wiki page is preserved only as an historical reference:
741747
L<https://www.funtoo.org/Funtoo:Keychain>.

scripts/release-create.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ notes_file=$(mktemp)
1313
# Artifact path vars (provided by orchestrator if using CI artifacts)
1414
ASSET_KEYCHAIN=${KEYCHAIN_ASSET_KEYCHAIN:-keychain}
1515
ASSET_MAN=${KEYCHAIN_ASSET_MAN:-keychain.1}
16-
ASSET_TARBALL=${KEYCHAIN_ASSET_TARBALL:-keychain-$VER.tar.gz}
16+
ASSET_TARBALL=${KEYCHAIN_ASSET_TARBALL:-dist/keychain-$VER.tar.gz}
1717

1818
echo "Creating release $VER"
1919
json=$(mktemp)

scripts/release-orchestrate.sh

Lines changed: 22 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -35,9 +35,9 @@ if [ "$MODE" = create ]; then
3535
fi
3636

3737
# 1. Ensure local assets exist
38-
for f in keychain-$VER.tar.gz keychain keychain.1; do
38+
for f in dist/keychain-$VER.tar.gz keychain keychain.1; do
3939
[ -f "$f" ] || { echo "Missing local asset: $f" >&2; exit 1; }
40-
done
40+
done
4141

4242
# 2. Fetch CI artifacts (MANDATORY)
4343
CI_DIR=".ci-artifacts-$VER"
@@ -111,48 +111,50 @@ EOF
111111
}
112112

113113
# Process artifacts with specialized logic
114-
for artifact in keychain keychain.1 keychain-$VER.tar.gz; do
115-
if [ ! -f "$CI_DIR/$artifact" ]; then
116-
printf ' %-20s CI copy missing; comparison failed (abort)\n' "$artifact"
114+
for artifact in keychain keychain.1 dist/keychain-$VER.tar.gz; do
115+
# Get basename for CI comparison
116+
basename_artifact=$(basename "$artifact")
117+
if [ ! -f "$CI_DIR/$basename_artifact" ]; then
118+
printf ' %-20s CI copy missing; comparison failed (abort)\n' "$basename_artifact"
117119
diff_flag=1
118120
continue
119121
fi
120-
case "$artifact" in
122+
case "$basename_artifact" in
121123
keychain)
122-
L=$(calc_sha256 "$artifact"); R=$(calc_sha256 "$CI_DIR/$artifact")
124+
L=$(calc_sha256 "$artifact"); R=$(calc_sha256 "$CI_DIR/$basename_artifact")
123125
if [ "$L" = "$R" ]; then
124-
printf ' %-20s %s (match)\n' "$artifact" "$L"
126+
printf ' %-20s %s (match)\n' "$basename_artifact" "$L"
125127
else
126-
printf ' %-20s LOCAL %s != CI %s *DIFF*\n' "$artifact" "$L" "$R"
128+
printf ' %-20s LOCAL %s != CI %s *DIFF*\n' "$basename_artifact" "$L" "$R"
127129
diff_flag=1
128130
fi
129131
;;
130132
keychain.1)
131133
# Direct hash first
132-
L=$(calc_sha256 "$artifact"); R=$(calc_sha256 "$CI_DIR/$artifact")
134+
L=$(calc_sha256 "$artifact"); R=$(calc_sha256 "$CI_DIR/$basename_artifact")
133135
if [ "$L" = "$R" ]; then
134-
printf ' %-20s %s (match)\n' "$artifact" "$L"
136+
printf ' %-20s %s (match)\n' "$basename_artifact" "$L"
135137
else
136138
# Normalize and compare ignoring Pod::Man header line.
137-
if diff -u <(tail -n +2 "$artifact") <(tail -n +2 "$CI_DIR/$artifact") >/dev/null 2>&1; then
138-
printf ' %-20s (normalized match ignoring Pod::Man header)\n' "$artifact"
139+
if diff -u <(tail -n +2 "$artifact") <(tail -n +2 "$CI_DIR/$basename_artifact") >/dev/null 2>&1; then
140+
printf ' %-20s (normalized match ignoring Pod::Man header)\n' "$basename_artifact"
139141
else
140-
printf ' %-20s LOCAL %s != CI %s *DIFF* (content mismatch beyond header)\n' "$artifact" "$L" "$R"
142+
printf ' %-20s LOCAL %s != CI %s *DIFF* (content mismatch beyond header)\n' "$basename_artifact" "$L" "$R"
141143
diff_flag=1
142144
fi
143145
fi
144146
;;
145147
"keychain-$VER.tar.gz")
146-
if compare_tar_content "$artifact" "$CI_DIR/$artifact"; then
148+
if compare_tar_content "$artifact" "$CI_DIR/$basename_artifact"; then
147149
# If tar blob hash matches display it; else note normalized match.
148-
L=$(calc_sha256 "$artifact"); R=$(calc_sha256 "$CI_DIR/$artifact")
150+
L=$(calc_sha256 "$artifact"); R=$(calc_sha256 "$CI_DIR/$basename_artifact")
149151
if [ "$L" = "$R" ]; then
150-
printf ' %-20s %s (match)\n' "$artifact" "$L"
152+
printf ' %-20s %s (match)\n' "$basename_artifact" "$L"
151153
else
152-
printf ' %-20s (content match; tar/gzip metadata differ)\n' "$artifact"
154+
printf ' %-20s (content match; tar/gzip metadata differ)\n' "$basename_artifact"
153155
fi
154156
else
155-
printf ' %-20s *CONTENT DIFF* (see above messages)\n' "$artifact"
157+
printf ' %-20s *CONTENT DIFF* (see above messages)\n' "$basename_artifact"
156158
diff_flag=1
157159
fi
158160
;;
@@ -182,7 +184,7 @@ fi
182184
if [ "${KEYCHAIN_FORCE_LOCAL:-}" = 1 ]; then
183185
KEYCHAIN_ASSET_KEYCHAIN="keychain"
184186
KEYCHAIN_ASSET_MAN="keychain.1"
185-
KEYCHAIN_ASSET_TARBALL="keychain-$VER.tar.gz"
187+
KEYCHAIN_ASSET_TARBALL="dist/keychain-$VER.tar.gz"
186188
echo "Source selection: USING LOCAL artifacts (override)." >&2
187189
else
188190
# All artifacts matched (raw or normalized) -> use CI versions

scripts/release-refresh.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ done
2222
echo "Uploading replacement assets..."
2323
ASSET_KEYCHAIN=${KEYCHAIN_ASSET_KEYCHAIN:-keychain}
2424
ASSET_MAN=${KEYCHAIN_ASSET_MAN:-keychain.1}
25-
ASSET_TARBALL=${KEYCHAIN_ASSET_TARBALL:-keychain-$VER.tar.gz}
25+
ASSET_TARBALL=${KEYCHAIN_ASSET_TARBALL:-dist/keychain-$VER.tar.gz}
2626

2727
# (Note: By default we do not modify existing release notes. Set KEYCHAIN_UPDATE_NOTES=1 to rebuild.)
2828

0 commit comments

Comments
 (0)