mirror of
https://github.com/keymanapp/keyman.git
synced 2026-08-14 20:59:25 +00:00
Clarifies the confusing builder.inc.sh / build-utils.sh distinction by giving the scripts more appropriate names. Most build scripts should use builder-full.inc.sh; some helper scripts can use builder-basic.inc.sh. Documented in resources/build/README.md. Renames: * resources/build/builder.inc.sh to resources/build/builder-full.inc.sh * resources/build/build-utils.sh to resources/build/builder-basic.inc.sh Other changes: * Moves Android-specific functions out of builder-basic.inc.sh and into android/build.sh. * Renames functions in builder-basic.inc.sh More functions may be moved from builder-basic.inc.sh into utils.inc.sh or other scripts in the future. Fixes: #14065 Build-bot: build all Test-bot: skip
57 lines
1.9 KiB
Bash
Executable file
57 lines
1.9 KiB
Bash
Executable file
#!/usr/bin/env bash
|
|
# TC build script for Keyman Linux/Test
|
|
# shellcheck disable=SC2164
|
|
# shellcheck disable=SC1091
|
|
|
|
## START STANDARD BUILD SCRIPT INCLUDE
|
|
# adjust relative paths as necessary
|
|
THIS_SCRIPT="$(readlink -f "${BASH_SOURCE[0]}")"
|
|
. "${THIS_SCRIPT%/*}/../../../resources/build/builder-full.inc.sh"
|
|
## END STANDARD BUILD SCRIPT INCLUDE
|
|
|
|
# shellcheck disable=SC2154
|
|
. "${KEYMAN_ROOT}/resources/build/utils.inc.sh"
|
|
. "${KEYMAN_ROOT}/resources/teamcity/includes/tc-helpers.inc.sh"
|
|
. "${KEYMAN_ROOT}/resources/teamcity/includes/tc-linux.inc.sh"
|
|
. "${KEYMAN_ROOT}/resources/teamcity/linux/linux-actions.inc.sh"
|
|
|
|
################################ Main script ################################
|
|
|
|
builder_describe \
|
|
"Tests install build, making a source package and runs unit tests." \
|
|
"all run all actions" \
|
|
"configure install dependencies" \
|
|
"build make a release build" \
|
|
"test run unit tests" \
|
|
"publish make a source tarball"
|
|
|
|
builder_parse "$@"
|
|
|
|
cd "${KEYMAN_ROOT}/linux"
|
|
|
|
function make_source_tarball_action() {
|
|
builder_echo start "make source tarball" "Make source tarball"
|
|
rm -rf dist
|
|
make tmpsources
|
|
builder_echo end "make source tarball" success "Finished making source tarball"
|
|
}
|
|
|
|
if builder_has_action all; then
|
|
linux_install_dependencies_action
|
|
linux_additional_test_dependencies_action
|
|
|
|
tc_set_variables_for_nvm
|
|
|
|
linux_build_action --coverage
|
|
linux_unit_tests_action --coverage --report --no-integration
|
|
make_source_tarball_action
|
|
else
|
|
builder_run_action configure linux_install_dependencies_action
|
|
builder_run_action configure linux_additional_test_dependencies_action
|
|
|
|
tc_set_variables_for_nvm
|
|
|
|
builder_run_action build linux_build_action --coverage
|
|
builder_run_action test linux_unit_tests_action --coverage --report --no-integration
|
|
builder_run_action publish make_source_tarball_action
|
|
fi
|