git checking

Create a File and add it.

mkdir test
cd test
git init
echo "V1.0 Hi Tim" > t.txt
git add t.txt
git commit -a -m "Initial"

Bad Modify

We are developing some code and something goes badly wrong

echo "2 Bad Code" >> t.txt

To get back to the Last checking in Version

git checkout t.txt

Look at the File

text V1.0 Hi Tim

###Multiple Git add's

We are back with the V1.0 only source file

We add somecode and things are looking ok

bash echo "V1.1 Looks Ok" >> t.txt git add t.txt

And we do some more development

bash echo "V1.2 Looks Okish " >> t.txt git add t.txt

But we decide that this is not good and we want to go back to the V1.0 file.