Help Center> CodeArts Repo> Best Practices> Git on CodeArts Repo> CodeArts Repo Cloud Operations
Updated on 2023-05-06 GMT+08:00

CodeArts Repo Cloud Operations

Preparations

  • You have registered an account for CodeArts Repo.
  • You already have a Git client.
  • A project has been created.

Cloud Repositories

CodeArts Repo allows you to create, clone, and manage cloud repositories. You can manage branches, tags, repository members, and keys, and perform operations on code, including committing, pulling, pushing, viewing, and online editing. For more details about cloud repositories, see Service Overview.

Creating an Empty Repository

  1. On the CodeArts Repo homepage, click New Repository.

  1. Enter the basic repository information, as shown in the following figure.

  1. Click OK to create the repository. The repository list page is displayed.

Setting the SSH Keys or HTTPS Password

SSH keys and HTTPS password are credentials for communication between a client and server. Set them first before you clone or push a repository on your computer.

Setting SSH Keys

SSH keys are used when a client communicates with CodeArts Repo over the SSH protocol. If you have downloaded Git Bash for Windows and generated an SSH key pair in the process, skip this section.

  1. Open the Git client (Git Bash or Linux CLI), enter the following command, and press Enter for three times.

    ssh-keygen -t rsa -C "<email address>"

    The generated SSH key pair is stored in ~/.ssh/id_rsa and ~/.ssh/id_rsa.pub by default.

  2. Add the SSH key to CodeArts Repo.

    Open the Git client (Git Bash or Linux CLI) and run the following command to print the SSH key in ~/.ssh/id_rsa.pub.

  3. Copy the preceding SSH key content, log in to your CodeArts Repo repository list page, click the nickname in the upper right corner, and choose This Account Settings > SSH Keys.

  4. On the SSK Keys page, click Add SSH Key. In the displayed Add SSH Key page, enter the information shown in the following figure and click OK. A message is displayed, indicating that the operation is successful.

    The SSH key has been added. You can proceed to set an HTTPS password.

Setting an HTTPS Password

An HTTPS password is used when a client communicates with CodeArts Repo over HTTPS. To set an HTTPS password, perform the following steps:

  1. Log in to the CodeArts Repo service repository list page, click the alias in the upper right corner, and choose This Account Settings > HTTP Password.

  2. Click Set new password, and then click Change to change the password. (If you have set an HTTPS password and are using it, click Change.)

  3. Enter the new password and email verification code, select I have read and agree to the Privacy Statement and CodeArts Service Statement, and click OK. A message is displayed, indicating that the operation is successful.