Unreal Engine source code git clone method

Today I want to download the source code of Unreal Engine to study and study. I thought it would be as simple as git clone before, but the Unreal Engine organization has done a lot of security things, and it is not so easy to download.

Most people don't see the UnrealEngine project on the homepage of Epic's github official website for the first time. Why? 

Epic has made this account binding. Only when your Epic account is bound to your github account can you view the UnrealEngine code normally.

account binding

Next, we will link the Github account to the Epic Games account step by step

1. Open Github and log in to Github.

2. If you do not have an Epic Game account, please use your email to register one, and open the Epic Game account page to modify account information: https://www.unrealengine.com/dashboard/settings

3. Then click the link button under Account-Github

Click Link Account in the link account that pops up next

3. Next, go back to your own github, and you will receive an invitation from Epic Games. After clicking View Invitation, click Join Epic Games on the next page.

4. Back to Epic Game's warehouse page, we can see the source code warehouse of Unrea Engine. https://github.com/EpicGames

Get github personal token

When I downloaded the code with the hopeful git clone https://github.com/EpicGames/UnrealEngine.git, after entering the user name and password, the code still could not be downloaded.

why? It turns out that from August 31, 2021, the code will no longer be downloaded by accepting the account password.

Epic's statement:

In July 2020, we announced our intention to require token-based authentication (for example, personal access, OAuth, or GitHub App install tokens) for all authenticated Git operations. Starting August 13, 2021, we will no longer accept account passwords when authenticating Git operations on GitHub.com.

Starting August 13, 2021, we will no longer accept account passwords when authenticating Git operations, and will require the use of token-based authentication. Such as Personal Access Tokens (for developers) or OAuth or GitHub App Install Tokens (for Integrators) for all authenticated Git operations on GitHub.com. You can also keep using SSH keys wherever you like.

Since I am in the company intranet and cannot use ssh directly, I can only try to use a personal access token.

1. Open Settings

 

2. Pull to the bottom and click Developer settings

3. Select Personal access tokens and create a personal token 

 4. When creating a token, be careful to uncheck repo.

Clone code

Before git clone code, be sure to install git lfs first, lfs needs to download some large files.

Please replace {token} with the token you created in the previous step, so that you can git clone the code.

git clone https://{token}@github.com/EpicGames/UnrealEngine.git

Guess you like

Origin blog.csdn.net/grace_yi/article/details/124690766