Skip to content
This repository has been archived by the owner on Feb 27, 2023. It is now read-only.

Commit

Permalink
Merge pull request #1156 from truongnh1992/contribution
Browse files Browse the repository at this point in the history
docs: add more detail steps in workspace preparation
  • Loading branch information
lowzj committed Jan 13, 2020
2 parents 9b9ca93 + ae01fe8 commit a562669
Showing 1 changed file with 32 additions and 13 deletions.
45 changes: 32 additions & 13 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -74,22 +74,41 @@ To put forward a PR, we assume you have registered a GitHub ID. Then you could f

1. **Set Remote** upstream to be `https://github.com/dragonflyoss/Dragonfly.git` using the following two commands:

```
git remote add upstream https://github.com/dragonflyoss/Dragonfly.git
git remote set-url --push upstream no-pushing
```
```
git remote add upstream https://github.com/dragonflyoss/Dragonfly.git
git remote set-url --push upstream no-pushing
```

With this remote setting, you can check your git remote configuration like this:
With this remote setting, you can check your git remote configuration like this:

```
$ git remote -v
origin https://github.com/<your-username>/Dragonfly.git (fetch)
origin https://github.com/<your-username>/Dragonfly.git (push)
upstream https://github.com/dragonflyoss/Dragonfly.git (fetch)
upstream no-pushing (push)
```
```
$ git remote -v
origin https://github.com/<your-username>/Dragonfly.git (fetch)
origin https://github.com/<your-username>/Dragonfly.git (push)
upstream https://github.com/dragonflyoss/Dragonfly.git (fetch)
upstream no-pushing (push)
```

Adding this, we can easily synchronize local branches with upstream branches.

1. **Create a branch** to add a new feature or fix issues

Update local working directory:

```
cd Dragonfly
git fetch upstream
git checkout master
git rebase upstream/master
```

Create a new branch:

```
git checkout -b <new-branch>
```

Adding this, we can easily synchronize local branches with upstream branches.
Make any change on the `new-branch` then build and test your codes.

### Branch Definition

Expand Down

0 comments on commit a562669

Please sign in to comment.