לדלג לתוכן

🔀 מבוא ל-Git

ברוכים הבאים!

קורס מקיף ללימוד Git מאפס עד רמה מתקדמת. הקורס מכסה את כל הנושאים החשובים: מיסודות, דרך branches ומיזוג, ועד workflows מקצועיים, rebase ו-pull requests.

למה Git?

  • 📚 מערכת בקרת הגרסאות הפופולרית בעולם
  • 🌳 עבודה במקביל על פיצ'רים בעזרת branches
  • 🔄 שיתוף קוד בקלות עם GitHub, GitLab ו-Bitbucket
  • ⏪ שחזור מלא של היסטוריית הפרויקט בכל רגע נתון

📚 מבנה הקורס

חלק א' - יסודות

מספר נושא קובץ
1 רקע והיסטוריה 01_background.md
2 התקנה והגדרות 02_installation.md
3 מושגי יסוד 03_basic_concepts.md

חלק ב' - מחזור החיים הבסיסי

מספר נושא קובץ
4 יצירת מאגר ראשון 04_first_repo.md
5 status, add, commit 05_status_add_commit.md
6 היסטוריה ו-log 06_history_log.md
7 ביטול שינויים 07_undo_changes.md

חלק ג' - Branches ו-Merge

מספר נושא קובץ
8 Branches 08_branches.md
9 Merge 09_merge.md
10 פתרון קונפליקטים 10_conflicts.md

חלק ד' - עבודה מרחוק

מספר נושא קובץ
11 Remote Repositories 11_remote.md
12 push, pull, fetch 12_push_pull_fetch.md
13 Clone 13_clone.md
14 gitignore 14_gitignore.md

חלק ה' - כלים מתקדמים

מספר נושא קובץ
15 Stash 15_stash.md
16 Tags 16_tags.md
17 Rebase 17_rebase.md
18 Cherry-pick 18_cherry_pick.md
19 reset ו-revert 19_reset_revert.md

חלק ו' - Workflow ועבודת צוות

מספר נושא קובץ
20 Workflows נפוצים 20_workflow.md
21 Pull Requests 21_pull_requests.md
22 שיטות עבודה מומלצות 22_best_practices.md

📁 תיקיית דוגמאות

מספר נושא קובץ
1 יצירת מאגר ראשון 01_first_repo.sh
2 status, add, commit 02_status_add_commit.sh
3 היסטוריה ו-log 03_log_history.sh
4 ביטול שינויים 04_undo_changes.sh
5 Branches 05_branches.sh
6 Merge 06_merge.sh
7 פתרון קונפליקט 07_conflict_resolution.sh
8 Remote, push, pull 08_remote_push_pull.sh
9 gitignore 09_gitignore_example.sh
10 Stash workflow 10_stash_workflow.sh
11 Tags 11_tags.sh
12 Rebase 12_rebase.sh
13 Cherry-pick 13_cherry_pick.sh
14 reset ו-revert 14_reset_revert.sh
15 Workflow מלא 15_full_workflow.sh

🚀 איך להתחיל?

צעד 1: בדיקת התקנה

git --version

אם לא מותקן, יש להוריד מ-git-scm.com.

צעד 2: הגדרת זהות (פעם אחת בלבד)

git config --global user.name "השם שלך"
git config --global user.email "[email protected]"
git config --global init.defaultBranch main
git config --global core.editor "code --wait"

צעד 3: יצירת מאגר ראשון

mkdir my-project
cd my-project
git init
echo "# My Project" > index.md
git add index.md
git commit -m "Initial commit"

📖 סדר לימוד מומלץ

  1. שבוע 1: יסודות + מחזור חיים בסיסי (פרקים 1-7)
  2. שבוע 2: Branches, Merge וקונפליקטים (פרקים 8-10)
  3. שבוע 3: עבודה מול remote ו-gitignore (פרקים 11-14)
  4. שבוע 4: כלים מתקדמים (פרקים 15-19)
  5. שבוע 5: Workflows, Pull Requests ו-Best Practices (פרקים 20-22)

📋 נושאים שנכללים

  • ✅ מושגי יסוד: Repository, Working Directory, Staging Area, HEAD
  • ✅ מחזור החיים: status, add, commit, log
  • ✅ ביטול שינויים: restore, reset, revert, checkout
  • ✅ ניהול branches: branch, switch, checkout
  • ✅ Merge ו-Fast-forward
  • ✅ פתרון קונפליקטים ידני
  • ✅ עבודה עם remotes (origin, upstream)
  • ✅ push, pull, fetch ו-tracking branches
  • ✅ Clone ופרוטוקולים (HTTPS / SSH)
  • ✅ קובץ .gitignore ותחביר
  • ✅ Stash לשמירה זמנית
  • ✅ Tags (lightweight ו-annotated)
  • ✅ Rebase ו-interactive rebase
  • ✅ Cherry-pick
  • ✅ ההבדל בין reset ל-revert
  • ✅ Workflows: Git Flow, GitHub Flow, Trunk-based
  • ✅ Pull Requests וקוד-רוויו
  • ✅ הודעות commit נכונות וקונבנציות שמות branches

🛠️ כלים מומלצים

Git ב-CLI

  • Git Bash (Windows) - מובנה בהתקנה הרשמית
  • Terminal / iTerm2 (macOS)
  • GNOME Terminal / Konsole (Linux)

עורכי קוד עם אינטגרציה

  • Visual Studio Code - אינטגרציה מובנית מצוינת
  • GitLens - תוסף VS Code חזק במיוחד

ממשקים גרפיים

  • GitHub Desktop - פשוט ומותאם ל-GitHub
  • Sourcetree - חינמי מ-Atlassian
  • GitKraken - ממשק מתקדם

בהצלחה בלימוד Git! 🎉