mirror of
https://github.com/keymanapp/keyman.git
synced 2026-08-16 05:39:24 +00:00
Relates to #10207. Adds the `api` action to build.sh for each affected module. The `api` action for each module will generate the api metadata files, and then the markdown files are generated by /developer/build.sh api. Note that developer-utils, kmc, and kmcmplib have no api documentation at this time (and kmcmplib is not Typescript so would need separate tooling anyway).
47 lines
1.6 KiB
Bash
Executable file
47 lines
1.6 KiB
Bash
Executable file
#!/usr/bin/env bash
|
|
## START STANDARD BUILD SCRIPT INCLUDE
|
|
# adjust relative paths as necessary
|
|
THIS_SCRIPT="$(readlink -f "${BASH_SOURCE[0]}")"
|
|
. "${THIS_SCRIPT%/*}/../../../resources/build/build-utils.sh"
|
|
## END STANDARD BUILD SCRIPT INCLUDE
|
|
|
|
. "$KEYMAN_ROOT/resources/shellHelperFunctions.sh"
|
|
. "$KEYMAN_ROOT/resources/build/build-utils-ci.inc.sh"
|
|
|
|
cd "$THIS_SCRIPT_PATH"
|
|
|
|
# TODO: "@/common/models/types" \
|
|
|
|
builder_describe "Build Keyman kmc Lexical Model Compiler module" \
|
|
"@/common/web/keyman-version" \
|
|
"@/developer/src/common/web/test-helpers" \
|
|
"clean" \
|
|
"configure" \
|
|
"build" \
|
|
"api analyze API and prepare API documentation" \
|
|
"test" \
|
|
"pack build a local .tgz pack for testing" \
|
|
"publish publish to npm" \
|
|
"--dry-run,-n don't actually publish, just dry run"
|
|
|
|
builder_describe_outputs \
|
|
configure /node_modules \
|
|
build /developer/src/kmc-model/build/src/main.js \
|
|
api /developer/build/api/kmc-model.api.json
|
|
|
|
builder_parse "$@"
|
|
|
|
#-------------------------------------------------------------------------------------------------------------------
|
|
|
|
function do_build() {
|
|
npm run build
|
|
}
|
|
|
|
builder_run_action clean rm -rf ./build/ ./tsconfig.tsbuildinfo
|
|
builder_run_action configure verify_npm_setup
|
|
builder_run_action build do_build
|
|
builder_run_action api api-extractor run --local --verbose
|
|
builder_run_action test npm test
|
|
builder_run_action publish builder_publish_to_npm
|
|
builder_run_action pack builder_publish_to_pack
|
|
|