Skip to main content

目標​

  • ファイルを作る/中身を見る
  • git add と git commit の動きを体で覚える

やること(そのまま打てばOK)​

# 1) フォルダとファイルを作る
mkdir -p practice1 && echo "はじめてのGit" > practice1/hello.txt

# 2) 変更を見る
git status && git diff -- practice1/hello.txt || true

# 3) ステージに載せてコミット
git add practice1/hello.txt
git commit -m "feat: 練習1 hello.txt を追加"

# 4) ログを見る(1行表示)
git log --oneline -5

次のステップ​