gitpython-developers / GitPython

GitPython is a python library used to interact with Git repositories.

Home Page:http://gitpython.readthedocs.org

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

【remote().exist()】 exception when lack remote section in config file

Im-Asher opened this issue · comments

i wanna to judge remote whether exist ,
the function that [remote().exist()] has exception【ValueError】,
check config file then found lack remote section;

operation:👇
if not self.repo.remote().exist():
self.repo.create_remote("origin",self.repo_url)