From f836574cbc714084eaa5c8b72ec1337df1b1ad4b Mon Sep 17 00:00:00 2001 From: Marc Durdin Date: Thu, 8 Sep 2022 14:32:39 +1000 Subject: [PATCH] chore: use keyman.com instead of keyman-staging.com Fixes #7227. We want to use keyman.com for now even for alpha builds, as keyman-staging.com is going to be used for transition to Docker-based hosting, and it will be problematic to try and share that process with alpha builds. --- .../tavultesoft/kmea/data/CloudRepository.java | 2 +- .../com/tavultesoft/kmea/util/KMPLink.java | 2 +- .../windows/delphi/general/Upload_Settings.pas | 4 ++-- .../KeymanEngine/Classes/KeymanHosts.swift | 6 +++--- linux/keyman-config/keyman_config/__init__.py | 12 ++++++------ .../Keyman4MacIM/KMInputMethodAppDelegate.m | 18 +++++++++--------- 6 files changed, 22 insertions(+), 22 deletions(-) diff --git a/android/KMEA/app/src/main/java/com/tavultesoft/kmea/data/CloudRepository.java b/android/KMEA/app/src/main/java/com/tavultesoft/kmea/data/CloudRepository.java index 1baba069ed..a7f5974718 100644 --- a/android/KMEA/app/src/main/java/com/tavultesoft/kmea/data/CloudRepository.java +++ b/android/KMEA/app/src/main/java/com/tavultesoft/kmea/data/CloudRepository.java @@ -39,7 +39,7 @@ public class CloudRepository { public static final String DOWNLOAD_IDENTIFIER_CATALOGUE = "catalogue"; public static final String API_PRODUCTION_HOST = "api.keyman.com"; - public static final String API_STAGING_HOST = "api.keyman-staging.com"; + public static final String API_STAGING_HOST = "api.keyman.com"; // #7227 disabling: "api.keyman-staging.com"; public static final String API_MODEL_LANGUAGE_FORMATSTR = "https://%s/model?q=bcp47:%s"; public static final String API_PACKAGE_VERSION_FORMATSTR = "https://%s/package-version?platform=android%s%s"; diff --git a/android/KMEA/app/src/main/java/com/tavultesoft/kmea/util/KMPLink.java b/android/KMEA/app/src/main/java/com/tavultesoft/kmea/util/KMPLink.java index ff234e85c7..19ad4aaa72 100644 --- a/android/KMEA/app/src/main/java/com/tavultesoft/kmea/util/KMPLink.java +++ b/android/KMEA/app/src/main/java/com/tavultesoft/kmea/util/KMPLink.java @@ -21,7 +21,7 @@ import java.util.regex.Pattern; public final class KMPLink { public static final String KMP_PRODUCTION_HOST = "keyman.com"; - public static final String KMP_STAGING_HOST = "keyman-staging.com"; + public static final String KMP_STAGING_HOST = "keyman.com"; // #7227 disabling: "keyman-staging.com"; private static final String KMP_INSTALL_KEYBOARDS_PATTERN_FORMATSTR = "^http(s)?://(%s|%s)/keyboards/install/([^\\?/]+)(\\?(.+))?$"; private static final String installPatternFormatStr = KMString.format(KMP_INSTALL_KEYBOARDS_PATTERN_FORMATSTR, diff --git a/common/windows/delphi/general/Upload_Settings.pas b/common/windows/delphi/general/Upload_Settings.pas index 41355e9c0f..f38cc07890 100644 --- a/common/windows/delphi/general/Upload_Settings.pas +++ b/common/windows/delphi/general/Upload_Settings.pas @@ -108,8 +108,8 @@ const // Alpha versions will work against the staging server so that they // can access new APIs etc that will only be available there. The staging // servers have resource constraints but should be okay for limited use. - S_KeymanCom_Staging = 'https://keyman-staging.com'; - S_APIServer_Staging = 'api.keyman-staging.com'; + S_KeymanCom_Staging = 'https://keyman.com'; // #7227 disabling: 'https://keyman-staging.com'; + S_APIServer_Staging = 'api.keyman.com'; // #7227 disabling: 'api.keyman-staging.com'; const URLPath_PackageDownload_Format = '/go/package/download/%0:s?platform=windows&tier=%1:s&bcp47=%2:s&update=%3:d'; diff --git a/ios/engine/KMEI/KeymanEngine/Classes/KeymanHosts.swift b/ios/engine/KMEI/KeymanEngine/Classes/KeymanHosts.swift index cf312a8e0d..897b162a5e 100644 --- a/ios/engine/KMEI/KeymanEngine/Classes/KeymanHosts.swift +++ b/ios/engine/KMEI/KeymanEngine/Classes/KeymanHosts.swift @@ -30,7 +30,7 @@ public enum KeymanHosts { case .alpha: fallthrough case .beta: - return URL.init(string: "https://api.keyman-staging.com")! + return URL.init(string: "https://api.keyman.com")! // #7227 disabling: "https://api.keyman-staging.com")! case .stable: return URL.init(string: "https://api.keyman.com")! } @@ -54,7 +54,7 @@ public enum KeymanHosts { case .alpha: fallthrough case .beta: - return URL.init(string: "https://help.keyman-staging.com")! + return URL.init(string: "https://help.keyman.com")! // #7227 disabling: "https://help.keyman-staging.com")! case .stable: return URL.init(string: "https://help.keyman.com")! } @@ -78,7 +78,7 @@ public enum KeymanHosts { case .alpha: fallthrough case .beta: - return URL.init(string: "https://keyman-staging.com")! + return URL.init(string: "https://keyman.com")! // #7227 disabling: "https://keyman-staging.com")! case .stable: return URL.init(string: "https://keyman.com")! } diff --git a/linux/keyman-config/keyman_config/__init__.py b/linux/keyman-config/keyman_config/__init__.py index 7c3972c247..ee2326a86f 100644 --- a/linux/keyman-config/keyman_config/__init__.py +++ b/linux/keyman-config/keyman_config/__init__.py @@ -40,15 +40,15 @@ def secure_lookup(data, key1, key2 = None): gettext.bindtextdomain('keyman-config', '/usr/share/locale') gettext.textdomain('keyman-config') -if __tier__ == 'alpha' or __tier__ == 'beta': +#if __tier__ == 'alpha' or __tier__ == 'beta': // #7227 disabling: # Alpha and beta versions will work against the staging server so that they # can access new APIs etc that will only be available there. The staging # servers have resource constraints but should be okay for limited use. - KeymanComUrl = 'https://keyman-staging.com' - KeymanApiUrl = 'https://api.keyman-staging.com' -else: - KeymanComUrl = 'https://keyman.com' - KeymanApiUrl = 'https://api.keyman.com' +# KeymanComUrl = 'https://keyman-staging.com' +# KeymanApiUrl = 'https://api.keyman-staging.com' +#else: +KeymanComUrl = 'https://keyman.com' +KeymanApiUrl = 'https://api.keyman.com' # There's no staging site for downloads KeymanDownloadsUrl = 'https://downloads.keyman.com' diff --git a/mac/Keyman4MacIM/Keyman4MacIM/KMInputMethodAppDelegate.m b/mac/Keyman4MacIM/Keyman4MacIM/KMInputMethodAppDelegate.m index 61558b7ecf..8a4cc0734b 100644 --- a/mac/Keyman4MacIM/Keyman4MacIM/KMInputMethodAppDelegate.m +++ b/mac/Keyman4MacIM/Keyman4MacIM/KMInputMethodAppDelegate.m @@ -130,16 +130,16 @@ NSString* _keymanDataPath = nil; result.tier = [keymanInfo objectForKey:@"Tier"]; result.versionRelease = [keymanInfo objectForKey:@"VersionRelease"]; result.versionWithTag = [keymanInfo objectForKey:@"VersionWithTag"]; - if([result.tier isEqualToString:@"stable"]) { - result.keymanCom = @"keyman.com"; - result.helpKeymanCom = @"help.keyman.com"; - result.apiKeymanCom = @"api.keyman.com"; - } + // if([result.tier isEqualToString:@"stable"]) { // #7227 disabling: + result.keymanCom = @"keyman.com"; + result.helpKeymanCom = @"help.keyman.com"; + result.apiKeymanCom = @"api.keyman.com"; + /*} else { result.keymanCom = @"keyman-staging.com"; result.helpKeymanCom = @"help.keyman-staging.com"; result.apiKeymanCom = @"api.keyman-staging.com"; - } + }*/ return result; } @@ -632,11 +632,11 @@ CGEventRef eventTapFunction(CGEventTapProxy proxy, CGEventType type, CGEventRef NSString *path = [[self keymanDataPath] stringByAppendingPathComponent:packageFolder]; KMPackageInfo *packageInfo = [self.packageReader loadPackageInfo:path]; - + if (packageInfo) { packageName = packageInfo.packageName; } - + return packageName; } @@ -1149,7 +1149,7 @@ CGEventRef eventTapFunction(CGEventTapProxy proxy, CGEventType type, CGEventRef [self.receivedData writeToFile:filePath atomically:YES]; [self unzipFile:filePath]; [[NSFileManager defaultManager] removeItemAtPath:filePath error:nil]; - + [_downloadInfoView setMessageText:NSLocalizedString(@"message-keyboard-download-complete", nil)]; NSButton *button = (NSButton *)[_downloadInfoView.buttons objectAtIndex:0]; [button setTitle:NSLocalizedString(@"button-download-complete", nil)];