Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 889829
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 15, 20262026-05-15T13:37:42+00:00 2026-05-15T13:37:42+00:00

Every piece of documentation I’ve read on git (including the online book and the

  • 0

Every piece of documentation I’ve read on git (including the online book and the built-in help) says I can type “git diff” from command line, but whenever I do that I get:

usage: git diff [--no-index] <path> <path>

Here’s what I’ve tried so far (all are examples from the documentation):

$ git diff
usage: git diff [--no-index] <path> <path>

$ git diff HEAD
usage: git diff [--no-index] <path> <path>

$ git diff --
usage: git diff [--no-index] <path> <path>

$ git diff -- .
usage: git diff [--no-index] <path> <path>

$ git diff --stat
usage: git diff [--no-index] <path> <path>

$ git --version
git version 1.7.1

Am I missing something here?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-15T13:37:43+00:00Added an answer on May 15, 2026 at 1:37 pm

    Are you actually inside a directory with a Git repository when you’re running these? (git rev-parse --git-dir) The command needs to be able to find the repository and determine what your working tree is in order to produce useful output. Otherwise (if a repository cannot be identified), it defaults to being a plain recursive-diff command, and needs two paths to operate.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I haven't quite figured this out. EVERY piece of documentation I've found covers how
The Java language documentation says: If a primitive type or a string is defined
At the end of the day every piece of code we write eventually gets
Every thing goes in code, but not saving data in SQLite db. Can any
See this simple piece of code in PHP: //Documentation: //memcache_set ( string $key ,
We have a requirement that every piece of code that makes it into production
I have a piece of code that needs to run every day at a
I was given the task of creating a stored procedure to copy every piece
I am new to WPF so I would accept every piece of advice. My
Just about every piece of example code everywhere omits error handling (because it confuses

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.