Questions tagged [gitpython]

GitPython is a python library used to interact with Git repositories

GitPython is a python library used to interact with Git repositories, providing object model access.

439 questions
-1
votes
2 answers

GitPython: Pull/Checkout from remote, discard local changes

For deploying files to some target (Windows) computers, I wanted to create a Python module I can feed with the necessary parameters. The module should then check if the specified repo exists in the outputpath. a) If it doesn't exist: clone the…
azev
  • 11
  • 5
-1
votes
2 answers

call python code of different git branch other than the current repository without switching branch

So, basically I have 2 versions of a project and for some users, I want to use the latest version while for others, I want to use older version. Both of them have same file names and multiple users will use it simultaneously. To accomplish this, I…
proprius
  • 422
  • 6
  • 16
-2
votes
2 answers

Python: sorted - not sorting gitPython branch objects by default?

I have this method: def filter_branches_by_names(self, names, exclude=False): """Filter branches list using names list. Args: names (list): names list to use as filter condition. exclude (bool): If set to False,…
Andrius
  • 15,319
  • 31
  • 125
  • 205
-4
votes
1 answer

I would like to ask how to solve this problem

Traceback (most recent call last): File "/home/shi/anaconda3/lib/python3.6/site-packages/git/__init__.py", line 83, in refresh() File "/home/shi/anaconda3/lib/python3.6/site-packages/git/__init__.py", line 73, in refresh if not…
1 2 3
29
30