I am new to linux, and I have just installed git using,
sudo apt-get install git-all
When I attempted to restore a file after making modifications, I get the following error:
git: 'restore' is not a git command. See 'git --help'.
I did some research, and it turns out that git restore was not implemented until git version 2.23.0. I then ran,
git --version
And saw that I had 2.20.1 installed. To update git, I ran,
sudo apt-get update
sudo apt-get --only-upgrade install git-all
It told me that git-all is already the newest version (1:2.20.1-2+deb10u3), but this is not the latest version of git. The latest version of git is 2.34.1. What is happening here and how can I update git?