Elastic Path Commerce Development

Preparing Elastic Path Source Code

Preparing Elastic Path Source Code

Ensure that you have the following:

This section provides instructions to prepare Elastic Path source code for your project to use.

  1. Prepare the source code.
    1. Navigate to https://code.elasticpath.com/ep-commerce/ep-commerce.
    2. Clone the repository.
      Note: When you clone an Elastic Path Commerce repository for the first time, follow the instructions in the Cloning via HTTPS guide.
      Warning: Windows File Path Limitation - Do not clone to a directory with a file path greater than 20 characters. Windows file paths are limited to 260 characters. The longest file path in the source code is greater than 230 characters.
      Tip:

      Configure Git to convert line ending to LF on input.

      The command to configure this is:
      git config --global core.autocrlf input
    3. Check out the correct branch and release version of Elastic Path Commerce.
      Tip: Each version branch contains the source code for the release and the subsequent patches. Enable Watch for the repository to get notification of any updates.
    4. Create a development branch in your local repository. The branch name depends on the SCM and branch naming conventions.
    5. Add the Elastic Path Commerce repository to your Git hosting service.
    6. Push the development branch to the Git hosting service.
  2. Configure the Maven extensions/maven/settings.xml file.
    Note: The extensions module contains a maven/individual-settings.xml that you will use.
    1. Change EP_REPOSITORY_USER and EP_REPOSITORY_PASSWORD to the credentials used for connecting to the public Elastic Path Maven repository.
      <servers>
              <server>
                  <id>ep-public</id>
                  <username>EP_REPOSITORY_USER</username>
                  <password>EP_REPOSITORY_PASSWORD</password>
              </server>
              <server>
                  <id>ep-cortex</id>
                  <username>EP_REPOSITORY_USER</username>
                  <password>EP_REPOSITORY_PASSWORD</password>
              </server>
              <server>
                  <id>ep-commerce-engine</id>
                  <username>EP_REPOSITORY_USER</username>
                  <password>EP_REPOSITORY_PASSWORD</password>
              </server>
              <server>
                  <id>ep-accelerators</id>
                  <username>EP_REPOSITORY_USER</username>
                  <password>EP_REPOSITORY_PASSWORD</password>
              </server>
          </servers>
    2. Make any changes required for your project environment.
    3. Push the changes to source control.
    4. Rename individual-settings.xml to settings.xml. Copy the file to the ${user.home}/.m2 directory.
  3. Set up a local developer environment.
    Follow the instructions at Setting up your Developer Environment to configure, build, and run Elastic Path Commerce in a command line environment.