dotNetty is a large project and contributions are more than welcome, so thank you for wanting to contribute to dotNetty!
Submit only relevant commits. We don't mind many commits in a pull request, but they must be relevant as explained below.
#issue
. Example of a bad message After reviewing a Pull request, we might ask you to fix some commits. After you've done that you need to force push to update your branch in your local fork.
Give the PR a descriptive title and in the description field describe what you have done in general terms and why. This will help the reviewers greatly, and provide a history for the future.
Especially if you modify something existing, be very clear! Have you changed any algorithms, or did you just intend to reorder the code? Justify why the changes are needed.
Make sure you have a GitHub account.
Fork, clone, add upstream to the dotNetty repository. See Fork a repo for more detailed instructions or follow the instructions below.
Fork by clicking Fork on https://github.com/Azure/DotNetty
Clone your fork locally.
git clone https://github.com/YOUR-USERNAME/DotNetty
git remote add upstream https://github.com/Azure/DotNetty
You now have two remotes: upstream points to https://github.com/Azure/DotNetty, and origin points to your fork on GitHub.
Unsure where to start? Issues marked with up for grabs are things we want help with.
See also: Contributing to Open Source on GitHub
New to Git? See https://help.github.com/articles/what-are-other-good-resources-for-learning-git-and-github
Never work directly on dev or master and you should never send a pull request from master - always from a feature branch created by you.
git checkout dev
git fetch upstream
git merge --ff-only upstream/dev
git push origin dev #(optional) this makes sure dev in your own fork on GitHub is up to date
See https://help.github.com/articles/fetching-a-remote for more info
implement-lengthframeencoder-323
or 295-implement-recvbuffer
, so that others can see what is being worked on.git checkout -b my-new-branch-123
git push origin my-new-branch-123
See also: Understanding the GitHub Flow (we're using dev
as our master branch)
While you're working away in your branch it's quite possible that your upstream dev may be updated. If this happens you should:
git stash
git checkout dev
git fetch upstream
git merge --ff-only upstream/dev
git checkout my-new-branch-123
git rebase dev
git push origin dev #(optional) this makes sure dev in your own fork on GitHub is up to date
This ensures that your history is "clean" i.e. you have one branch off from dev followed by your changes in a straight line. Failing to do this ends up with several "messy" merges in your history, which we don't want. This is the reason why you should always work in a branch and you should never be working in, or sending pull requests from dev.
If you're working on a long running feature then you may want to do this quite often, rather than run the risk of potential merge issues further down the line.
If you realize you've missed something after submitting a Pull request, just commit to your local branch and push the branch just like you did the first time. This commit will automatically be included in the Pull request.
If we ask you to change already published commits using interactive rebase (like squashing or splitting commits or rewriting commit messages) you need to force push using -f
:
git push -f origin my-new-branch-123
If all commits are on dev you need to move them to a new feature branch.
You can rebase your local dev on upstream/dev (to remove any merge commits), rename it, and recreate dev
git checkout dev
git rebase upstream/dev
git branch -m my-new-branch-123
git branch dev upstream/dev
Or you can create a new branch off of dev and then cherry pick the commits
git checkout -b my-new-branch-123 upstream/dev
git cherry-pick rev #rev is the revisions you want to pick
git cherry-pick rev #repeat until you have picked all commits
git branch -m dev old-dev #rename dev
git branch dev upstream/dev #create a new dev
See our C# Coding Style for more information on following the project's conventions.
Props to Akka.NET and NancyFX from which we've "borrowed" this text.
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。