Skip to content

Commit d6d9570

Browse files
committed
release: add linux to Debian package filenames
Linux tarballs already identify their platform in the filename, while Debian packages do not. Give both artifacts the same microsoft-git_<version>_linux_<architecture> basename so release assets follow a consistent naming convention. The build and staging steps must agree on this basename; otherwise staging tries to move a file that dpkg-deb never created. Keep the Debian package metadata unchanged: the qualifier identifies the release asset, not the installed package. Assisted-by: GPT-6.1 Sol Signed-off-by: Matthew John Cheetham <mjcheetham@outlook.com>
1 parent 81a1edf commit d6d9570

1 file changed

Lines changed: 5 additions & 4 deletions

File tree

‎.azure-pipelines/release.yml‎

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1156,7 +1156,7 @@ extends:
11561156
echo "$BUILD_VERSION" >version
11571157
make GIT-VERSION-FILE
11581158
1159-
PKGNAME="microsoft-git_${VERSION}_$(deb_arch)"
1159+
PKGNAME="microsoft-git_${VERSION}_linux_$(deb_arch)"
11601160
PKGDIR="$(Build.ArtifactStagingDirectory)/pkgroot"
11611161
rm -rf "$PKGDIR"
11621162
mkdir -p "$PKGDIR/DEBIAN"
@@ -1221,9 +1221,10 @@ extends:
12211221
12221222
staging_dir="$(Build.ArtifactStagingDirectory)"
12231223
mkdir -p "$staging_dir/_final"
1224-
mv "$staging_dir/app/microsoft-git_$(git_version)_$(deb_arch).deb" "$staging_dir/_final/"
1225-
tar -czf "$staging_dir/_final/microsoft-git_$(git_version)_linux_$(deb_arch).tar.gz" \
1226-
-C "$staging_dir/pkgroot" usr
1224+
pkg_name="microsoft-git_$(git_version)_linux_$(deb_arch)"
1225+
mv "$staging_dir/app/$pkg_name.deb" "$staging_dir/_final/"
1226+
tar -czf "$staging_dir/_final/$pkg_name.tar.gz" \
1227+
-C "$staging_dir/pkgroot" usr
12271228
# Validate the freshly built .deb in-place: install it
12281229
# and assert `git --version`. Folded into the build job
12291230
# so it runs on the same agent without the 1ES job-

0 commit comments

Comments
 (0)