One path, start to finish, for any lab that asks you to submit a GitHub URL: a OneDrive folder, opening it in VS Code, committing your work, publishing it, and pasting the link into Canvas. Works the same whether the lab is a Jupyter notebook, a .py file, or anything else.
Lab computers on campus already have Git installed, so you can skip straight to Step 1 there. Everything on this page assumes VS Code is already installed — see IDEs & Code Editors if it isn't yet.
The most common point of confusion: which of these steps you only ever do one time on a given computer, and which ones start over for every single lab. Each lab becomes its own separate GitHub repository, so most of this page repeats.
Every lab gets its own fresh folder. Don't reuse a folder from a previous lab, and don't put a new lab's files inside an old lab's folder.
Lab 7. Use whatever name your instructor asks for; it's fine if it has a space in it.Using OneDrive, not just any folder on your hard drive, means your files are backed up automatically and available if you switch to a different lab computer.
Skip this step entirely if you've already done it on this computer for an earlier lab. If you're not sure, it's harmless to run it again.
git config --global user.name "Your Name"
git config --global user.email "[email protected]"
This is different from signing in to GitHub, which happens later in Step 6. Want to know exactly what this command does? See the core Git commands, explained.
This step looks the same no matter what kind of file the lab uses, a Jupyter notebook, a .py script, or anything else your instructor hands out.
Lab7_JaneDoe.ipynb), do that now.Ctrl+S on Windows, Cmd+S on Mac).Saving the file and submitting the lab are not the same thing. Ctrl+S only saves to your OneDrive folder. Nothing is on GitHub, and nothing is submitted, until you complete Steps 5 through 7 below.
Initial commit, into the message box at the top of the panel.Ctrl+Enter) to commit.This saves a snapshot on your own computer. It still hasn't gone anywhere — that's the next step.
Already signed in from a previous lab? VS Code remembers you, and this step just asks Public or Private before publishing.
https://github.com/your-username/Lab-7.