Git

How do you undo changes in the working directory that haven’t been committed yet?

How do you undo changes in the working directory that haven’t been committed yet? a) git revert b) git reset –hard c) git checkout — file d) git delete Answer: c) git checkout — file Explanation: The command git checkout — file is used to undo changes in the working directory for a specific file,

How do you undo changes in the working directory that haven’t been committed yet? Read More »

What is a Git remote?

What is a Git remote? a) A repository hosted on a server b) A local branch c) A tag d) A commit Answer: a) A repository hosted on a server Explanation: A Git remote is a reference to a repository hosted on a server, such as GitHub, GitLab, or a private server. It allows you

What is a Git remote? Read More »

What is a Git tag?

What is a Git tag? a) A label for a specific commit b) A branch of a repository c) A commit message d) A pull request Answer: a) A label for a specific commit Explanation: A Git tag is a label used to mark a specific commit in the repository’s history. Tags are typically used

What is a Git tag? Read More »

Scroll to Top