Skip to content

Latest commit

 

History

History
99 lines (69 loc) · 2.48 KB

CONTRIBUTING.md

File metadata and controls

99 lines (69 loc) · 2.48 KB

Contributing Guide

We are glad you want to contribute to jenkins-infra - in particular the plugin-site.

Adhering to the following process is the best way to get your work included in the project:

  1. Fork the project, clone your fork, and configure the remotes:

    # Clone your fork of the repo into the current directory
    git clone https://github.com/<your-username>/plugin-site.git
    # Navigate to the newly cloned directory
    cd plugin-site
    # Assign the original repo to a remote called "upstream"
    git remote add upstream https://github.com/jenkins-infra/plugin-site.git
  2. If you cloned a while ago, get the latest changes from upstream:

    git checkout main
    git pull upstream main
  3. Create a new topic branch (off the main project development branch) to contain your feature, change, or fix:

    git checkout -b <topic-branch-name>
  4. Make your changes. You can check in the README.md file how to setup a development environment and how to test the integrity of the code.

  5. Commit your changes in logical chunks. Please adhere to these git commit message guidelines or your code is unlikely be merged into the main project. Use Git's interactive rebase feature to tidy up your commits before making them public.

  6. Locally merge (or rebase) the upstream development branch into your topic branch:

    git pull [--rebase] upstream main
  7. Push your topic branch up to your fork:

    git push origin <topic-branch-name>
  8. Open a Pull Request with a clear title and description against the main branch.

IMPORTANT: By submitting a patch, you agree to allow the project owners to license your work under the terms of the MIT License.

Running the app

Requirements

  • node 20+

Run locally

yarn install
cd ./plugins/plugin-site
yarn dev
Open http://localhost:3000

To aid with development mode, an environment variable of GET_CONTENT is needed to force gatsby to pull down the slow wiki/github content for each plugin

Linting

ESLint with React linting options have been enabled.

yarn lint

Tests

Execute tests via

yarn test

or run in watch mode

cd ./plugins/plugin-site
yarn test:watch