Skip to main content
Build the future with Agentforce at TDX in San Francisco or on Salesforce+ on March 5–6. Register now.

Set Up the Project on Your Local Machine

Follow Along with Trail Together

Want to follow along with an expert as you work through this step? Take a look at this video, part of the Trail Together series.

(This clip starts at the 4:47 minute mark, in case you want to rewind and watch the beginning of the step again.)

Introduction

Our next goal is to set up the developer project that we use to modify our application. We start by cloning the repository.

Download a Project from GitHub

If you're a Windows user, first install git for Windows tooling. This tool helps you run git from the command line.

  1. Open a new Terminal (Mac) or Command Prompt (Windows) window and use the following command to create a unique directory to do your work in:
    mkdir my_sf_project
    cd my_sf_project
  2. Next, use this command to clone the app repository:
    git clone https://github.com/trailheadapps/dreamhouse-lwc.git
  3. Next, open the directory:
    cd dreamhouse-lwc
    Cloning dreamhouse-lwc project from GitHub

Cloning the repository pulls all the source code into your local file system. But before you start editing, you first create your own branch. This is a best practice as defined by GitHub Flow, because it helps ensure your main branch is a clean and production-ready version of your code.

Create a Branch for Your Project

  1. In your command window, create a new branch to do your work in:
    git checkout -b my_branch
    Now that you're working in your own branch, it's easy to submit updates to your team later on.
  2. In Salesforce DX, we provide a comprehensive set of capabilities through our command-line interface. In the command terminal window, see the available commands by running:
    sf --help

Now that we've set up our project, our next step is to create our scratch org.

We won't check any of your setup. Click Verify Step to go to the next step in the project.

Salesforce 도움말에서 Trailhead 피드백을 공유하세요.

Trailhead에 관한 여러분의 의견에 귀 기울이겠습니다. 이제 Salesforce 도움말 사이트에서 언제든지 새로운 피드백 양식을 작성할 수 있습니다.

자세히 알아보기 의견 공유하기