programing

unbuntu에 최신 버전의 git를 설치하는 중

lastmoon 2023. 7. 1. 09:17
반응형

unbuntu에 최신 버전의 git를 설치하는 중

My Current git 버전 1.7.9.5...

Git 1.7.10 이상으로 업그레이드해야 합니다.git clone제대로 작동하도록 명령

나는 노력했다.sudo add-apt-repository ppa:git-core/ppa업그레이드를 위해 사용되었지만 다음과 같은 결과:

Traceback (most recent call last):
  File "/usr/bin/add-apt-repository", line 125, in <module>
    ppa_info = get_ppa_info_from_lp(user, ppa_name)
  File "/usr/lib/python2.7/dist-packages/softwareproperties/ppa.py", line 80, in get_ppa_info_from_lp
    curl.perform()
pycurl.error: (7, "couldn't connect to host")

최신 GIT를 설치하려면 어떻게 해야 합니까?

Ubuntu git 유지 관리자 은 그것을 위한 PPA를 가지고 있습니다.

ppa:git-core/ppa

그냥 하기:

sudo add-apt-repository ppa:git-core/ppa
sudo apt-get update
sudo apt-get install git

오류: 패키지를 찾을 수 없습니다.add-apt-repository

한다면add-apt-repository명령을 찾을 수 없습니다. 먼저 다음을 사용하여 명령을 설치하십시오.

sudo apt-get install software-properties-common

오류: 시작하지 못했습니다.dirmngr

오류가 표시되는 경우:

gpg: failed to start the dirmngr '/usr/bin/dirmngr': No such file or directory

그 다음, 설치dirmngr포함:

sudo apt install dirmngr --install-recommends

질문은 다음과 같습니다. "어떻게 해야 하나요?sudo add-apt-repository ppa:git-core/ppa명령이 실패합니다."

프록시 뒤에 있는 VM에서도 동일한 문제가 발생했습니다.다음 두 단계로 해결했습니다.

  1. 프록시 환경 변수 설정

    export http_proxy=http://<user>:<pwd>@<proxy_url>:<port_number>
    export https_proxy=http://<user>:<pwd>@<proxy_url>:<port_number>
    
  2. 실행add-apt-repositorysudo로 다시 명령합니다.-E사용자 환경을 보존하는 옵션:

    sudo -E add-apt-repository ppa:git-core/ppa
    

최신 버전의 Git를 업데이트하려면 아래 명령을 따르십시오.

sudo add-apt-repository ppa:git-core/ppa -y
sudo apt-get update
sudo apt-get install git -y
git --version

최신 버전의 Ubuntu에서 Git를 설치하거나 업데이트하려면 터미널에 following 명령을 입력하고 Enter(복귀)를 누릅니다.

sudo apt-get install git

Git 버전을 확인하기 위해.

git --version 

또는 슈퍼 수동 방식

git hub에서 git 소스를 다운로드한 다음

make prefix=/usr/local all
sudo make prefix=/usr/local install

https://www.digitalocean.com/community/tutorials/how-to-install-git-on-ubuntu-14-04

Ubuntu에 Git 설치

  1. sudo apt-get 업데이트
  2. sudo apt-get 설치 git
  3. sudo apt-get 설치 gitkit-gui

언급URL : https://stackoverflow.com/questions/19109542/installing-latest-version-of-git-in-ubuntu

반응형