Skip to content

Latest commit

 

History

History
66 lines (41 loc) · 1.39 KB

CONTRIBUTING.md

File metadata and controls

66 lines (41 loc) · 1.39 KB

Contributing to utils

This is a short guide on how to contribute to the project.

Submitting a pull request

If you find a bug that you'd like to fix, or a new feature that you'd like to implement then please submit a pull request via GitHub.

Fork the Repository:

  1. Visit https://github.com/kashifkhan0771/utils

  2. Click the "Fork" button to create your own fork

  3. Clone your fork locally:

    git clone [email protected]:/utils.git cd utils

Make a branch to add your new feature

git checkout -b my-new-feature main

And get hacking.

When ready - run the unit tests for the code you changed

make test

Make sure you

  • Add documentation for a new feature
  • Add unit tests for a new feature
  • squash commits down to one per feature
  • rebase to develop git rebase main

When you are done with that

git push origin my-new-feature

Your patch will get reviewed, and you might get asked to fix some stuff.

If so, then make the changes in the same branch, squash the commits, rebase it to develop then push it to GitHub with --force.

Test

Tests are run using a testing framework, so at the top level you can run this to run all the tests.

# runs all tests
make test

Adding New Dependency

RUNTHIS='go get <package>'

Example

RUNTHIS='go get github.com/sirupsen/logrus'
RUNTHIS='go get github.com/sirupsen/[email protected]'