armbian-next: optimize for CONFIG_DEFS_ONLY=yes, skipping stacktraces/git info
This commit is contained in:
parent
b7fa6fa8b0
commit
2a68cc6e9e
@ -56,7 +56,8 @@ function do_main_configuration() {
|
||||
|
||||
[[ -z "${CHROOT_CACHE_VERSION}" ]] && CHROOT_CACHE_VERSION=7
|
||||
|
||||
if [[ -d "${SRC}/.git" ]]; then
|
||||
if [[ -d "${SRC}/.git" && "${CONFIG_DEFS_ONLY}" != "yes" ]]; then # don't waste time if only gathering config defs
|
||||
display_alert "Getting git info for repo" "${SRC}" "debug"
|
||||
BUILD_REPOSITORY_URL="$(git remote get-url "$(git remote | grep origin || true)" || true)" # ignore all errors
|
||||
BUILD_REPOSITORY_COMMIT="$(git describe --match=d_e_a_d_b_e_e_f --always --dirty || true)" # ignore error
|
||||
fi
|
||||
|
||||
@ -1,7 +1,8 @@
|
||||
# Helper function, to get clean "stack traces" that do not include the hook/extension infrastructure code.
|
||||
function get_extension_hook_stracktrace() {
|
||||
local sources_str="$1" # Give this ${BASH_SOURCE[*]} - expanded
|
||||
local lines_str="$2" # And this # Give this ${BASH_LINENO[*]} - expanded
|
||||
[[ "${CONFIG_DEFS_ONLY}" == "yes" ]] && return 0 # don't waste time here
|
||||
local sources_str="$1" # Give this ${BASH_SOURCE[*]} - expanded
|
||||
local lines_str="$2" # And this # Give this ${BASH_LINENO[*]} - expanded
|
||||
local sources lines index final_stack=""
|
||||
IFS=' ' read -r -a sources <<< "${sources_str}"
|
||||
IFS=' ' read -r -a lines <<< "${lines_str}"
|
||||
@ -29,6 +30,7 @@ function get_extension_hook_stracktrace() {
|
||||
}
|
||||
|
||||
function show_caller_full() {
|
||||
[[ "${CONFIG_DEFS_ONLY}" == "yes" ]] && return 0 # don't waste time here
|
||||
{
|
||||
local i=1 # skip the first frame
|
||||
local line_no
|
||||
|
||||
Loading…
Reference in New Issue
Block a user