I'm very new to git/GitHub and stack, so I'm sorry if I say anything wrong or phrase things badly.
I just downloaded VS code on my mac, and chose the option to "Clone a Git Repository" I entered the link of the one I previously made, which just had a readme.md. I then some dragged an empty-example project into the local repository, under documents, staged the files committed and pushed. The repo is here: repo
My questions are:
git config --global user.name "my username went here"
and git config --global user.email "myemail.email.com"
, but do I not have to enter a password or anything? Can't I just type in someone elses username/email, and have all of their permissions?I really appreciate all the help, again sorry if I'm asking this badly, I'm very new to all of this.
- When I hit cmd+S, is it saving it directly in the local repo under my documents (where I chose to save it), or is the somewhere else?
When you save you save your file in your working directory. Git notice that the file has changed but you need to add+commit to store the changes inside git.
- If #1 is saving it directly in the local repo, what is the point of commits? Just to have a message?
The commit is an operation that stores a set of changes inside git.
- Before I started using github, I just saved it in a projects folder on my desktop, is it possible for me to have the files saved on my desktop, commit changes to the local repo and then, every once in a while, push to the origin?
Git works exactly like that. Your local repo is a copy of the "origin" repo. You can synch them using the pull/push commands
- How does VS code already know my account? I remember when I was watching git tutorials I did git config --global user.name "my username went here" and git config --global user.email "myemail.email.com", but do I not have to enter a password or anything? Can't I just type in someone elses username/email, and have all of their permissions?
When you push your changes to the remote origin git ask for github credentials
Anyway I suggest you to read a tutorial or something like this:
https://try.github.io/levels/1/challenges/1
bye