Git 2 Flashcards
What does git log –pretty=format fo
It makes the output of git log with a specific format
Mention 5 specifiers for git log –pretty=format
%H commit hash
%h commit abv hash
%T tree hash
%t abv tree hash
%P parent hashes
%p abv parent hashes
%ae author email
%an author name
%ad author date(respects the –date option)
%ar author relative date
%s subject
An equivalent of git reset HEAD <file> is</file>
git restore –staged <file></file>
What does git remote -v
It lists all the remotes with its URLs
What does git fetch <remote> do?</remote>
It fetches all the branches form that remote and also creates branches <remote>/<branch></branch></remote>
What does git pull do?
It fetches the remote that is set up to follow for your current branch and the merges it.
What does git branch –move
Renames branch
What is the difference between a lightweight and annotated tag
Lightweight tags only creates a reference to a commit, annotated are objects with its own hash that stores metadata (including a message) and the reference to the commit
What does git tag -s do
-s option signs the annotated tag and