forked from enlightenment/efl
Annotating the build log with timings will help us to understand better where the time is spend during the builds and see areas to optimize. Switching over to the "native" bash functions in Travis, so switching all scripts to bash. Signed-off-by: Stefan Schmidt <s.schmidt@samsung.com> Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de> Differential Revision: https://phab.enlightenment.org/D11913devs/stefan/ci-timing-stats
parent
5c5f0692fc
commit
26fa4ea355
12 changed files with 59 additions and 76 deletions
@ -1,9 +1,13 @@ |
||||
#!/bin/sh |
||||
#!/bin/bash |
||||
|
||||
set -e |
||||
|
||||
travis_fold start "ccache-stats" |
||||
travis_time_start "ccache-stats" |
||||
if [ "$DISTRO" != "" ] ; then |
||||
docker exec $(cat $HOME/cid) ccache -s |
||||
elif [ "$TRAVIS_OS_NAME" = "osx" ]; then |
||||
ccache -s |
||||
fi |
||||
travis_time_finish "ccache-stats" |
||||
travis_fold end "ccache-stats" |
||||
|
@ -1,15 +1,16 @@ |
||||
#!/bin/sh |
||||
#!/bin/bash |
||||
|
||||
set -e |
||||
. .ci/travis.sh |
||||
|
||||
if [ "$1" != "exactness" ] ; then |
||||
exit 0 |
||||
fi |
||||
|
||||
travis_fold exactness "exactness" |
||||
travis_fold start "exactness" |
||||
travis_time_start "exactness" |
||||
if [ "$DISTRO" != "" ] ; then |
||||
docker exec --env EIO_MONITOR_POLL=1 $(cat $HOME/cid) sh -c 'git -C /exactness-elm-data pull' |
||||
docker exec --env EIO_MONITOR_POLL=1 --env LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/usr/local/lib:/usr/local/lib64 --env EINA_LOG_LEVELS_GLOB=eina_*:0,ecore*:0,efreet*:0,eldbus:0,elementary:0 $(cat $HOME/cid) exactness -j 20 -b /exactness-elm-data/default-profile -p /exactness-elm-data/default-profile/ci-fedora32-tests.txt |
||||
fi |
||||
travis_endfold exactness |
||||
travis_time_finish "exactness" |
||||
travis_fold end "exactness" |
||||
|
@ -1,15 +1,17 @@ |
||||
#!/bin/sh |
||||
#!/bin/bash |
||||
|
||||
set -e |
||||
. .ci/travis.sh |
||||
|
||||
if [ "$1" != "default" ] ; then |
||||
exit 0 |
||||
fi |
||||
travis_fold benchmark "ninja benchmark" |
||||
travis_fold start "ninja-benchmark" |
||||
travis_time_start "ninja-benchmark" |
||||
if [ "$DISTRO" != "" ] ; then |
||||
docker exec --env EIO_MONITOR_POLL=1 --env ELM_ENGINE=buffer $(cat $HOME/cid) ninja benchmark -C build |
||||
elif [ "$TRAVIS_OS_NAME" = "osx" ]; then |
||||
export PATH="/usr/local/opt/ccache/libexec:$(brew --prefix gettext)/bin:$PATH" |
||||
ninja benchmark -C build |
||||
fi |
||||
travis_endfold benchmark |
||||
travis_time_finish "ninja-benchmark" |
||||
travis_fold end "ninja-benchmark" |
||||
|
@ -1,24 +0,0 @@ |
||||
#!/bin/sh |
||||
|
||||
# https://github.com/travis-ci/travis-rubies/blob/9f7962a881c55d32da7c76baefc58b89e3941d91/build.sh#L38-L44 |
||||
|
||||
travis_fold() { |
||||
echo -e "travis_fold:start:$1\033[33;1m$2\033[0m" |
||||
} |
||||
travis_endfold() { |
||||
echo -e "\ntravis_fold:end:$1\r" |
||||
} |
||||
|
||||
travis_time_start() { |
||||
travis_timer_id=$(printf %08x $(( RANDOM * RANDOM ))) |
||||
travis_start_time=$(travis_nanoseconds) |
||||
echo -en "travis_time:start:$travis_timer_id\r${ANSI_CLEAR}" |
||||
} |
||||
|
||||
travis_time_finish() { |
||||
local result=$? |
||||
travis_end_time=$(travis_nanoseconds) |
||||
local duration=$(($travis_end_time-$travis_start_time)) |
||||
echo -en "\ntravis_time:end:$travis_timer_id:start=$travis_start_time,finish=$travis_end_time,duration=$duration\r${ANSI_CLEAR}" |
||||
return $result |
||||
} |
Loading…
Reference in new issue