-
Notifications
You must be signed in to change notification settings - Fork 38
Setup Development Repository
UPennalizers Development Repository built on ENIAC server and will be used for competition. Team member can either clone a new Development Repository or Add it to current open source folder.
git clone [pennkey]@eniac.seas.upenn.edu:git/UPennalizers-Dev.git UPennDev
Checkout NaoCompetition
git checkout -tb NaoCompeition origin/NaoCompetition
This is for experts only! Add New Repository to existing git checkout
git remote add dev [pennkey]@eniac.seas.upenn.edu:git/UPennalizers-Dev.git
git fetch dev
Checkout dev Master
git checkout -tb dev-master remotes/dev/master
Save password to server http://linuxproblem.org/art_9.html
Following Step assume that you cloned a new development repository and in master branch. Try git branch -a to check if there is a * in front of master or git checkout -tb [branchName] remotes/origin/[branchName] to change the base branch. If you added development repository to current folder, change the repository name from origin to dev in all following commands
Always commit with comments and your name
git commit -m "comments" --author='Your Name <email>'
if your laptop, setup your git config by
git config --global user.name "Your Name"
git config --global user.email "Your email"
git branch nsl-walk
git checkout nsl-walk
git push origin nsl-walk
Work on code here. After you do a "git add" and "git commit", you need to put your updates back to the server
git push origin nsl-walk
git checkout nsl-walk
git merge master
git push origin nsl-walk
git checkout nsl-master
git merge nsl-walk
git push origin nsl-master
git push origin :nsl-walk (this deletes your nsl-walk branch from the private git repo)
git branch -d nsl-walk (this deletes your nsl-walk branch from your local computer)
git remote prune origin
git fetch origin
git archive HEAD --format=zip > archive.zip
git archive HEAD | gzip > archive.tar.gz
Source General Notes
-
To work on a pre-existing branch, type:
- git checkout -tb nsl-existing-branch remotes/nsl/nsl-existing-branch
-
Work on this branch as normal. To commit changes and push them to the NSL repository:
- git commit -m "My changes are ..."
- git push nsl nsl-branch-to-push
-
To add a new branch to the NSL repo
- git branch nsl-new-branch
- git checkout nsl-new-branch
- git push nsl nsl-new-branch
-
To Delete this branch when you have merged it to nsl-master:
- git push nsl :branch-to-delete
-
To update one nsl branches (similar to svn update)
- git checkout nsl-branch-to-update
- git pull nsl nsl-branch-to-update
- To check if there are new branches:
- git checkout master
- git fetch nsl
-
To see what is going on:
- git remote show nsl
-
- git push -f