Git 올리기
# 현재 상태 확인 (머지 중인지, 어떤 파일이 바뀌었는지)
git status
# (머지가 남은 경우만) 진행 중이던 머지를 커밋으로 마무리
git commit -m "Merge remote README"
# 변경된 파일·새 파일을 전부 스테이징 (.env 등 gitignore는 제외)
git add .
# add 잘 됐는지 다시 확인
git status
# 스테이징한 내용을 커밋 (로컬 저장)
git commit -m "Add KMA weather screen with ncst, hourly, and daily forecast"
# 원격 GitHub main 브랜치에 업로드
git push origin main // git 연결되있지않으면 로그인 창 생성
Git 내려받기(처음)
# 저장소 받기(처음만)
git clone https://github.com/ngeniusai94/yWheather.git
# .env는 깃에 없음 → 기존 PC에서 복사해서 이 폴더에 넣기
# 패키지 설치 후 실행
npm install //굳이해야하나
npx expo start
Git 내려받기
# GitHub에 있는 최신 코드를 이 폴더에 받아오기
git pull origin main
# 잘 받아졌는지 확인
git status
Git 최초
git init
git add .
git commit -m "Add yCard mobile layout preview"
git branch -M main
git remote add origin https://github.com/ngeniusai94/yCard.git
git push -u origin main
임시
cd /Users/doyeob/Doyeob/study/cursor/yCard
git add .
git commit -m "메시지"
git push yCardGit main
댓글