1. 윈도우에 git 설치
https://git-scm.com/download/win
Git - Downloading Package
Download for Windows Click here to download the latest (2.45.2) 32-bit version of Git for Windows. This is the most recent maintained build. It was released about 1 month ago, on 2024-06-03. Other Git for Windows downloads Standalone Installer 32-bit Git f
git-scm.com
사용자 설정
2. 리눅스에 git 설치
우분투 가상머신에 git을 설치한다.
git 버전 업데이트
$ sudo add-apt-repository ppa:git-core/ppa -y
$ sudo apt-get update
$ sudo apt-get install git -y
사용자 설정
3. vs code와 연동
폴더 생성후 cmd로 터미널 창 열기 -> code . (vscode실행) -> git init (깃 저장소 생성)
해당 폴더에 예시 파일 작성
4. 소스트리에 추가
폴더 안의 파일중 공유되지 않았으면 하는 파일은 .gitignore에 적어주면 된다.
https://git-scm.com/docs/gitignore
Git - gitignore Documentation
The optional configuration variable core.excludesFile indicates a path to a file containing patterns of file names to exclude, similar to $GIT_DIR/info/exclude. Patterns in the exclude file are used in addition to those in $GIT_DIR/info/exclude.
git-scm.com
5. 깃허브와 연동
설정에서 토큰 발급받기
자격증명 관리자에서 일반 자격증명을 추가한다.
소스트리와 연결
GitHub : 원격 저장소중 유명 / git과는 다름!!
pull request : merge할때 원격 저장소의내용(main branch) 에 들어가야하니까 확인 필요
Issue : 이슈 트레킹(jira와 비슷)
참고
Git - Reference
Reference
git-scm.com
https://dkswnkk.tistory.com/576
[git] Git - HEAD
Git Head 모든 브렌치에는 HEAD값이 존재하는데, HEAD는 브렌치의 마지막 커밋 즉 현재 속한 브랜치의 가장 최신 커밋을 의미합니다. 작업 트리에 변화를 주는 git 명령어들은 대부분 HEAD를 변경하는
dkswnkk.tistory.com
[Github] 우분투에서 깃허브 자동으로 로그인하게 설정하기 (자동 로그인)
안녕하세요 깃허브 사용 중, push 할때마다 로그인을 해야해서 너무 귀찮더라구요. 그래서 한 번 로그인을 해두면 로그인 과정을 진행하지 않아도 push가 되도록 설정하는 방법을 찾아왔습니다. gi
daechu.tistory.com
https://pinedance.github.io/blog/2019/05/29/Git-Credential
Git, Pull/Push할 때 id password 묻지 않게 하기
배경
pinedance.github.io
'SKT FLY AI > DevOps' 카테고리의 다른 글
DevOps - Jenkins(1) 설치 (0) | 2024.07.08 |
---|---|
DevOps - Github Actions (0) | 2024.07.05 |
DevOps - Flask (0) | 2024.07.05 |
DevOps - Docker 이론 (0) | 2024.07.04 |
DevOps - Linux(Ubuntu 가상머신 생성법) / hyper-V (0) | 2024.07.04 |