Tuesday, May 19, 2020

Create a patch for LibreOffice directly in gerrit

Possibly, you are a great C++ developer or conversely you write your first strings in C++ and you want make LibreOffice better with pair (or more!) string of code.
Note, the same way uses for Help changes.
We'll suppose you already know what strings and in which file(s) of the LibreOffice source code you age going to change.
I'll talk here about using gerrit for that change making. 
So open your browser and type in address bar - gerrit.libreoffice.org. Click on SIGN IN in top right corner of the site. You'll see something like this:
For gerrit using you must have a TDF account, so just create it by that orange button ;-) Then login in to the site.
For making your change select Browse->Repositories on top of the site:

Then in the Filter field type one word "core" and click on link "core" in row below (if you want change Help, then type "help" instead "core" and click to "help"):
In left side of the site press Commands and then press CREATE CHANGE button by center of screen:
In opened window type in to Select branch for new change field word master and select "master" from drop-down list. Type something like tdf#bug_number <description> into Description area. Please use short description here, about only 75 characters on the first line; if you need a longer description, then add one empty line, and then add as many 75-character lines as you want. Press CREATE button.
Screen updates. Press EDIT in right top corner of the site:
There is a row with commands in right side of the site:
Press OPEN. In a new window type a name for file where you want make your change:
Please use a tooltip for selecting a full path to file! Click OPEN. It opens a source code editor:
Make your changes in the source code and click SAVE in right top site corner. Please wait, it shows a message like "All changes saved" in left bottom corner, then click CLOSE in right top site corner. You'll back to main site where you'll can see the changed file with your change. 
If your changes are in more than one file then just repeat operations from OPEN command as you need.
So, you made all your changes. Now you need someone who will review your patch. 
If you have a friend from LibreOffice developers (as me;-), then you can add it to reviewers directly. Click ADD REVIEWER in left side of the site and in first row of new window type his nickname or e-mail to add him in opening window. Then press START REVIEW there.
If you know nobody from LibreOffice developers then you can ask them to review your patch on #libreoffice-dev IRC channel in Freenode.net.
In that case click START REVIEW in main window and finally click PUBLISH EDIT in top right corner of the site.
Now you should just wait. You'll get one message from jenkins test bot and if it will be +1, then someone from developers should review the patch and set +2 and then will merge it to LibreOffice source code.

No comments:

Post a Comment

All comments will be preliminary check