On 2026-05-10 14:08, Julien Nabet wrote:
I tried cherry-picked another commit but the fact that Collabora has "online" and "core" made me change my process.Here's what I'm doing for the moment, eg with https:// gerrit.collaboraoffice.com/c/online/+/2166Prerequisite : clone collabora repo and update it On local repo Collabora: 1) git ls-remote origin | grep 2166 => d30e4c110d534c2166c46ebdafae733f1c16a0a8 refs/changes/02/1902/1 801290a91a52d77e852375583a83eca89f3a9cb0 refs/changes/66/2166/1 5e6d001d766c86a54ef4a3620bf2a0134a2bfec2 refs/changes/66/2166/2 95ca53d8515f615d356c24814b027772ff0be986 refs/changes/66/2166/meta 6ab8f0ade13a9c22202322616a52f3dd09242166 refs/changes/80/1980/meta 2) retrieve the last change so here: git fetch origin refs/changes/66/2166/2 3) generate the patch from the head git format-patch -1 FETCH_HEAD --stdout > /tmp/2166.patch4) since the patch may contain "engine" before each module (sw, sc, etc.), a script to remove themsed 's#engine/##' /tmp/2166.patch > /tmp/2166-lo.patch On local LO repo 5) Apply the patch git am --3way /tmp/2166-lo.patch Notice that it may fail at this moment and one's must fix conflicts 6) add some commit reference (cherry-picked from commit I5463e2b89a71c46096ef3f9806fc33f0e523e5e7) So it's quite tedious, I hope there's a simpler way
git should be able to handle cherry-picks automatically regardless of the move to the "engine" subdirectory in the Collabora repo. I just tried with a "random" commit from their main branch and that worked as expected.
Sample steps: 1) add the Collabora repo as a remote to the existing LO core one:git remote add collabora ssh://<YOUR_USER_NAME>@gerrit.collaboraoffice.com:29418/online
(or use an https URL that doesn't require authentication)
2) `git remote update`
3) find the commit you're interested in: `git log collabora/main`
4) cherry-pick to the local branch:
git cherry-pick -x 64dd38c12dbea925478b9cb7349b6845104dc92e
Of course, if the files within the repo diverge, any merge conflicts
will still have to be handled manually.
OpenPGP_signature.asc
Description: OpenPGP digital signature
