Step: 1 Goto https://wikitech.wikimedia.org And Click on "Create Account". Now Fill ther Form. One thing You will Ask What is Instance shell account name? So Instance shell account name is required for assign you a unique name in Gerrit repo. You will understand it later. In other Word Instance shell account name is your Gerrit Username.
Step: 3 Goto https://gerrit.wikimedia.org And CLick on Sign In at upper corner. And Sign In by Username And password, Which you make on wikitech.
Install Git and Git-review
Step-3:-After the Installation of Git. You need to Configure Git. #First, Configure Your Email By
git config --global user.email "firstname.lastname@example.org"#Second, Configure Your Username by
git config --global user.name "example". And Finally Type
git config -lAnd press Enter Key to confirm the things were done Succesfully.
Step-5:- To generate a new SSH key. Type
ssh-keygen -t rsa -C "email@example.com"And Hit the Enter. After that, We want the default settings so when asked to enter a file in which to save the key, just press enter. Then Terminal will demand "passphrases". passphrases are just like a password. It will use when You clone the Repo. So type memorable passphrase and press enter. Now Key will Successfully Generate.
Step-6:- Now, Open the https://gerrit.wikimedia.org and get the login by your Wikitech Account. Now you can see Your Name at Uppar-Right Corner. Click on that and then Setting.
Step-7:- Click on SSH Public Keys, Now the Time is to upload Your SSH key in Gerrit. For this Propose you need to go to Terminal and type
cat ~/.ssh/id_rsa.puband press the Enter. Now you can see your lengthy SSH key in your Terminal. Copy the text ssh-rsa............firstname.lastname@example.org and Paste Into Gerrit SSH Public Keys. And then Click on Add. Now your key has added into Gerrit.
Step-8:- Now type the
eval `ssh-agent`and press the Enter. then type
ssh-add .ssh/id_rsaand press the Enter. Now We are at this stage where We can make Connection to gerrit.wikimedia.org. For this Purpose, You need to type
ssh -p 29418 <USERNAME>@gerrit.wikimedia.orgHere <USERNAME> means your Shell Name. The Massege Are you sure you want to continue connecting (yes/no)? will Come, type yes and Press the Enter. Now you have successfully connected over SSH.
Step-8:- Now to need to Install and Setup git-review for Uploading the Patch. Just go to terminal and Type
sudo apt-get install git-reviewand press the Enter. Now your pc will demand the password. Enter the Operating System Password. And Hit the Enter. As you can see New message will come "Do you want to continue? [Y/n]". Pres "y" and Hit the Enter Key. The Process of installing will start.
In this session, We Will learn How to upload the Patch Via Git.
Step 1 Clone the repo from Gerrit. You will find the relevant projects at https://gerrit.wikimedia.org/r/#/admin/projects/. Just find the project by typing and copy git clone command from there. Make sure you are log in.
You ca use https://gerrit.wikimedia.org/r/#/admin/projects/sandbox project for testing pupose.
Via Publish Edit
In this session, We Will learn How to upload the Patch Via Gerrit UI.