Git - Move Branch

Move to “master” Open the terminal (press Ctrl+`) and run: git checkout master If master isn’t checked out locally yet, do: git fetch origin git checkout master If “master” was not updated in the local branch If the branch switched successfully to master, but the files in your working directory didn’t update as expected, it could be one of these cases: Confirm You’re on the Correct Branch Run this to verify: git branch You should see something like this. The asterisk * indicates your current branch. ...

May 20, 2025

Git - Useful Commands

1. Check the connection git remote -v See also: Git - Useful Commands Git - Move Branch Git - Ignore Settings

May 20, 2025

Git - Ignore Settings

How to Ignore Uploading Folders and Files to GitHub For example .venv folder Open your project folder in VS Code. Open .gitignore file in the root of the project Add the following line to .gitignore: .venv/ Save the file. then Git will ignore the .venv folder, and it won’t be tracked in your repository. If .venv was already committed before, you’ll need to remove it from Git history using: git rm -r --cached .venv git commit -m "Removed .venv from repository" git push origin main # or your current branch You can check if .venv is ignored by Git using the following command ...

February 25, 2025