ChibiOS-Contrib/README-git.md

64 lines
1.3 KiB
Markdown
Raw Normal View History

2014-10-11 04:59:57 -07:00
Quick start:
2014-10-19 10:35:29 -07:00
============
2014-10-11 04:59:57 -07:00
2014-10-19 10:31:18 -07:00
Assume you already have a github account. Lets your account name is
"username".
2014-10-11 04:59:57 -07:00
2014-10-19 10:31:18 -07:00
First you need to fork 2 repos:
2015-01-17 05:09:39 -08:00
- ChibiOS
2014-10-19 10:31:18 -07:00
- ChibiOS-contrib
2014-10-11 04:59:57 -07:00
2014-10-19 10:31:18 -07:00
Make local clone of your fork
2015-01-17 05:07:26 -08:00
```bash
2015-01-17 05:11:17 -08:00
# git clone git@github.com:username/ChibiOS.git
2015-01-17 05:07:26 -08:00
```
2014-10-11 04:59:57 -07:00
2014-10-19 10:31:18 -07:00
Make local branch for your feature
2015-01-17 05:07:26 -08:00
```bash
2015-01-17 05:11:17 -08:00
# cd ChibiOS
2014-10-19 10:39:55 -07:00
# git branch feature
# git checkout feature
2015-01-17 05:07:26 -08:00
```
2014-10-19 10:31:18 -07:00
There is no code from ChibiOS-contrib in your repo. We have to connect
ChibiOS-contrib as a git submodule
2015-01-17 05:07:26 -08:00
```bash
2014-10-19 10:39:55 -07:00
# git submodule add git@github.com:username/ChibiOS-Contrib.git community
2015-01-17 05:07:26 -08:00
```
2014-10-19 10:31:18 -07:00
Make branch again, but now in freshly connected submodule
2015-01-17 05:07:26 -08:00
```bash
2014-10-19 10:39:55 -07:00
# cd community
# git branch feature
# git checkout feature
2015-01-17 05:07:26 -08:00
```
2014-10-19 10:31:18 -07:00
Hack, hack, hack... Commit our changes and push to server. Note: you have
to do this for both repositories. First ChibiOS-Contrib
2015-01-17 05:07:26 -08:00
```bash
2014-10-19 10:39:55 -07:00
# cd community
# git add .
# git commit -m "Feature implemented"
# git push origin feature:feature
2015-01-17 05:07:26 -08:00
```
2014-10-19 10:31:18 -07:00
Now for parent repo
2015-01-17 05:07:26 -08:00
```bash
2014-10-19 10:39:55 -07:00
# cd ..
# git add .
# git commit -m "Feature implemented"
# git push origin feature:feature
2015-01-17 05:07:26 -08:00
```
2014-10-19 10:31:18 -07:00
Now all your changes published on github. Just use web interface to send
2015-01-17 05:11:17 -08:00
2 pull requests: for ChibiOS-contrib and for ChibiOS.
2014-10-11 04:59:57 -07:00
Links:
2014-10-19 10:37:46 -07:00
======
2014-10-19 10:39:55 -07:00
2014-10-19 07:57:27 -07:00
https://help.github.com/
2015-01-17 05:08:56 -08:00
2014-10-19 07:57:27 -07:00
http://git-scm.com/
2015-01-17 05:08:56 -08:00
2014-10-11 04:59:57 -07:00
http://chibios.org/dokuwiki/doku.php?id=chibios:guides:style_guide