Commit graph

26 commits

Author SHA1 Message Date
Marc Durdin
f394245636 maint(common): consolidate builder scripts
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
2025-08-02 08:11:24 +10:00
Eberhard Beilharz
4d81589f48
maint(common): use unique names for Keyman version variables
Previously the builder scripts defined a readonly `VERSION` environment
variable for the Keyman version. That caused problems when another
(external) script tried to define a `VERSION` variable. We encountered
this problem when trying to move the TC build steps of a configuration
into a single script (#13399) when we tried to source `~/.nvm/nvm.sh`.

This change uses a Keyman specific prefix for the version variables and
renames `VERSION` → `KEYMAN_VERSION` etc. Unfortunately these variables
are used in a lot of places, so this turned out to be a bit of a yak
shave.

Test-bot: skip
2025-05-07 18:46:51 +02:00
Marc Durdin
7d17913e18 feat(developer): seed kmc-copy 2024-10-22 10:28:00 +07:00
Marc Durdin
939134a9a3 feat(developer): kmc-generate module
Plenty of todo items left but this is a mostly-functional module for the
kmc generate command for automatically creating keyboard and model
projects.
2024-09-03 06:15:33 +07:00
Marc Durdin
c8a1c6aa39 chore(developer): use builder.inc.sh instead of build-utils.sh in build scripts
also, remove old Makefiles
2024-05-20 06:34:46 +07:00
Marc Durdin
debb799caa fix(common): upgrade sentry-cli to 2.31.0
Fixes #11091.

Updating to latest sentry-cli on all projects, reviewed release notes
and there do not appear to be any breaking changes.

sentry-cli 2.19.4 had a bug with uploading wasm symbols:
https://github.com/getsentry/sentry-cli/issues/1682

It was fixed in 2.20.0:
https://github.com/getsentry/sentry-cli/releases/tag/2.20.0
2024-04-03 10:48:35 +07:00
Marc Durdin
d7411ec4c4 fix(developer): version string matches for sentry
Fixes two things:
* $VERSION_GIT_TAG was being misinterpreted by mkver as
  $VERSION + "_GIT_TAG". This has been addressed by making the $VERSION
  match the last one in the replaceVersionStrings_Mkver function, and
  also have moved to using the newer $VersionGitTag and $Environment
  vartiables instead.
* The 'dist' property was being set in sentry-cli sourcemap uploads,
  though we never set the dist prop when we initialize sentry.
2024-02-22 11:48:56 +07:00
Marc Durdin
335675dd6c chore(developer): try paths from resource parent instead
This matches the paths as shown in the server URLs
2024-02-22 10:14:38 +07:00
Marc Durdin
34f144259a fix(developer): strip paths from keymanweb sourcemaps when uploading to sentry
For keymanweb distribution only, strip all paths from sourcemaps when
uploading to Sentry, by running the sourcemap upload from the specific
folder. This maps to sentry-manager's stripping of paths in its
reporting.
2024-02-22 10:12:17 +07:00
Marc Durdin
5900ab4079 fix(developer): use --no-dedupe flag to avoid HTTP 414 in sentry-cli
Ref https://github.com/getsentry/sentry-cli/issues/1657

Seeing requests with > 16K URI (e.g. 48KB!) like:

  GET https://sentry.io/api/0/projects/keyman/keyman-developer/releases/release@17.0.273-beta-test-10798/files/?cursor=&checksum=004512221481ac19e94117147b07f028ba6c31d4&...

This will skip the de-dupe phase which is intended to reduce the number
of files being uploaded; as it was failing in some cases, and thus
uploading the files anyway, I am hopeful that it will have no
significant impact on the build time.
2024-02-22 05:53:15 +07:00
Marc Durdin
d66da2da91 fix(developer): improve uploading of sourcemaps to sentry
Fixes #10720.

This makes three fixes:
* Uploads each sourcemap path separately to try and avoid the 413 error
  noted in the issue above.
* Starts from the parent folder, as it is possible that paths starting
  with .. may be ignored, as they were not being uploaded to sentry.
* Removes a number of unneeded test files and debug symbols, which
  should reduce the size of each release's debug data upload, and
  slightly speed up the build.
2024-02-21 15:49:20 +07:00
Marc Durdin
f61e65ceb9
Merge pull request #9736 from keymanapp/chore/merge-master-into-package-metadata
chore: merge master into package-metadata
2023-10-11 11:28:07 +11:00
Marc Durdin
eeb755f76a fix(windows): re-enable signature check
Fixes #9692.

Signature checking was skipped because we missed a ".virtual" to force
nmake to build the test and test_i3633 targets. This opened up a small
cascade of related formatting issues on Makefiles, and the fact that the
test_i3633 (has there ever been a more poorly named project?) Makefile
did not even work.

Refactored significantly, added same tests to Developer Makefile, and
also now verifying the .msi and installer executable.

We can improve this further but I'd like to get this in to avoid further
critical issues with code signing given the current broken signing
configuration.
2023-10-06 09:14:35 +07:00
Marc Durdin
4c07b6c49c feat(developer): remove kmcmpdll 2023-09-02 12:25:29 +04:00
Marc Durdin
bda6ba1adc chore(developer): further kmc-keyboard-info infrastructure 2023-07-26 12:02:09 +07:00
Marc Durdin
ce9c9ec9fc chore: try removing -t from sentry-cli 2023-07-13 14:48:05 +07:00
Marc Durdin
b0652c2afc chore(developer): wasm debug symbols and upload to sentry 2023-07-13 13:42:47 +07:00
Marc Durdin
31ee7bff63 feat(developer): use sentry inject for sourcemap resolution 2023-07-13 06:07:44 +07:00
Marc Durdin
b435471b24 feat(developer): add sentry reporting for kmc
Fixes #9113.

Adds sentry reporting, plus helper functions, for kmc. Includes the
now-standard `-sentry-client-test-exception` command line parameter,
with `kmcmplib` and `event` sub-options available.

Uploads kmc* sourcemaps to sentry on a release build.

On Windows, honours the registry setting for error reporting. Also
includes a command line option `--[no-]error-reporting` (must be used
prior to initial command, e.g. `kmc --no-error-reporting build ...`).
2023-07-11 15:45:41 +07:00
Marc Durdin
ce864ea923 chore: update standard script prolog to use builtin instead of dirname 2023-02-22 11:04:15 +07:00
Marc Durdin
463c7ff907 chore: remove greadlink from standard script prolog 2023-02-22 10:43:06 +07:00
Marc Durdin
067028cec2 chore: revise tag variable name to VERSION_GIT_TAG
Introduce new $VERSION_GIT_TAG environment variable, and update all
references to release@version in all projects to use the new variable.
2023-01-21 17:02:50 +07:00
Marc Durdin
34ece2182d fix(common): update sentry release identifiers to support semver
Fixes #7895.

This should mean that Sentry reports start to track semantic versions. I
have reviewed each project and I _think_ I've captured all the locations
where we need to construct release identifiers. Note that one of them
was fixed from a plain version number.

Docs on release format: https://docs.sentry.io/platforms/node/guides/serverless-cloud/configuration/releases/#bind-the-version
2023-01-17 17:04:24 +07:00
Marc Durdin
e38cc79efc feat(developer): build kmcomp-$version.zip during release build
Replaces the script building kmcomp-$version.zip in TeamCity. Will be
used for more automated keyboard testing shortly.

Means kmcomp-$version.zip will be available as an artifact in all test
builds.

@keymanapp-test-bot skip
2022-07-09 15:45:44 +10:00
Marc Durdin
4c323ec665 chore(developer): fix path in sentry-upload-difs 2022-06-21 07:01:44 +10:00
Marc Durdin
1d764d0fa0 chore(windows): split sentry-upload-difs.sh to Developer
Splits the script into separate scripts for each platform. Note that
this is only ever called from TeamCity builds.
2022-06-10 13:24:59 +10:00