ci: Add time
prefixing before most commands
We don't have timestamps set up right now, and including timing information is easy and useful to debug CI speed.
This commit is contained in:
parent
d5227781de
commit
836315084e
@ -7,7 +7,7 @@
|
||||
set -euo pipefail
|
||||
|
||||
CXX_VER=$(cargo metadata --format-version 1 | jq -r '.packages[]|select(.name == "cxx").version')
|
||||
cargo install cxxbridge-cmd --version "${CXX_VER}"
|
||||
time cargo install cxxbridge-cmd --version "${CXX_VER}"
|
||||
|
||||
CBINDGEN_VER=$(cargo metadata --format-version 1 | jq -r '.packages[]|select(.name == "cbindgen").version')
|
||||
cargo install cbindgen --version "${CBINDGEN_VER}"
|
||||
time cargo install cbindgen --version "${CBINDGEN_VER}"
|
||||
|
@ -12,7 +12,7 @@ fi
|
||||
|
||||
# we have the canonical spec file handy so just builddep from that
|
||||
# XXX: use --allowerasing as a temporary hack to ease the migration to libmodulemd2
|
||||
dnf builddep --spec -y packaging/rpm-ostree.spec.in --allowerasing
|
||||
time dnf builddep --spec -y packaging/rpm-ostree.spec.in --allowerasing
|
||||
# Mostly dependencies for tests; TODO move these into the spec file
|
||||
# and also put them in the cosa buildroot (or another container)
|
||||
pkg_install ostree{,-devel,-grub2} createrepo_c /usr/bin/jq python3-pyyaml \
|
||||
|
@ -10,35 +10,33 @@ export PATH="$HOME/.cargo/bin:$PATH"
|
||||
|
||||
pkg_upgrade() {
|
||||
echo "Running dnf -y distro-sync... $(date)"
|
||||
dnf -y distro-sync
|
||||
time dnf -y distro-sync
|
||||
echo "Done dnf -y distro-sync! $(date)"
|
||||
}
|
||||
|
||||
make() {
|
||||
/usr/bin/make -j ${MAKE_JOBS:-$(getconf _NPROCESSORS_ONLN)} "$@"
|
||||
time /usr/bin/make -j ${MAKE_JOBS:-$(getconf _NPROCESSORS_ONLN)} "$@"
|
||||
}
|
||||
|
||||
build() {
|
||||
env NOCONFIGURE=1 ./autogen.sh
|
||||
./configure --prefix=/usr --libdir=/usr/lib64 --sysconfdir=/etc "$@"
|
||||
make V=1
|
||||
time ./configure --prefix=/usr --libdir=/usr/lib64 --sysconfdir=/etc "$@"
|
||||
time make V=1
|
||||
}
|
||||
|
||||
pkg_install() {
|
||||
echo "Running dnf -y install... $(date)"
|
||||
dnf -y install "$@"
|
||||
time dnf -y install "$@"
|
||||
echo "Done running dnf -y install! $(date)"
|
||||
}
|
||||
|
||||
pkg_builddep() {
|
||||
echo "Running builddep... $(date)"
|
||||
# This is sadly the only case where it's a different command
|
||||
if test -x /usr/bin/dnf; then
|
||||
dnf builddep -y "$@"
|
||||
time dnf builddep -y "$@"
|
||||
else
|
||||
yum-builddep -y "$@"
|
||||
time yum-builddep -y "$@"
|
||||
fi
|
||||
echo "Done running builddep! $(date)"
|
||||
}
|
||||
|
||||
pkg_install_builddeps() {
|
||||
@ -50,6 +48,6 @@ pkg_install_builddeps() {
|
||||
if [ $# -ne 0 ]; then
|
||||
pkg_builddep "$@"
|
||||
pkg_install "$@"
|
||||
rpm -e "$@"
|
||||
time rpm -e "$@"
|
||||
fi
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user