Skip to content

Missing definition in API documentation: repo.git #1405

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
cowlinator opened this issue Jan 29, 2022 · 2 comments
Open

Missing definition in API documentation: repo.git #1405

cowlinator opened this issue Jan 29, 2022 · 2 comments

Comments

@cowlinator
Copy link

cowlinator commented Jan 29, 2022

API documentation at https://gitpython.readthedocs.io/en/stable/reference.html#git.repo.base.Repo.git does not describe repo.git. What type of object is it? What are its function definitions?

I'm looking at modifying code that uses repo.git.describe() (which I would think would be a popular function and thus definitely documented), but I can find no function definition in the api, and I dont' know what arguments it accepts.

@Byron
Copy link
Member

Byron commented Jan 30, 2022

Indeed, the field itself could use some documentation maybe along with some docs on how to use it.

It can't be documented as its functions are all 'virtual', they act as away to build a git command-line invocation, so repo.git.foo() is valid and causes git foo to be called.

@cowlinator
Copy link
Author

cowlinator commented Jan 31, 2022

@Byron , great.

What you wrote here is exactly the information that needs to be in the document at https://gitpython.readthedocs.io/en/stable/reference.html

git= None

repo.git is a virtual object which represents a git command-line invocation.  See [documentation on how to use it](https://gitpython.readthedocs.io/en/stable/tutorial.html#using-git-directly).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Development

No branches or pull requests

2 participants