Open Source Comes to Campus/Github pull steps: Difference between revisions

imported>Paulproteus
(Created page with "== To fork a project on Github == * Start out logged in to Github * Visit the project you want to fork * Click the "Fork" button in the top-right * Wait for the animation ...")
 
imported>Shauna
 
(13 intermediate revisions by 2 users not shown)
Line 1:
== Visiting the project on the web ==
 
Since this project is a website, we've specially configured the repository so that whenever there is a push to it, it is made visible on the web.
 
If your group's repository is called e.g. ''waffle-castle.github.io'', then you can see that the shared version is visible on the web at http://waffle-castle.github.io/.
 
But note that any changes in your ''fork'' won't show up there until the maintainer of the project merges those changes in.
 
== To fork a project on Github ==
 
Line 9 ⟶ 17:
* Wait for the animation to conclude
 
* Notice that your browser is now visiting a copy of the project in your personal space, rather than the old, group-owned one. You should also see a "fork of..." remark in the top-left. (See [https://openhatch.org/wiki/File:Forks.png here] for screenshot.)
 
== Now, clone to it to your computer ==
Line 25 ⟶ 33:
* Once you've done that, "cd" into the directory.
 
== Now, makeMake sure you have the project properly set up ==
 
* Open index.html in your favorite text editor -- it should look like a regular HTML page
Line 37 ⟶ 45:
== Find a task ==
 
Now, find a bug on the project's issue tracker that you will work on, and '''assignclaim it toby yourself'''!leaving a comment on the issue saying so.
 
(Before you do that, make sure to refresh the page and check that no one else has claimed it while you were reading and deciding.)
Now, work with your text editor to resolve it!
 
== Resolve the task ==
 
How you do this depends on the issue you've chosen. If you run into a problem you can't seem to solve, try asking the student next to you or one of the mentors.
 
Make sure to open up index.html and check that your solution works.
 
== Commit and push ==
 
Once you're finished making changes, you can use the following command to get a list of files you've changed:
Now, commit your changes by typing:
 
git status
 
You can commit your changes by typing "git add" followed by the files you've changed, for instance:
 
git add index.html
 
Once you've added the changes, you can "commit" them with a message specifying what you've changed.
 
git commit -m "Explanation of my changes"
Line 53 ⟶ 73:
git push
 
Now,You can now visit Github and make sure your personal fork (the repository under your account) contains those changes.
 
== Create pull request ==
 
Now, visitVisit your personal fork and click the "Pull requests" button on the right. This will offer you the chance to "Create...". Explain what you did, and leave a remark that this relates to the issue number you saw.
 
a remark that this relates to the issue number you saw.
Now, get feedback from the project's maintainer, (the mentor leading your group) and eagerly await your pull request getting merged!
 
== Once merged, visit your changes on the web ==
 
When your changes are merged into the main project repository, our specially configured repository will update the group website with the merged files.
 
This is a special trick that we do during the Website editing with git exercise, using Github Pages. It demonstrates that when the merge happens, it can programmatically cause a different event; this is often called ''hooks''.
Now, get feedback from the project's maintainer, and eagerly await your pull request getting merged!
Anonymous user