How to set up git repo
- Create a new repo in GitHub.com
- Select SSH
- in R create your project with GitHub box tick
- create a test.R file then do initial comit
- Copy and paste this in the terminal git remote add origin git branch -M main git push -u origin main
######## SSH KEY is required if this is your first tie set up github
- paste this in your R terminal ssh-keygen -t ed25519 -C <email address associate with
- go to c/Users/Khoa.Truong/.ssh/id_ed25519.pub (this is the default location), but can cd to another location in the R terminal
- on GitHub.com go to setting>SSH and GPG KEYS then add new SSH Key
- paste the key from id_ed25519.pub to the box. which looks like this ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIL6hZXdfyN2dlIym68LMHJl0o/vfWiQf8ik5lvF1R1Nr