2022-10-19

【Linux】CentOS 7 安裝 Git2

CentOS 7Git 版本為 1.8.x,若想使用 Git2,(例如想開發學習 Flutter 就必須更新到 Git2)必須另尋第三方的套件庫。


先移除舊版 git
  1.  
  2. [root]# yum remove git*
  3.  


引入套件庫,目前有 2 個較多人採用的套件庫, 1 個是社群(IUS),一個是美國的資訊顧問公司(Endpoint)
  1.  
  2. # IUS 套件庫
  3. [root]# yum install install https://repo.ius.io/ius-release-el7.rpm
  4.  
  5. # Endpoint 套件庫
  6. # 本筆記採用 Endpoint 套件庫
  7. [root]# yum install https://packages.endpointdev.com/rhel/7/os/x86_64/endpoint-repo.x86_64.rpm
  8.  

安裝 git2
  1.  
  2. # 很神奇,自動安裝 Endpoint 的,而不是 CentOS7 的 git
  3. [root]# yum install git
  4.  


沒有留言:

張貼留言