Integrating GitHub RStudio
This time, sign up for GitHub and create a GitHub RStudio Integrations Let's work together on this, because when you say GitHub, you mean something like Gitin your life? Git helps you version control your code locally (on your computer), and GitHub is a platform that allows you to share and collaborate on code across the internet.
We're going to ask our hero, CHATGPT, what Git and GitHub are again, and since we've been using 3.5 Turbo for the other posts, we're going to get answers from 4.0.
About Git, GitHub
Gitand GitHubThe Codeto Createand Managewhich Tools.
Git This is similar to saving your work as you go along. For example, when you're writing a document, if you don't hit 'save' after you've written an important part, you could lose everything you've written if your computer crashes or something goes wrong. So if you 'save' along the way, you'll be able to go back to the point where you left off if something goes wrong. Git uses this principle to manage your code. Every time you make a change to your code, it 'saves' that state and lets you go back to a previous state when you need to.
GitHub It's like cloud storage: if you store your documents only on your computer, no one else can see them, and if something happens to your computer, you can lose them. That's why many people store their documents in the cloud. GitHub is similar, allowing you to store your code in the cloud and share it with others, and it also has the ability to manage changes, even if multiple people are working on the same code at the same time.
In this way, you can think of Git and GitHub as tools that help you securely store, manage, and share your code.
Access and sign up for GitHub
hoxy, if you don't have Git installed, you'll first need to install the Installing Gitand let's go.
Open your web browser and navigate to ‘github.com‘on the server. Something bling-bling and cyberpathic. 'Sign up' Click to go through the signup process, starting with entering your email address. If you look closely, you'll see the words "Let's begin the adventure!" I thought this was just a casual phrase, and then you'll see why I say it (what! Is this scary? Or is this voice mail? No, it's an internet scam...).

Passwordsand set the Usernameand check whether you want to receive updates and announcements from GitHub by email, and Continuousand the adventure (puzzle solving) begins. I don't know if it's the snow or the lazy afternoon, but it's your turn... If you make it through this gateway in one piece, you're a GitHub user. (30 questions later and you're wondering why you're doing this...)

Now, did you pass? If you can think of the picture to the left and right in your head and answer 10 questions correctly, you pass. I'm wrong now... You go first. Anyone else? It's okay, it's my first time.^^/
Anyway, a checkmark indicates that you've passed, Create accountand GitHub will send a verification number to the email address you registered with. Check the number and enter it in the verification box to finally complete your signup.

Oh no, it's not over, it's asking for something else. Are you thinking, "Is this really an internet scam?" First, click the 'Skip personailzation' I missed this and suffered the GitHub woes (what. That's like going to a pharmacy and saying, "Hey, pharmacist, I'd like some headache medicine!"?!)

Now that you've signed up for GitHub, let's get down to business and create a remote repository.
Create a remote repository
If you've 'Skip Personalization', you've probably landed on the Dashboard screen as shown below.'Create repository' to create my first repository on the GitHub server (aren't we really getting robbed now? ...)

Enter a name for your repository, and lightly fill in the description. I'm going to use Quarto to build a website on GitHub, so I named it quarto-website. For the other options, leave it alone and use the 'Create Repository' on the bottom right.

Dare for the first time in my lifeinterest last(아 이건 아니지 ㅋㅋㅋ) 원격 저장 공간(quarto-website라는 이름의)이 깃허브 서버에 만들어졌습니다. 일단 추카추카! 짝짝짝!(이 글을 읽는 사람에게 보상을 줌으로써 조금이라도 더 내 블로그에서 놀도록 어그로?를 끈다.)

If you scroll down a little bit from the screen above, you'll see the following, which you can see by clicking on the orange square box that says Copy the URL addressSet it aside. After a while, you'll see a Information you need when working with RStudio. This is where I need you to get your head out of your ass. I was a little confused myself.

Integrating GitHub RStudio
Returning to RStudio. From the menu, select Tools > Project Options > Git/SVN > (None->GIT) >Yes in sequence. I can't help but say, "You're making me dizzy, Mr. Internet Engineer. Sometimes you need to turn up the difficulty level to strengthen your brain muscles! Start with Tools and follow the arrows!
Rerun RStudio from the previous step and run the 'Git' tab(It's Terry's Adventure, Hidden Object. Look for the Git tab!)
Click the Git tab > click 'Commit' After clicking, the 'Review Changes' window will pop up. Ctrl + a(Select All) to select all files.
Stage Click, Commit messageand then type Commit to perform a Git commit. Locally (on my machine), the commit ran against the files in the quatro-website folder. Since this is my first local commit, I entered the commit message as 'quarto-website project init' (think of init as an initialization...)
Author identity unknown
When you run the git commit command on my machine (local) with the above actions, you should see a message like the one below.
*** Please tell me who you are.
Run
git config -global user.email "you@example.com"
git config -global user.name "Your Name"
Think of this as labeling the work so that when multiple people work on this working directory, you can see who did what.
Select the Terminal window in the bottom right corner of RStudio and run the command above using the same one you used to sign up for GitHub (two dashes).
For example, git config -global user.email "gildonghong@gmail.com"
git config -global user.name "gildonghong"
Now that we've committed locally, let's take these homepage files on my machine and push them over to the remote repository.
New Branch button(
) and press Name the branch 'main'and enter 'Add Remote' After clicking Remote name with 'origin' and Ureal (which I copied from GitHub.)and then type 'Add'to complete the setup, and the Createin the left sidebar.
fatal:
fatal: unable to access 'https://github.com/********/*******.git/': SSL certificate problem: self-signed certificate in certificate chain
Anyone else getting the error above? This is an authentication error when connecting to a repository on GitHub with RStudio on my computer.
Click Tools > Global Options > Git/SVN > Create SSH Key button from the top menu of RStudio > Select SSH key type: RSA > Create > Close > Options screen to View public key > Ctrl + c to Close > Apply > OK to get to the main screen of RStudio.
Now go to your GitHub dashboard and select Settings by clicking the icon next to the inbox on the top right corner. Click the SSH and GPG keys menu in the center left corner and click the New SSH key button. On the screen that appears, enter a suitable title (e.g. myhome-computer), paste the one you copied above into the Key section, and click the Add SSH key button.
Back in RStudio, close RStudio completely and run it again to apply the settings properly. In a terminal window, execute the command below.
git remote set-url origin https://github.com/....../…...git (please make this part your own)
git push -u origin main
Oops. Suddenly a strange window pops up. It asks me to sign in to connect my computer with Git-Hub. I click "Sign in with you browser" to sign in.

Next, click 'Authorize git-ecosystem' on the screen below to connect my computer to GitHub. It's asking me to authorize it because it's my computer, and it won't appear after that.

As shown in the image below, the files that were local (on my computer) have been moved to the remote repository. In the future, if you work locally and commit in the same way as above, you will be able to manage your changes on GitHub in the same way.

But wait, what's a Stage and what's a Commit? Let's get some answers from WRTN, which is providing CHATGPT 4.0 for free.
About Stages and Commits
'Stage' and 'Commit' are key concepts for versioning your code.
Stage: 'Staging' means that Git uses the Changeto TrackingThe Fileto Preparewhich Steps. Here, 'Stage' is dictionary defined as 'Preparation steps', which means that if you modify a file, you put it in a 'stage' state so that Git can keep track of those changes. By doing so, Git will create a new Changes to filesto Include in the next 'Commit'to make Preparein the file.
Commit: 'Commit' is a ready Confirm changesThe 'Commit' step saves changes to the files in the 'Stage' state, which are recorded in the project's history. Each 'Commit' has a unique ID, which allows you to go back to the state of the code at a specific point in time.
So, to summarize the difference, Stage is where you track and prepare changes, and Commit is where you finalize the prepared changes and record them in history. These two steps are what version control of your code is all about.
It's a little bit complicated today, so thank you for your efforts.
LIFE2.0: IT Playground, TerryThank you.
All content on 'secondlife.lol' is protected by copyright law. Unauthorized reprinting, copying, distribution, etc. is prohibited.







