Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.



Where to find the

...

CloudStack code

Source code is hosted at:

https://git-wip-us.apache.org/repos/asf/incubator-cloudstack.gitImage Removed

You can send in diffs of your changes to the Cloudstack development mailing list, where your diffs will be reviewed and committed to the master branch that syncs up often with the external public git branch.

The master git branch is what Apache Cloudstack developers work with. To clone this branch, you will need to do -

git clone https://git-wip-us.apache.org/repos/asf/incubator-cloudstack.gitImage Removed

You may want to pull a specific sub-branch of cloudstack-oss. To do this, you will need to first pull the cloudstack-oss branch using the git clone command above, and then, do -

...

$ git branch
master 
* my-feature

Step 64) Make your changes to the new my-feature branch, and git commit your changes.

Step 75) Pushing  Ready your changes patch for submission upstream :

           There are two cases here:

If you did this on              I) pushing your changes to the master branch which you pulled:

    •  

...

                            Just do "git push"

                Case b) You made changes to the local "my-feature" branch:

                              i) git log my-feature
                                    - get all the git commits you want to push upstream, in order bottom to top (you need to maintain the right patching order!)

                              ii) git checkout {}

                              iii) git cherry-pick <commit_number_bottom-most> .. .. .. <commit_number_top-most>

                              -- Alternately, you can do a simple -

                              ii) git checkout 3.0.x; git merge my-feature

                                    -- This will pull all your changes/commits that you made to my-feature.

                              iv) git push

             II) pushing your changes to a private branch that you forked off master:

                     Here, all steps for Case I) hold good, up until iii). But during git push, do this instead:

                              $ git push origin my-feature:pvt-my-feature

                     This will create a new branch "pvt-my-feature" on the origin (which is git.cloud.com's cloudstack-oss) and team members can pull this branch and check in all the feature code changes into it. To pull this branch, just do -

...

    • $ git format-patch origin   # this will provide a patch for each commit that is on your local copy of the branch that isn't upstream.    

If you did this on a topic branch

    • $ git format-patch origin master # this will provide a patch for each commit that's on your local branch that isn't on upstreams master

Step 6) Submit your patches for review. 

There are three different methods by which patches may be submitted upstream. 

  • Create a review request in ReviewBoard and upload your patches
  • Use git-send-email to the cloudstack-dev mailing list.
  • Create a bug in Jira and upload your patch to that bug

Other useful git commands

git stash

  - Lets you stash away the changes if you don't want to commit them yet but want to change your branch

...