Created: 2016-06-15 mié 07:58
git
<>
github
zsh
or oh-my-zsh
# How my git configuration looks like?
git config --list
# Adding some, if you don't have a user.name or user.email set
git config --global user.name myusername
## This is very important!!
## YOU NEED TO DO THIS
git config --global push.default current
mkdir my_working_directory
cd my_working_directory
git init
touch some_file.py
# hack
# hack
git add some_file.py
git commit -m "Working with some awesome idea"
# hack
# more hack
...
Some differences:
github
accountgithub.com
in which you want to participate
http://github.com/the-repo-you-want-to-participate
Fork
buttongit clone http://github.com/my-copy-of-the-repo-you-want-to-participate
cd the-repo-you-want-to-participate
# hack
# hack
git add some_file.py
git commit -m "Working with some awesome idea"
# hack
# hack
git push
pull-request
and describe your workpull
the most recent changes in the original repo?## See the "remotes"
git remote -v
## Add the original repo
git remote add original-repo http://github.com/the-repo-you-want-to-participate
## Pull the changes of the original repo to your local copy
git pull original-repo master
## Push the added changes to your repo
git push origin master
## etc
git
-gurus involvedDon't code anything if there is not a need of doing it
## Pull from the repo
git pull
## Decide what do you want to do and create an issue
git checkout -b a-meaningful-name
## hack, hack, hack, add/rm, commit
## Push to the repo and create a remote branch
git push
## Create a pull-request and describe your work (Suggest/add a reviewer)
## Code review
## The pull-request is closed and the remote branch is destroyed
## Switch to master locally
git checkout master
## Destroy your local branch
git branch -D a-meaningful-name
## Pull the most recent changes (including yours)
git pull
test
do_stuff()
(no args)I'm step X
, where X
is the number of the stepmaster.py
that uses that 3 steps in order.test
directoryCreada por Adolfo De Unánue.