![[IntelliJ] IntelliJ와 Github 연동](https://img1.daumcdn.net/thumb/R750x0/?scode=mtistory2&fname=https%3A%2F%2Fblog.kakaocdn.net%2Fdn%2Fdg6cU4%2Fbtslat95cci%2FWNQSMFUqwci5zzCfoBkxi0%2Fimg.png)
[IntelliJ] IntelliJ와 Github 연동삽질/사이드 프로젝트2023. 6. 25. 18:55
Table of Contents
728x90
728x90
IntelliJ Git 설정
Git 경로 설정
File - Settings - Git에서 깃 경로 설정
보통은 설치하면 자동으로 경로가 잡히는데, 깔려있지 않다면 Git을 설치하고 재시도 해보자.

GitHub 계정 연동
Add account 클릭 - Log in via GitHub 클릭



클릭하면 GitHub 로그인 - JetBrains에 권한 부여 후 연동이 완료됨
프로젝트 Git 연동
1. VCS - Enable Version Control Intergration 클릭 후 아래 화면처럼 나오면 OK 버튼 클릭

2. Git - Manage Remotes - Repository 주소 입력

3. Project 우클릭 - Git - Pull 진행
진행 시 빨간 색으로 없는 branch라고 나타날 시, Ctrl + F5를 눌려 Fetching 진행

만약 refusing to merge unrelated histories 에러가 발생하여 pull이 안된다면 아래의 명령어를 터미널에 입력.
git pull --allow-unrelated-histories REMOTE BRANCH
git pull --allow-unrelated-histories origin main
4. README.md 파일이 프로젝트에 추가된 것 확인 후 commit 탭에서 commit, push 진행

5. GitHub Repository 확인
728x90
300x250
@mag1c :: 꾸준히 재밌게
2023.04 ~ 백엔드 개발자의 기록
포스팅이 좋았다면 "좋아요❤️" 또는 "구독👍🏻" 해주세요!