-
-
Notifications
You must be signed in to change notification settings - Fork 139
docs: make steps in git workflow more beginner-friendly #1772
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
docs: make steps in git workflow more beginner-friendly #1772
Conversation
@derberg can you help review, if we missed a step |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
left some suggestions
I love you how change approach to have one code snippet with command and examples/output - reads better
git-workflow.md
Outdated
|
||
Each contributor and maintainer in AsyncAPI must follow this workflow: | ||
AsyncAPI uses a fork model to allow contributions to the organization's repositories. In this model, you push changes to your own working copy (a fork, a so-called `origin`) of the original repository (a so-called `upstream`), and then create one or more pull requests (PRs) to incorporate changes from the `origin` to `upstream`. This unified workflow allows both members and external contributors to contribute through the same process, keeping the main repository branches clean. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
AsyncAPI uses a fork model to allow contributions to the organization's repositories. In this model, you push changes to your own working copy (a fork, a so-called `origin`) of the original repository (a so-called `upstream`), and then create one or more pull requests (PRs) to incorporate changes from the `origin` to `upstream`. This unified workflow allows both members and external contributors to contribute through the same process, keeping the main repository branches clean. | |
AsyncAPI uses a fork model for all community members, including maintainers. In this model, you push changes to your own working copy (a fork, a so-called `origin`) of the original repository (a so-called `upstream`), and then create one or more pull requests (PRs) to incorporate changes from the `origin` to `upstream`. This unified workflow allows both members and external contributors to contribute through the same process, keeping the main repository branches clean. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
(a fork, a so-called
origin
)
you need to change it somehow - it sounds like origin is the same as fork but it is not
origin is the remote version of repo - opposing the local copy (clone)
so upstream, if somebody clones (asyncapi bot) the upstream, it operates on local version, on clone - and pushes it to origin, in this case upsteam is origin
so fork = origin && upstream = origin
git-workflow.md
Outdated
```bash | ||
# Command | ||
git fetch upstream BRANCH-NAME | ||
|
||
# Example | ||
git fetch upstream master | ||
``` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
```bash | |
# Command | |
git fetch upstream BRANCH-NAME | |
# Example | |
git fetch upstream master | |
``` | |
```bash | |
# Command | |
git fetch upstream master | |
``` |
in our case it will always be master
- because of ci/cd complex setup, we are not able to enable main
git-workflow.md
Outdated
|
||
In case you are a contributor who suggests minor changes using GitHub UI, it is recommended to use a [Pull bot](https://probot.github.io/apps/pull). This bot keeps your fork up to date by creating and merging a pull request with latest changes into the `master `branch of your fork. | ||
For minor changes via GitHub UI, use a [Pull bot](https://probot.github.io/apps/pull) to keep your fork up to date. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
so many years after writing this first version of the document, not sure we should recommend pullbot
now there is a native functionality in GH, that allows you to update your fork with upstream with one click
I stopped using pull bot few years back 😄
git-workflow.md
Outdated
|
||
4. Create a pull request from the branch of your forked repository to the `master` branch of the upstream repository and wait for the maintainers' review. | ||
4. Create a pull request from your branch of the `origin` repository to the `master` branch of the `upstream` repository and await review. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
4. Create a pull request from your branch of the `origin` repository to the `master` branch of the `upstream` repository and await review. | |
4. Create a pull request from your branch of the fork repository to the `master` branch of the `upstream` repository and await review. |
git-workflow.md
Outdated
git remote add upstream https://github.com/{original-owner}/{original-repository}.git | ||
``` | ||
See the example: | ||
2. Add the `upstream` repository: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
2. Add the `upstream` repository: | |
2. Add the `upstream` repository. In other words, point to main project located in AsyncAPI GitHub organization: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
/rtm |
Description
When expanding our Community documentation (#1622) we came across the situation that multiple documents (#1725, #1730) describe git workflow as a prerequisite to start contributing to community repos.
It was decided to update the workflow document with more user-friendly instructions and link back to this document while removing redundant sections from other documents that mention git workflow in any context.
Related issue(s)
See also #1622 #1725 #1730