dsp5680xx - flash module clk to freescale cfg value
[openocd/dsp568013.git] / HACKING
blob353e72f165c06191617cb77a0e00484360d55762
1 NB! If you're behind a corporate wall with http only access to the
2 world, you can still use these instructions!
4 Submitting patches to the OpenOCD Gerrit server:
6 OpenOCD is to some extent a "self service" open source project, so to
7 contribute, you must follow the standard procedures to have the best
8 possible chance to get your changes accepted.
10 The procedure to create a patch is essentially:
12 - make the changes
13 - create a commit
14 - send the changes to the Gerrit server for review
15 - correct the patch and re-send it according to review feedback
18 0. Create a Gerrit account at:
20 http://openocd.zylin.com
22 - On subsequent sign ins, use the full URL prefaced with 'http://'
23   For example:
25         http://user_identifier.open_id_provider.com
27 0.1. Add a username to your profile.
29 After creating the Gerrit account and signing in, you will need to
30 add a username to your profile. To do this, go to 'Settings', and
31 add a username of your choice.
33 Your username will be required in step 2 and substituted wherever
34 the string 'USERNAME' is found.
36 0.2. Add an SSH public key
38 Following the directions for your specific platform:
40         for Windows: help.github.com/win-set-up-git/#_set_up_ssh_keys
41         for OSX:     help.github.com/mac-set-up-git/#_set_up_ssh_keys
42         for Linux:   help.github.com/linux-set-up-git/#_set_up_ssh_keys
44 While these pages describe the setting up of git as well,
45 you should scroll down the page till you get to the section:
46 'Next: Set Up SSH Keys', and follow the steps described.
48 1. Clone the git repository, rather than just
49 download the source.
51 git clone git://openocd.git.sourceforge.net/gitroot/openocd/openocd
53 or if you have problems with the "git:" protocol, use
54 the slower http protocol:
56 git clone http://repo.or.cz/r/openocd.git
58 2. Set up Gerrit with your local repository. All this does it
59 to instruct git locally how to send off the changes.
61 Add a new remote to git using Gerrit username:
63 git remote add review ssh://USERNAME@openocd.zylin.com:29418/openocd.git
64 git config remote.review.push HEAD:refs/for/master
66 Or with http only:
68 git remote add review http://openocd.zylin.com/p/openocd.git
69 git config remote.review.push HEAD:refs/for/master
71 You will need to install this hook, we will look into a better
72 solution:
74 scp -p -P 29418 USERNAME@openocd.zylin.com:hooks/commit-msg .git/hooks/
76 Or with http only:
78 wget http://openocd.zylin.com/tools/hooks/commit-msg
79 mv commit-msg .git/hooks
80 chmod +x .git/hooks/commit-msg
82 3. Set up git with your name and email:
84 git config --global user.name "John Smith"
85 git config --global user.email "john@smith.org"
87 4. Work on your patches. Split the work into
88 multiple small patches that can be reviewed and
89 applied seperately and safely to the OpenOCD
90 repository.
92 while(!done) {
93   work - edit files using your favorite editor.
94   run "git commit -s -a" to commit all changes.
97 TIP! use "git add ." before commit to add new files.
99 --- example comment, notice the short first line w/topic ---
100 topic: short comment
101 <blank line>
102 longer comments over several
103 lines...
104 -----
106 5. Next you need to make sure that your patches
107 are on top of the latest stuff on the server and
108 that there are no conflicts.
110 git pull --rebase origin/master
112 6. Send the patches to the Gerrit server for review.
114 git push review
116 7. Forgot something, want to add more? Just make the changes and do:
118 git commit --amend
119 git push review
121 Further reading:
123 http://www.coreboot.org/Git