Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

change languagedepot.org url to lexbox.org #342

Open
hahn-kev opened this issue Jun 11, 2024 · 2 comments
Open

change languagedepot.org url to lexbox.org #342

hahn-kev opened this issue Jun 11, 2024 · 2 comments
Assignees

Comments

@hahn-kev
Copy link
Contributor

hahn-kev commented Jun 11, 2024

this will change the domain used in the dialog, but we also want to change any pre existing projects. This will require hooking this ini check code

internal void CheckAndUpdateHgrc()
{
CheckMercurialIni();
if (!_hgrcUpdateNeeded)
return;
try
{
lock(_pathToRepository) // Avoid crash if two threads try to Sync simultaneously
{
EnsureChorusMergeAddedToHgrc();
EnsureCacertsIsSet();
var extensions = HgExtensions;
EnsureTheseExtensionsAndFormatSet(extensions);
_hgrcUpdateNeeded = false;
}
}
catch (Exception error)
{
throw new ApplicationException($"Failed to set up extensions for the repository: {error.Message}", error);
}
}

if the domain is Ld then change it to lexbox. Be careful to make sure it's not changing the domain in other cases.


I'd also like to try and change how the protocol logic works so we can drop all the domains except lexbox. This will require changing

public static bool IsKnownResumableRepository(string uri)
{
// REVIEW (Hasso) 2021.01: this seems to apply only to HTTP repositories, and is now stored in a separate property of
// ServerSettingsModel.cs. Perhaps we should move IsResumable to HttpRepositoryAddress and this logic to determine
// resumability to ServerSettingsModel.
return uri.ToLower().Contains("resumable");
}

and any code that calls it to use a stored value of what protocol to use for a project (or it might be global?).


For HG It will also require changing the assumption that the url is https:://{host}/{projectId} to https:://{host}/hg/{projectId} (project id being the chorus term, lexbox calls it project code)

ProjectId = WebUtility.UrlDecode(UrlHelper.GetPathAfterHost(url));

and
return $"https://{Host}/{WebUtility.UrlEncode(ProjectId)}";

though there may be other places.

@josephmyers
Copy link
Collaborator

Am I supposed to be assigned to this?

@hahn-kev
Copy link
Contributor Author

I probably should have just mentioned you, but I wanted you to be aware if you had the time to spend on it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants