Skip to content

Latest commit

 

History

History
73 lines (53 loc) · 2.08 KB

CONTRIBUTING.md

File metadata and controls

73 lines (53 loc) · 2.08 KB

Contributing to validatorgo

Welcome to validatorgo repository!! We appreciate your interest in contributing to this open source library and for helping our community grow.

How to Contribute

Code Contribution

In general, we follow the "fork-and-pull" Git workflow.

  1. Fork the repository on GitHub
  2. Clone the forked project to your local machine
git clone https://github.com/<your-username>/<repo-name>.git
cd <repo-name>
  1. Work on your fork

    • Make your changes and additions

      • Most of your changes should be focused on root directory, the sanitizer package and the README.md.
    • Change or add tests if needed

      • Add or update tests in the relevant *_test.go files.
    • Run tests and make sure they pass

        go test ./...
    • Update documentation if necessary
      • Update README.md and other go doc comments to reflect your changes.
  2. Commit changes to your own branch

  • Create a new branch for your work:
    git checkout -b <feature-or-fix-name>
  • Stage and commit your changes
    git add .
    git commit -m "Describe your changes"
  1. Merge the latest from "upstream" and resolve conflicts if any
  • Add the upstream repository
    git remote add upstream https://github.com/<original-repo-owner>/<repo-name>.git
  • Fetch and merge the latest changes
    git fetch upstream
    git merge upstream/main
  1. Repeat step 3
  • Re-test your changes after merging upstream updates to ensure everything still works as intended.
  1. Push your work back up to your fork
git push origin <branch-name>
  1. Submit a Pull Request (PR)
  • Go to the original repository on GitHub and navigate to the Pull Requests tab.
  • Click on "New Pull Request" and select the dev branch.
  • Add a meaningful title and description for your changes.
  • Submit the Pull Request for review.