Platform:

Creating a fork of a core package

Several of Pulsar’s core packages are maintained in the packages directory of the pulsar-edit/pulsar repository. If you would like to use one of these packages as a starting point for your own package, please follow the steps below.

Creating your new package

For the sake of this guide, let’s assume that you want to start with the current code in the one-light-ui package, make some customizations to it, and publish your new package under the name one-light-ui-plus.

  1. Download the current contents of the pulsar-edit/pulsar repository as a zip file.

  2. Unzip the file to a temporary location (for example, /tmp/pulsarC:\TEMP\pulsar).

  3. Copy the contents of the desired package into a working directory for your fork.

$ cp -R /tmp/pulsar/packages/one-light-ui ~/src/one-light-ui-plus
$ cd ~/src/one-light-ui-plus
$ cp -R /tmp/pulsar/packages/one-light-ui ~/src/one-light-ui-plus
$ cd ~/src/one-light-ui-plus
$ Copy-Item -Path "C:\TEMP\pulsar\packages\one-light-ui" -Destination "C:\src\one-light-ui-plus" -Recurse -Force
$ cd C:\src\one-light-ui-plus
  1. Create a local repository and commit the initial contents
$ git init
$ git commit -am "Import core Pulsar package"
  1. Update the name property in package.json to give your package a unique name.

  2. Make the other customizations that you have in mind.

  3. Commit your changes.

$ git commit -am "Apply initial customizations"
  1. Create a public repository on github.com for your new package.

  2. Follow the instructions in the github.com UI to push your code to your new online repository.

  3. Follow the steps in the Publishing guide to publish your new package.

Merging upstream changes into your package

The code in the original package will continue to evolve over time, either to fix bugs or to add new enhancements. You may want to incorporate some or all of those updates into your package. To do so, you can follow these steps for merging upstream changes into your package.