Git Quick Command for GitHub
git clone
root@:~/github/sandbox# git status
On branch master
Your branch is up-to-date with 'origin/master'.
Changes not staged for commit:
(use "git add ..." to update what will be committed)
(use "git checkout -- ..." to discard changes in working directory)
modified: README.md
no changes added to commit (use "git add" and/or "git commit -a")
root@:~/github/sandbox# git add README.md
root@:~/github/sandbox# git commit -m "first commit"
root@:~/github/sandbox# git commit -m "first commit"
[master ddd2de1] first commit
1 file changed, 1 insertion(+), 1 deletion(-)
root@:~/github/sandbox# git push origin master
Counting objects: 3, done.
Writing objects: 100% (3/3), 257 bytes | 0 bytes/s, done.
Total 3 (delta 0), reused 0 (delta 0)
05ed44f..ddd2de1 master -> master
Password Less Push to Github
$ git config credential.helper store
$ git push https://github.com/repo.git
Username for 'https://github.com':
Password for 'https://USERNAME@github.com':
Use should also specify caching expire,
git config --global credential.helper 'cache --timeout 7200'
No comments:
Post a Comment