scripts/shell/extractspec.sh
2024-03-20 11:28:46 -05:00

13 lines
265 B
Bash
Executable file

#!/usr/bin/env bash
#
# read all .src.rpm and extract the .spec
# bsdtar is part of libarchive (http://libarchive.org/)
#
# SPDX-License-Identifier: MIT
for RPM in ./*.src.rpm; do
VER=${RPM%.src.rpm}
bsdtar -xOf "${RPM}" \*.spec > "./${VER}.spec"
done
exit 0