article cover image
Git Level 2
ريادة الأعمال 1 دقيقة 0 تعليق 21 مشاهدة
صورة المستخدم يوشع يوسف
يوشع يوسف
تم النشر 2025-07-04 14:53:28 - آخر تحديث 2025-07-04 15:13:33

git level 1 in
https://oufok.com/article/view/39da064594c8af6d03592faa3b0ebece/

إنشاء فرع
git branch branch_name

حذف فرع
git branch -d branch_name
git branch --delete branch_name

لدخول فرع
git checkout branch_name // checked-out branch.

تغيير اسم الفرع
git branch --move old new
git branch -m old new

عرض الأفرع
git branch
git branch --all
git branch --list

إضافة commitـات فرع إلى الفرع الحالي
git merge branch_name

---

اكتب
git diff
لنرى الفرق بين git. و local copy

git diff file_name


ref can be a branch_name or a tag_name.


git diff ref1 ref2

git diff ref1 ref2 file_name

git diff <commitId1> <commitId2>

git diff --stat <branch/commitId>

git diff --name-only <branch/commitId>

git diff --name-only <commitId> <folder_path>


لرؤية الـcommitـات
git log

git log --oneline

git log --graph

git log --decorate --oneline --graph

git shortlog
-s --summary
-n --numbered
-e --email
--format


git log ref
لرؤية commitات ref


git show
or
git log -1
لعرض آخر commit

اكتب
git show commit_id
لعرض commit محدد

git log --all --grep "removed file"
Will search for removed file string in all logs in all branches

git log --grep="add file" --invert-grep Will show all commits that do not contain add file.

git log --after '3 days ago'
Specific dates work too:
git log --after 2016-05-01

git log --author=author

An alias to --after is --since.
Flags exist for the converse too: --before and --until.

git log --patch
-p

git log --stat

git level 3 in

https://oufok.com/article/view/dd6a392bfa53f8e1173403f308746e4c/

التعليقات (0)