So, let me start by recapping some of the operations that
we can perform on local repositories. I'm just going to list them
here and go through them by separating them into three main
categories. The first one is commands that, to create a repository and
notice that not all of these are git commands, that for
example, to create the repository, we would normally want to. Create a
directory, which is exactly what we did in our demo. We want
to go to that directory and then execute the git init statement,
which initializes that directory as a git repository. The second
category includes commands that we'll use to modify the content of
the repository. We saw that we can use git add
to add a specific file or a complete directory to our
index. So to the list of files that will be
committed, that will be considered in the next commit. Then we
can use commit to actually commit the changes that we
made to those files to our local repository, and we can
also use git move and git rm or git remove
to move files around and to remove files. Finally, the
third category is the category of commands that we can
use to inspect the concrete repository. And this set includes git
log, that we can use to see the log of
the repository, git status, that can give us important information
about the status of the file center repository. Git diff,
that we can use to see the differences between for example,
our local files. And the remote files. And finally git
show, that will show us information about our last commit. What
we committed, what were the changes and so on. And again,
we saw most or all of these commands in our demo.
So let me also remind you of a possible workflow. Which
again, we already saw but it's always good to go through
it once more. And remember that this is just an example.
It's just a possible workflow. You can do many different things,
you can have many different workflows with git. This is just
up to illustrate some of the things that you can do. So,
you might do some local editing. Execute git status to see what
files you changed. Then you might run a git diff on the
files to see what are these changes. And then you can run
git commit -a to commit your changes. And in case you
want to specify the commit message right away without having to go
through an editor, you can also add the -m parameter and
specify the message here on the same line.