Commit graph

58 commits

Author SHA1 Message Date
Marc Durdin
f070bfbea6 fix(mac): use xcframework to support m1 2021-11-18 12:03:52 +11:00
Marc Durdin
5fac633fb6 fix(common): build script help param
When working on a new build script, I tripped over the `-?` question
mark help parameter here, as it needs to be escaped. Opted to fix all
the instances in our scripts, although AFAICT there would not have been
current bugs arising from this, as there were no conflicting one
character options lower in the case list.
2021-05-28 09:50:40 +10:00
Marc Durdin
637cc064da fix(mac): show local help in app
Fixes #3979.

Instead of loading help.keyman.com in the support frame, we now load a
local copy of the help. External links within the help will open in the
user's browser. This avoids issues of navigation to keyboard download
and other sites which won't work well.

Also, adds Back, Forward and Home buttons to the window so the user can
navigate more easily with mouse.

Finally, this means that the local help will always be synchronised with
the app version and brings the macOS help in line with the other
platforms.
2021-03-15 17:21:19 +11:00
Marc Durdin
9757e4330b fix(mac): improve robustness of altool call
Handles temporary failures calling altool where Apple servers return
"Could not find the RequestUUID" for a few minutes post-upload.

Example log we are handling:

```
[04:50:44][Step 5/5] Zipping Keyman.app for notarization to /Users/mcdurdin/buildAgent/work/99b311828f4ee7c/keyman/mac/Keyman4MacIM/build/Release/Keyman.zip
[04:50:44][Step 5/5] Uploading Keyman.zip to Apple for notarization
[04:51:23][Step 5/5] <?xml version="1.0" encoding="UTF-8"?>
[04:51:23][Step 5/5] <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
[04:51:23][Step 5/5] <plist version="1.0">
[04:51:23][Step 5/5] <dict>
[04:51:23][Step 5/5] 	<key>notarization-upload</key>
[04:51:23][Step 5/5] 	<dict>
[04:51:23][Step 5/5] 		<key>RequestUUID</key>
[04:51:23][Step 5/5] 		<string>fd45e30c-5a96-4d02-9196-0923d4e5e90f</string>
[04:51:23][Step 5/5] 	</dict>
[04:51:23][Step 5/5] 	<key>os-version</key>
[04:51:23][Step 5/5] 	<string>10.15.3</string>
[04:51:23][Step 5/5] 	<key>success-message</key>
[04:51:23][Step 5/5] 	<string>No errors uploading '/Users/mcdurdin/buildAgent/work/99b311828f4ee7c/keyman/mac/Keyman4MacIM/build/Release/Keyman.zip'.</string>
[04:51:23][Step 5/5] 	<key>tool-path</key>
[04:51:23][Step 5/5] 	<string>/Applications/Xcode.app/Contents/SharedFrameworks/ContentDeliveryServices.framework/Versions/A/Frameworks/AppStoreService.framework</string>
[04:51:23][Step 5/5] 	<key>tool-version</key>
[04:51:23][Step 5/5] 	<string>4.01.1182</string>
[04:51:23][Step 5/5] </dict>
[04:51:23][Step 5/5] </plist>
[04:51:23][Step 5/5]
[04:51:23][Step 5/5] Waiting 30 seconds for status
[04:51:55][Step 5/5] <?xml version="1.0" encoding="UTF-8"?>
[04:51:55][Step 5/5] <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
[04:51:55][Step 5/5] <plist version="1.0">
[04:51:55][Step 5/5] <dict>
[04:51:55][Step 5/5] 	<key>os-version</key>
[04:51:55][Step 5/5] 	<string>10.15.3</string>
[04:51:55][Step 5/5] 	<key>product-errors</key>
[04:51:55][Step 5/5] 	<array>
[04:51:55][Step 5/5] 		<dict>
[04:51:55][Step 5/5] 			<key>code</key>
[04:51:55][Step 5/5] 			<integer>1519</integer>
[04:51:55][Step 5/5] 			<key>message</key>
[04:51:55][Step 5/5] 			<string>Could not find the RequestUUID.</string>
[04:51:55][Step 5/5] 			<key>userInfo</key>
[04:51:55][Step 5/5] 			<dict>
[04:51:55][Step 5/5] 				<key>NSLocalizedDescription</key>
[04:51:55][Step 5/5] 				<string>Could not find the RequestUUID.</string>
[04:51:55][Step 5/5] 				<key>NSLocalizedFailureReason</key>
[04:51:55][Step 5/5] 				<string>Apple Services operation failed.</string>
[04:51:55][Step 5/5] 				<key>NSLocalizedRecoverySuggestion</key>
[04:51:55][Step 5/5] 				<string>Could not find the RequestUUID.</string>
[04:51:55][Step 5/5] 			</dict>
[04:51:55][Step 5/5] 		</dict>
[04:51:55][Step 5/5] 	</array>
[04:51:55][Step 5/5] 	<key>tool-path</key>
[04:51:55][Step 5/5] 	<string>/Applications/Xcode.app/Contents/SharedFrameworks/ContentDeliveryServices.framework/Versions/A/Frameworks/AppStoreService.framework</string>
[04:51:55][Step 5/5] 	<key>tool-version</key>
[04:51:55][Step 5/5] 	<string>4.01.1182</string>
[04:51:55][Step 5/5] </dict>
[04:51:55][Step 5/5] </plist>
[04:51:55][Step 5/5]
[04:51:55][Step 5/5] altool failed with code 1
```
2020-11-26 11:53:35 +11:00
Marc Durdin
b4f08b3604 chore: fix parameters 2020-11-24 08:10:50 +11:00
Marc Durdin
f692af2545 chore: fix test 2020-11-24 08:08:33 +11:00
Marc Durdin
e41df6f838 fix(mac): re-sign files post plist update
Cleans up a bunch of bits and pieces around the build process and makes
sure that files are re-signed after we update the Info.plist file.
2020-11-24 08:02:16 +11:00
Marc Durdin
c2401514cb fix(mac): support page and copyright
Fixes #3849.

* Uses keyman-staging.com when on alpha or beta
* Updates copyright year at build time
* Fixes link to help documentation (/mac, not /macosx)
2020-11-20 05:55:53 +11:00
Marc Durdin
590f7782cc chore: fix command order 2020-11-19 10:32:07 +11:00
Marc Durdin
da8dbc59fb fix(mac): codesign resilience
This PR tries to make codesign more resilient to failure, by retrying
a build step that falls over with code 65. This code is not limited to
codesign but most frequently happens with it.

A more complete answer would be to do the codesigning step in build.sh
instead of in the project, which would give us more control of the
outcome, and maybe simplify the build process somewhat, but I will
leave that for now, because it is usually better to leave that to XCode.
2020-11-19 10:24:36 +11:00
Marc Durdin
be8738e9b4 chore(mac): rewrite plists after build
Instead of updating the source plist files with version information,
do this on the built artifacts so that the source files do not get
continually clobbered.
2020-11-19 09:38:32 +11:00
Marc Durdin
bede3948d2 feat(mac): Sentry support
I wasn't going to do this, but realised that crash reporting was going
to be a problem on mac because it still used crashlytics/fabric. Turned
out to be a good exercise to get me back into macOS world, and fairly
straightforward to get right (helps that the other platforms broke the
ice for me).
2020-11-18 17:13:20 +11:00
Marc Durdin
066e9aa8a8 fix(mac): altool second call report ci errors 2020-06-22 11:32:15 +10:00
Marc Durdin
7c46e02907 fix(mac/resources): altool is failing but we lose the log in CI 2020-06-22 08:30:52 +10:00
Marc Durdin
15231a0bac fix(mac): invalid build script params removed
I accidentally pulled old parameters into mac/build.sh for the
make-km-dmg.sh script when merging from beta. The script no longer
requires `-version`. This fixes that.
2020-02-17 14:58:45 +11:00
Marc Durdin
255e4f4b7a chore: Merge branch 'master' into chore/beta-to-master-p9s2-1 2020-02-17 10:11:15 +11:00
Marc Durdin
4281b72b26 chore(mac): Merge branch 'beta' into fix/mac/install-fails-with-quarantine 2020-02-14 11:26:43 +11:00
Marc Durdin
f856785742 fix(mac): Modifier keys were resetting cached context
Fixes #2375.

For applications that do not provide context to Keyman, Keyman was losing
the context buffer whenever a modifier key was pressed or released. This
change modifies the cache reset to occur only when the Command modifier is
pressed.
2020-02-05 19:32:03 +11:00
Marc Durdin
d6dbe602c2 fix(mac): dmg background and script tweaks 2020-02-05 16:31:27 +11:00
Marc Durdin
7f9bf19a91 chore(mac): fix version references in dmg build 2020-01-29 12:50:51 +11:00
Marc Durdin
855a80258b chore(ios): use new version infrastructure 2020-01-29 11:53:50 +11:00
Marc Durdin
ccfef64c99 chore(mac): use new version infrastructure 2020-01-29 11:15:36 +11:00
Marc Durdin
f8ea457325 feat(mac): install script
First steps towards a clean install script
for Keyman for Mac. Some steps still out-
of-order for now, particularly opening
System Preferences to allow Keyman before
Keyman has run for first time.
2020-01-29 10:12:26 +11:00
Marc Durdin
d9e8e546dc chore(mac): update build notes 2019-12-04 10:21:55 +01:00
Marc Durdin
0900aa99bf [mac] Clarify deployment build instructions 2019-08-16 15:31:15 +10:00
Marc Durdin
cba0a879ae Updated build script 2019-08-02 10:10:31 +10:00
Marc Durdin
c3376eba18 [Mac] Add notarization for 10.14.5 and later versions 2019-07-24 20:57:46 +10:00
Marc Durdin
2da606ec4b
Merge pull request #1343 from keymanapp/mac-update-podfile
[mac] Update podfile.lock for latest XCode / macOS version support
2018-12-07 14:12:10 +11:00
Marc Durdin
11a870c443 [mac] Address review comments 2018-12-07 12:06:13 +11:00
Marc Durdin
f6fc0b0274 [mac] Use pod update instead of pod install 2018-12-07 11:29:43 +11:00
Marc Durdin
690bdbf7aa [mac] Workaround hang in upload-symbols when called from xcodebuild. 2018-12-07 11:22:29 +11:00
Randy Boring
9ce945aab1 use standard shell helper functions instead of a copy of a few of them 2018-12-05 09:45:20 -06:00
Marc Durdin
a2d954fb78
Merge branch 'master' into beta-P3S5-merge-to-alpha 2018-06-14 10:39:03 +07:00
Tom Bogle
4f0010a941 [Mac] Added switches to control Keyman4MacIM build destination 2018-06-05 14:34:48 -04:00
Tom Bogle
c26f44f5dc [Mac] Added pod install command to build and updated supporting files. 2018-06-04 10:29:17 -04:00
Tom Bogle
191d72a6ef [Mac] #769 - Switched to using Cocoapods to get Crashlytics framework
This also gets the upload-symbols script, which seems to be necessary to upload the dSYM file for the Keyman Engine.
2018-06-01 16:00:22 -04:00
Marc Durdin
5a734c4ebd
Merge branch 'master' into beta-p3s4-merge-to-master 2018-05-31 10:44:11 +07:00
Tom Bogle
6f7cb912ef [Mac] [WIP] #769 - Adding dSYM files for KM engine to support Crashlytics 2018-05-18 12:30:58 -04:00
Marc Durdin
27bb92aec8
Merge branch 'master' into beta-p3s3-merge-to-master 2018-05-18 13:10:32 +07:00
Tom Bogle
7294d697b9 Fixed syntax error in build script 2018-05-15 16:04:23 -04:00
Tom Bogle
222089485e Call carthage unconditionally; update Fabric key only for Keyman4MacIM 2018-05-15 15:48:35 -04:00
Tom Bogle
1ae52efc2b Added missing fi to close if in build script 2018-05-10 22:14:29 -04:00
Tom Bogle
632088bbad Got Fabric and Crashlytics via Carthage and segmented crash anylytics
Added code to build script and custom shell script in project to use hardcoded APIKey for debug builds but allow the release APIKey to be kept secret (supplied via environment variable during build).
2018-05-10 16:56:41 -04:00
Marc Durdin
c13d8a57af Move version.md to resources/ so that we can reference it more safely. 2018-03-22 15:39:08 +07:00
Marc Durdin
678cbe371b Update to version 11.0 for build-impacting version numbers (and reduce hard-coded references where possible) 2018-03-22 14:55:30 +07:00
Tom Bogle
9e9a08e6cd Run IM tests as separate step to avoid interfering with local deploy
For some seemingly inexplicable reason, if the scheme is not specified, xcodebuild magically builds the app and puts it in the Debug or Release subfolder of the build folder. However, if the scheme is specified explicitly, then the app is built only in the DerivedData folder and not automatically copied to the build folder. Since the local deploy process expects to find it there, it fails. So I'm adding a subsequent step to run the tests. As an added bonus, I also suppress the IM tests for a release build since they fail to build.
2018-02-13 01:36:00 -05:00
Tom Bogle
016f0dc7f6 Re-added $BUILD_ACTIONS - maybe not needed 2018-02-12 23:15:04 -05:00
Tom Bogle
bcc527f696 Fixed up all the plumbing issues with unit tests for Keyman4MacIM 2018-02-02 13:35:42 -05:00
Tom Bogle
141c10cd47 Temporary addition of "which carthage" 2018-01-31 12:36:56 -05:00
Tom Bogle
3522e876c4 Only do carthage update (to get OCMocks) is -test is specified 2018-01-31 12:32:12 -05:00