git
command-line interface (CLI) to manage your project and submit it.
You'll need an account on GitHub, the dominant cloud-based source control solution
Some useful resources and explanations in the GitHub quickstart docs
git
Command-Line Interface (CLI)
git
, open a terminal and test it with:$ git --version git version 2.51.0.windows.1Then run the following configuration commands. First, set your identity for local commits:
$ git config --global user.name "John Doe" $ git config --global user.email johndoe@example.com
$ code
$ nano
$ vim
$ git config --global core.editor "code --wait"
$ git clone <repo URL>
It should open a browser window for login, but if it asks for username/password at the command line, you need create a Personal Access Token
After you successfully clone, change directories into the repo (e.g. cd 202610-assn01-html-and-css-testguy
) and then run this command to configure the
commit template. You will need to do each time you clone.
$ git config commit.template .gitmessage
Every time you finish working on your assignment, commit and push. In the root of the repo:
$ git status // check the state of the repo (and make sure you're in the repo) $ git add . // stage all the changes you made $ git status // confirm all your changes are there $ git commit // commit locally, opens the editor so you can uncomment checklist items and/or add a commit message $ git push // send the commit to the server
As a new git user, if anything goes wrong stop and re-clone to a different directory. Move your work over and continue. This is by far the easiest way to get out of any trouble you get into for now.
git clone <repo URL>
to create a local copygit status
to see what has changed (do this before and after all the other commands!)git add .
to stage all changes you've madegit commit
to store your staged changes as a changesetgit push
to upload all your changesets to GitHubclone
the repo and create the example.html file in the working directorycommit
and push
your work