Skip to content

Latest commit

 

History

History
226 lines (171 loc) · 8.95 KB

CONTRIBUTING.md

File metadata and controls

226 lines (171 loc) · 8.95 KB

📚 Contributing Guidelines

When contributing, please first discuss the change you wish to make via issue, email, or any other method with the owners of this repository before making a change. Please note we have a code of conduct, please follow it in all your interactions with the project.

📖 Knowledge Base

Need some help regarding the basics?🤔

You can refer to the following articles on basics of Git and Github and also contact the Project Mentors, in case you are stuck:

📨 Submitting Contribution

Below you will find the process and workflow used to review and merge your changes.

Step 0 : Find an issue 🔎

  • Take a look at the Existing Issues or create your own Issues!
  • Wait for the Issue to be assigned to you after which you can start working on it.
  • Note : Every change in this project should/must have an associated issue.

Step 1 : Fork the Project ↪️

  • Fork this Repository. This will create a Local Copy of this Repository on your Github Profile. Keep a reference to the original project in upstream remote.
git clone https://github.com/<your-username>/<repo-name>
cd <repo-name>
git remote add upstream https://github.com/srealmoreno/label-sync-action
  • If you have already forked the project, update your copy before working.
git remote update
git checkout <branch-name>
git rebase upstream/<branch-name>

Step 2 : Branch 🔀

Create a new branch. Use its name to identify the issue your addressing.

# It will create a new branch with name Branch_Name and switch to that branch
git checkout -b branch_name

Step 3 : Work on the issue assigned 👨‍💻

  • Work on the issue(s) assigned to you.
  • Add all the files/folders needed.
  • After you've made changes or made your contribution to the project add changes to the branch you've just created by:
# To add all new files to branch Branch_Name
git add .

# To add only a few files to Branch_Name
git add <some files>

Step 4 : Commit 💬

  • To commit give a descriptive message for the convenience of reviewer by:
# This message get associated with all files you have changed
git commit -m "message"
  • NOTE: A PR should have only one commit. Multiple commits should be squashed.

Step 5 : Work Remotely 📤

  • Now you are ready to your work to the remote repository.
  • When your work is ready and complies with the project conventions, upload your changes to your fork:
# To push your work to your remote repository
git push -u origin Branch_Name

Step 6 : Pull Request 📦

  • Go to your repository in browser and click on compare and pull requests. Then add a title and description to your pull request that explains your contribution.

📝 Recommendations

Issues and feature requests 💡

You've found a bug in the source code, a mistake in the documentation or maybe you'd like a new feature? Take a look at GitHub Discussions to see if it's already being discussed. You can help us by submitting an issue on GitHub. Before you create an issue, make sure to search the issue archive -- your issue may have already been addressed!

Please try to create bug reports that are:

  • Reproducible. Include steps to reproduce the problem.
  • Specific. Include as much detail as possible: which version, what environment, etc.
  • Unique. Do not duplicate existing opened issues.
  • Scoped to a Single Bug. One bug per report.

Even better: Submit a pull request with a fix or new feature!

How to submit a Pull Request 📤

  1. Search our repository for open or closed Pull Requests that relate to your submission. You don't want to duplicate effort.
  2. Fork the project
  3. Create your feature branch (git checkout -b feat/amazing_feature)
  4. Commit your changes (git commit -m 'feat: add amazing_feature') uses conventional commits, so please follow the specification in your commit messages.
  5. Push to the branch (git push origin feat/amazing_feature)
  6. Open a Pull Request

Clean Pull Request 🧹

Contributing is also a great way to learn more about social coding on Github, new technologies and and their ecosystems and how to make constructive, helpful bug reports, feature requests and the noblest of all contributions: a good, clean pull request.

  • Create a personal fork of the project on Github.
  • Clone the fork on your local machine. Your remote repo on Github is called origin.
    • git clone https://github.com/<your-username>/label-sync-action
  • Add the original repository as a remote called upstream.
    • git remote add upstream https://github.com/srealmoreno/label-sync-action
  • If you created your fork a while ago be sure to pull upstream changes into your local repository.
  • Create a new branch to work on! Branch from develop if it exists, else from main.
  • Implement/fix your feature, comment your code.
  • Follow the code style of the project, including indentation.
  • If there is related tests please run them.
  • Write or adapt tests as needed.
  • Add or change the documentation as needed.
  • Squash your commits into a single commit with git's interactive rebase. Create a new branch if it's necessary.
  • Push your branch to your fork on Github, the remote origin.
  • From your fork open a pull request in the correct branch. Target the project's develop branch if there is one, else go for main!
  • Once the pull request is approved and merged you can pull the changes from upstream to your local repo and delete your extra branch(es).

Always write your commit messages in the present tense. Your commit message should describe what the commit, when applied, does to the code – not what you did to the code. (examples)

Commit messages 💬

  • Use the Present Tense ("Add feature" not "Added feature").

  • Use the Imperative Mood ("Move file to..." not "Moves file to...").

  • Limit the subject line to 50 characters

  • Wrap the body at 72 characters

  • Reference issues and pull requests, where possible.

  • Be creative with emojies

    • 🎉 :tada: Initial commit
    • 🎨 :art: when improving the format/structure of the code
    • 🐎 :racehorse: when improving performance
    • 📚 :books: when writing docs
    • ✏️ :pencil2: when fixing typos
    • 🐛 :bug: when fixing a bug
    • 🔥 :fire: when removing code or files
    • 💚 :green_heart: when fixing the CI build
    • :white_check_mark: when adding tests
    • 🔒 :lock: when dealing with security
    • :heavy_plus_sign: when adding new dependencies
    • ⬆️ :arrow_up: when upgrading dependencies
    • ⬇️ :arrow_down: when downgrading dependencies
    • 👕 :shirt: when removing linter warnings
    • 🚧 :construction: work in progress
    • :sparkles: when adding feature
    • 💄 :lipstick: when improving UI
    • 💎 :gem: new release
    • 🚀 :rocket: Anything related to Deployments/DevOps

Do not add images, rather 👇

Instead of adding non-essential images to repository link them to markdown files.

How to do that? 📌

  • You can do that by hosting all you images and screenshots to any images hosting sites such as imgur, imgbb, postimages.
  • Then link your uploaded images to README files.

👥 Community membership

New contributors 🖋

New contributors should be welcomed to the community by existing members, helped with PR workflow, and directed to relevant documentation and communication channels