user391986
user391986

Reputation: 30956

use git show on a tag which has same name as file

I have an annotated tag that's called folicp but there is also a file with the same name so when I try to run

git show folicp 

I get fatal: ambiguous argument 'test': both revision and filename

Upvotes: 1

Views: 69

Answers (1)

Lily Ballard
Lily Ballard

Reputation: 185871

You can use git show folicp --. The -- distinguishes refs from filenames.

Alternatively you could use the fully-qualified tag name, git show refs/tags/folicp

Upvotes: 3

Related Questions