Commit graph

1727 commits

Author SHA1 Message Date
Marc Durdin
5473eb43d5
Merge pull request #14236 from keymanapp/maint/web/14225-simplify-rsync-call-and-download-info-build
maint(web): cleanup rsync call from bash for Windows agents and refactor
2025-07-01 06:04:45 +07:00
Marc Durdin
90b7c34df8 maint(web): cleanup rsync call from bash for Windows agents and refactor
Refactors the Powershell script which built the .download_info file for
web into the keyman-web-release.sh script, and then bypasses the path
rewriting that msys does when calling a Windows executable (rsync).

This was tricky because msys was mangling all the paths to Windows-style
but we specifically need to reference one remote Unix-style path in the
rsync call. As we wanted to move away from the Powershell script anyway,
it was cleaner to resolve this in one go by moving the whole script to
bash.

The new tc-download-info.inc.sh script is a minimally generalized
version of the download_info writing from keyman-linux-release.sh, and
once the dust settles, it would be good to DRY this out.

Note that this is still Windows-only, despite the rest of the build
being basically platform-agnostic. I wanted to get this stable before we
generalize, which should be fairly straightforward, as it's only the
rsync call which will be touched.

Tested locally with a drop-in Windows executable that just prints its
arguments, to verify that path mangling is not occurring where we don't
want it. The DEBUG lines in keyman-web-release.sh will be removed once
we are confident this is correct.

Fixes: #14225
2025-06-29 10:13:22 +10:00
Eberhard Beilharz
399baddf23
refactor(linux): rename linux agent specific functions
This change prefixes functions with `ba_` that are intended to be run on
a Linux build agent. That should make it easier to distinguish them from
functions that deal with building Keyman for Linux.

Test-bot: skip
2025-06-25 20:13:09 +02:00
Marc Durdin
41b89bb0d1 maint(resources): add pr-build-status test to resources/build.sh
Also tweak one output string for clarity.

Build-bot: skip
2025-06-25 05:51:00 +10:00
Marc Durdin
bb282303e4 maint(resources): minor cleanup
Build-bot: skip
2025-06-25 05:47:12 +10:00
Marc Durdin
6ab6e2b20e fix(resources): use correct payload for status event 2025-06-24 16:54:56 +10:00
Marc Durdin
9de8d260cc maint(resources): support additional workflow events for pr-build-status
Also retrieves the correct SHA from each workflow event.

Build-bot: skip
Test-bot: skip
2025-06-24 16:49:19 +10:00
Marc Durdin
795f9f75ae maint(resources): build pr-build-status.yml from sources 2025-06-24 09:47:12 +10:00
Marc Durdin
3be1bd942d
Merge pull request #14199 from keymanapp/maint/resources/14172-pr-build-status-2
maint(resources): add pr-build-status GitHub Action to summarize build status 🤖
2025-06-24 06:07:30 +07:00
Marc Durdin
61e1b4ca37
Merge pull request #14217 from keymanapp/maint/resources/allow-target-branch-names-in-rrtb
fix(resources): allow branch names in run-required-test-builds shortcut call
2025-06-24 06:07:16 +07:00
Marc Durdin
0f4a1cdfe7 fix(resources): allow branch names in run-required-test-builds shortcut call
This is a transitional patch while we wait for the Build-bot changes to
flow through all the open PRs. Fixes the broken master test build.
2025-06-24 09:03:28 +10:00
Marc Durdin
a6936a3a41
Merge pull request #14196 from keymanapp/maint/developer/support-buildLevel
maint(developer): support buildLevel 🤖
2025-06-24 05:53:13 +07:00
Marc Durdin
27196068ae chore(common): Merge branch 'maint/common/pr-build-bot' of https://github.com/keymanapp/keyman into maint/common/pr-build-bot 2025-06-23 05:14:36 +10:00
Marc Durdin
94cdf834df maint(common): polish docs and add tests for build-bot 2025-06-23 05:05:01 +10:00
Marc Durdin
deb18b4811 maint(resources): add pr-build-status check run GHA
Adds a check run to verify the outcome of all builds on the branch, so
that we can add branch protection rules.

Fixes: #14172
Build-bot: skip
2025-06-19 07:36:06 +10:00
Marc Durdin
825f7d2df0
Merge branch 'maint/common/pr-build-bot' into maint/developer/support-buildLevel 2025-06-16 04:54:29 +07:00
Marc Durdin
81c941313b
Merge branch 'master' into maint/common/pr-build-bot 2025-06-16 03:52:39 +07:00
Marc Durdin
156bdcdd8a maint(common): rename and move builder_if_release_build_level 2025-06-16 06:45:42 +10:00
Marc Durdin
f3136d5ab2 maint(developer): skip signature check on buildLevel build 2025-06-16 05:54:33 +10:00
Marc Durdin
870d37f56b maint(developer): only copy .dbg/.pdb on release buildLevel 2025-06-16 05:40:30 +10:00
Marc Durdin
11a558e926 maint(developer): support buildLevel
Relates-to: 14125
Build-bot: build
Test-bot: skip
2025-06-14 15:22:15 +10:00
Marc Durdin
d4fd05f470 docs(common): add build-bot documentation 2025-06-14 07:29:49 +10:00
Marc Durdin
9896fb878f maint(common): pass buildLevel to TeamCity / GHA 2025-06-14 07:29:31 +10:00
Eberhard Beilharz
3542ed4a9d
Merge pull request #14194 from keymanapp/maint/web/fixrelease
However, we have to use double quotes inside of the string as well so that it gets treated as a command with parameters instead of a single command with spaces.

Follow-up-of: #14168
Part-of: #13399
Test-bot: skip
2025-06-13 22:17:00 +02:00
Eberhard Beilharz
860a1c1aff
maint(developer,web): use double quotes inside the string again
However, we have to use double quotes inside of the string as well so
that it gets treated as a command with parameters instead of a single
command with spaces.

Follow-up-of: #14168
Part-of: #13399
Test-bot: skip
2025-06-13 22:02:06 +02:00
Eberhard Beilharz
7868bec04c
maint(developer): fix developer release build
Follow-up-of: #14184
Part-of: #13399
Test-bot: skip
2025-06-13 18:39:39 +02:00
Eberhard Beilharz
895883cae0
maint(developer,web): use braces for variables in powershell scripts
This changes variable references in the powershell scripts to use braces
(`${FOO}` instead of `$FOO`). This solves the problem where powershell
considers the colon in the rsync command as being part of a variable.
This should fix release builds for Web and Developer.

Also commented some unused variables.

Follow-up-of: #14167,#14168
Part-of: #13399
Test-bot: skip
2025-06-13 12:45:16 +02:00
Marc Durdin
3754cac89b maint(resources): only automatically merge keyman-server PRs with automerge label
Prevents PRs from keyman-server from being merged unless they already
have the 'automerge' label. This supports the upcoming epic-master-merge
infrastructure, where we would like to automatically approve the PRs but
allow maintainers to merge when ready.

We cannot specify required status checks at this point, because we don't
necessarily know which status checks will be required for a given PR. A
future improvement would be to define a new status check which verifies
that all the expected builds for a given PR have passed, and then make
that into a required status check for all master,beta,stable-x.y,epic/
branches. This status check would need to be updated automatically
whenever another status check completes. Probably should be implemented
as a GHA.

In the future, we could move to using GitHub's auto-merge functionality,
and not use the current auto-merge action but that's a much bigger
change.

Also, upgraded auto-approve to v4.0.0 to remove node deprecation
warnings.
2025-06-13 09:32:04 +10:00
Eberhard Beilharz
8ee1127f13
Merge pull request #14168 from keymanapp/maint/developer/fixrelease
This fixes developer release builds. Previously we used single quotes for specifying `--rsync-path`. This caused the parameter to contain the variable name instead of the content.

Also define and set the variables in a powershell script so that they can be used. This was already done for the other powershell scripts, but overlooked for `download-symbol-server-index.ps1`. Also use variables instead of hard-coding values.

Follow-up-of: #14059
Part-of: #13399
Test-bot: skip
2025-06-12 23:07:02 +02:00
Eberhard Beilharz
917e83d7ad
maint(web): use double quotes so that variable gets replaced
This fixes web release builds. Previously we used single quotes
for specifying `--rsync-path`. This caused the parameter to contain
the variable name instead of the content.
2025-06-12 18:32:34 +02:00
Eberhard Beilharz
4bfb35c19f
maint(developer): use double quotes so that variable gets replaced
This fixes developer release builds. Previously we used single quotes
for specifying `--rsync-path`. This caused the parameter to contain
the variable name instead of the content.

Follow-up-of: #14059
Part-of: #13399
Test-bot: skip
2025-06-12 18:28:15 +02:00
Eberhard Beilharz
6e7071ada6
maint(developer): define (and use) variables in developer release build
We have to define and set the variables in a powershell script so that
they can be used. This was already done for the other powershell scripts,
but overlooked for this one. Also use variables instead of hard-coding
values.
2025-06-12 18:24:15 +02:00
Eberhard Beilharz
bfa8165033
maint(web): add some more arguments for web release build script
Previously rsync used some TC variables. Now with the build step being
a script the TC variables are no longer accessible from the script, so
we add new arguments to the build script and then use these when calling
rsync. A similar changer was already made previously for the developer
release build.

Follow-up-of: #14049
Related: #14059
Part-of: #13399
Test-bot: skip
2025-06-12 17:40:59 +02:00
Marc Durdin
b2e8418c2a
Merge branch 'master' into maint/common/pr-build-bot 2025-06-11 10:37:03 +07:00
Marc Durdin
7b32085e0f
Merge pull request #14155 from keymanapp/maint/common/14146_macregex
maint(resources): fix regression on mac triggering builds
2025-06-11 08:39:13 +07:00
Marc Durdin
95af46d0c9
Merge pull request #14156 from keymanapp/maint/web/14151_uploadscript
maint(web): use path when calling powershell script
2025-06-11 08:29:08 +07:00
Eberhard Beilharz
fd314eb2f7
maint(developer): export environment variables
Export the newly introduced variables so that they are available in the
powershell script.

Fixes: #14150
Follow-up-of: #14052
Test-bot: skip
2025-06-10 19:43:47 +02:00
Eberhard Beilharz
1fdff7d66c
maint(web): use path when calling powershell script
Also remove the check if we're running on Windows since that is already
happening in the calling function.

Fixes: #14151
Follow-up-of: #14049
Test-bot: skip
2025-06-10 19:02:04 +02:00
Eberhard Beilharz
656c4b8c6d
maint(resources): fix regression on mac triggering builds
The `grep` available on macOS doesn't have the `--perl-regexp` option,
so the changes introduced in #14047 caused a regression. This change
directly makes use of Perl which is available on macOS.

Fixes: #14146
Follow-up-of: #14047
Test-bot: skip
2025-06-10 18:53:08 +02:00
Eberhard Beilharz
7ef985dbd8
Merge pull request #14058 from keymanapp/maint/developer/14045_docker 2025-06-10 17:32:26 +02:00
Marc Durdin
a4c8f568f1
Merge branch 'master' into maint/common/pr-build-bot 2025-06-07 12:54:17 +07:00
Eberhard Beilharz
33fe775aa7
maint(developer): use docker buildx to build docker images
This change verifies that `docker buildx` is available and then uses that
for building the images. For that we apparently need the magic line at
the top of the `Dockerfile`s and set the environment variable
`DOCKER_BUILDKIT`. This solves a problem building docker images on
Linux with an older Docker version where the heredocs didn't work.
2025-06-06 18:10:53 +02:00
Eberhard Beilharz
f13134100c
maint(developer): specify platforms as targets instead of actions in run.sh
This adjusts `resources/docker-images/run.sh` to more closely match
the syntax in `build.sh`.
2025-06-06 17:07:02 +02:00
Eberhard Beilharz
a4b9fe67e3
Merge pull request #14059 from keymanapp/maint/developer/13399_tc-config-dev-refactor
This adds a `configure` build step that will install any missing dependencies required to build on Linux.

Part-of: #13399 
Fixes: #14131
2025-06-06 09:35:16 +02:00
Eberhard Beilharz
2b73148efc
Merge pull request #14052 from keymanapp/maint/web/13399_tc-config_dev
This matches the existing TC configuration as closely as possible.

Part-of: #13399
2025-06-05 12:32:54 +02:00
Eberhard Beilharz
962eb76ef6
Merge pull request #14051 from keymanapp/maint/web/13399_tc-config_refactor
This refactors the build script and makes some changes so that it is possible to run in a docker container on a developer's machine.

Part-of: #13399
2025-06-05 12:32:00 +02:00
Marc Durdin
d9378aebb2 maint(common): Build-bot now available to control test builds
The Build-bot command is available now to control which platforms are
built. See the wiki for instructions on how to use Build-bot.

Build-bot: build
Test-bot: skip
2025-06-05 15:05:35 +07:00
Eberhard Beilharz
8679b6db1d
maint(developer): change to correct directory for powershell scripts 2025-06-05 09:42:39 +02:00
Eberhard Beilharz
36fb4d30b8
maint(web): fix working directory for zipping artifacts for Web release
This fixes the Keyman for Web release builds - the script expects to be
run from `${KEYMANROOT}/web`.
2025-06-05 09:07:17 +02:00
Eberhard Beilharz
ce86bcd6a0
maint(developer): fix build on Windows agents
Windows agents have NVM installed in a different place, and always enabled
so we don't need to set variables for NVM.
2025-06-05 09:00:23 +02:00