Skip to content

[error] fatal: 'origin' does not appear to be a git repository #4

Description

@mywnajsldkf

error

fatal: 'origin' does not appear to be a git repository
fatal: Could not read from remote repository.

Please make sure you have the correct access rights and the repository exists.

pull, push를 하는 도중에 원격 저장소 에러가 난 경우입니다.
원격 저장소에 origin/master가 없거나 remote repository 설정이 잘못되어있는 경우 나타나는 오류입니다.

기존에 연결되어있던 원격저장소 연결을 끊고 다시 연결하는 방식으로 해결해보겠습니다.

  1. 원격 저장소명 확인

스크린샷 2021-01-05 오후 11 15 14

- 원격저장소 주소 `https://github.com/Oasis-hackathon/2021-oasis-hackathon` 가 무척 길기 때문에 이에 `origin`이라는 별명을 붙였구나! 라고 생각하시면 됩니다.
  1. 기존 원격저장소 연결 삭제

스크린샷 2021-01-05 오후 11 19 20

git remote remove origin

스크린샷 2021-01-05 오후 11 19 41

git remote -v 확인 해 보았을 때 아무것도 나타나지 않음을 확인할 수 있습니다.

  1. 다시 연결

스크린샷 2021-01-05 오후 11 24 17

이번에는 원격저장소 주소(remote url)에 oasis라는 이름을 붙여서 다시 연결해보았습니다.
git remote -v로 확인해보니 잘 연결되었음을 확인할 수 있네요 👍

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions