
git level 2 in
https://oufok.com/article/view/6cd3c55209daaec086a55f1c44510a97/
github
اخلق مجلد repo
مجلد السحابة يسمى Remote Repository
اكتب
git remote -v
لمعرفة جواب
هل مجلد repo مربوط ب مجلد github؟
اكتب
git remote add origin repo_http
لربط مجلدك repo ب مجلد github
git remote set-url origin repo_http
git remote --verbose
-v
git remote rename origin destination
# Change remote name from 'origin' to 'destination'
git remote get-url origin
اكتب
git push -u origin branch_name
لرفع محتويات مجلدك repo إلى مجلد github
* `git push --force`: Use with extreme caution! This command overwrites the remote branch, potentially losing changes.
General syntax
git push <remotename> <object>:<remotebranchname>
Example
git push origin master:wip-yourname
Deleting the remote branch is the equivalent of pushing an empty object to it.
git push <remotename> : <remotebranchname>
or
git push origin --delete wip-yourname
رفع commit وحيد
git push <remotename> <commit SHA> : <remotebranchname>
There are 4 types of Object:
blob, tree, commit, tag
اكتب
git clone link
تنزيل مجلد github إلى مجلدك repo
git clone [repo_url] --depth 1
git clone --branch <branch name> <url>
اكتب
git fetch url branch_name
تنزيل فرع في مجلد github إلى مجلدك repo
git fetch --depth=1000
git fetch remote-name
اكتب
git merge
لدمج ما fetchـه من مجلد github ب مجلدك repo
git merge remote-name/branch-name
pull=git fetch+git merge
git pull origin branch_name
_______________________
من خدمات github
1 دعوة صديق
collaborator
2 نسخ مشروع شخص ما
fork