Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

doc: add contributing guide template #2

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

xrutayisire
Copy link

Resolves: N/A

Description

  • I think adding contributing guide template or other repositories specific md templates to this repository is the way to go to share "code" related template.
  • Created a templates folder
  • Added contributing guide template
  • Added a small info about how to use template in any project

Checklist

  • If my changes require tests, I added them.
  • If my changes affect backward compatibility, it has been discussed.
  • If my changes require an update to the CONTRIBUTING.md guide, I updated it.

How to QA 1

  • Reading it 🥳

Footnotes

  1. Please use these labels when submitting a review:
    ❓ #ask: Ask a question.
    💡 #idea: Suggest an idea.
    ⚠️ #issue: Strongly suggest a change.
    🎉 #nice: Share a compliment.


# Test your changes before requesting a review.
# All changes should be tested. No failing tests are allowed.
[TEST COMMAND]
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think i'd separate tests from development.
As it can be a very messy part so i'd make it separated on his own.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That's a good idea since some repos require a specialized setup. Packages usually have very small requirements (just run npm run test), while services can have large requirements (run a server + configure .env + run the script).


<!-- Describe how to deploy this service to the staging environment. -->

#### Production
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should we specify that

  • only the main branch of services is to be deployed
  • it's people's responsibility to make sure their PR doesn't break production or other services (by running CI, creating tests, ...)

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't know if a rollback strategy make sense to add here but. could be a good addition

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should we specify that only the main branch of services is to be deployed

I think this info is specific to each service, so we can probably leave it out of the template. It can be mentioned in the "Production" section.

Should we specify that it's people's responsibility to make sure their PR doesn't break production or other services (by running CI, creating tests, ...)

Yes, that is a good addition, similar to the "no failing tests are allowed" line in the "Develop" section. It could be added as a Caution block. immediately after the "Production" heading.

I don't know if a rollback strategy make sense to add here but. could be a good addition

Makes sense to me as part of the Production section.

This guide should be short and concise while providing enough information to get started. The last thing someone wants to do when they start working is read a bunch of documentation. 😅 Do you have an idea of how we could do that?

Copy link
Member

@angeloashmore angeloashmore left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I like this idea a lot! I left a few comments below and replied to @Heyrows's thoughts.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ #issue: This file should be named CONTRIBUTING.md to follow this convention.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 #idea: We have a slightly different version for public packages, like @prismicio/client. Note that we replaced mentions of specific Prismic teams with just "Prismic."

What if we had both templates available in this repo?

It would mean my comment above about renaming the file to CONTRIBUTING.md is irrelevant. We could use this naming convention instead:

  • CONTRIBUTING-private.md
  • CONTRIBUTING-public.md

Comment on lines +107 to +108
# Checkout the master branch and pull the latest changes.
git checkout master
Copy link
Member

@angeloashmore angeloashmore Jun 14, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 #idea: Repositories use main as the default branch now. Maybe we can use main instead of master in the template.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants