항해99 TIL 33일차_061022

열공이·2022년 6월 10일
0

Git 에러

  1. fatal: not a valid object name: 'main'
    => 커밋을 하면 된다.

https://somjang.tistory.com/entry/Git-fatal-Not-a-valid-object-name-master-%ED%95%B4%EA%B2%B0%EB%B0%A9%EB%B2%95

  1. git push origin main 치니까 에러가 떴다
    remote: Invalid username or password.
    fatal: Authentication failed for 'https://github.com/nowlcode/hanghae-spring-w1.git/'

그래서 git remote show origin 쓰고 다시 git push origin main 치니까 username for, password for라고 하는 부분들이 나와서 내 닉네임 쓰고 패스워드에 토큰 썼더니 해결되었다.

또 git config --list하면 git과 github연결 잘 된 걸 볼 수 있다.

https://valuelog.tistory.com/54

  1. 예전에 git branch하면 현재 git branch들을 보여주는 대신 pager로 따로 가서 보여주는 방식이였다. 그런데 그렇게 되면 또 q 누르고 귀찮게 되서 git config --global --replace-all core.pager "less -F -X"라서 설정해두니 제대로 브랜치명들이 밑에 있는 것처럼 나왔다.

Java git:(main) git branch
*main
young

https://intrepidgeeks.com/tutorial/the-git-branch-command-run-result-page-is-not-displayed-qdc

profile
프로그래머가 되자! 열공!

0개의 댓글