File: general.rst

package info (click to toggle)
python-pygit2 1.18.1-1
  • links: PTS, VCS
  • area: main
  • in suites: sid
  • size: 2,720 kB
  • sloc: ansic: 12,584; python: 9,337; sh: 205; makefile: 26
file content (82 lines) | stat: -rw-r--r-- 1,792 bytes parent folder | download | duplicates (5)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
**********************************************************************
General
**********************************************************************

.. contents:: Contents
   :local:


Top level constants and exceptions from the library.

Version
=========

The following constants provide information about the version of the libgit2
library that has been built against. The version number has a
``MAJOR.MINOR.REVISION`` format.

.. py:data:: LIBGIT2_VER_MAJOR

   Integer value of the major version number. For example, for the version
   ``0.26.0``::

      >>> print(pygit2.LIBGIT2_VER_MAJOR)
      0

.. py:data:: LIBGIT2_VER_MINOR

   Integer value of the minor version number. For example, for the version
   ``0.26.0``::

      >>> print(pygit2.LIBGIT2_VER_MINOR)
      26

.. py:data:: LIBGIT2_VER_REVISION

   Integer value of the revision version number. For example, for the version
   ``0.26.0``::

      >>> print(pygit2.LIBGIT2_VER_REVISION)
      0

.. py:data:: LIBGIT2_VER

   Tuple value of the revision version numbers. For example, for the version
   ``0.26.0``::

      >>> print(pygit2.LIBGIT2_VER)
      (0, 26, 0)

.. py:data:: LIBGIT2_VERSION

   The libgit2 version number as a string::

      >>> print(pygit2.LIBGIT2_VERSION)
      '0.26.0'

Options
=========

.. autofunction:: pygit2.option

Exceptions
==========

.. autoexception:: pygit2.GitError
   :members:
   :show-inheritance:
   :undoc-members:

.. autoexception:: pygit2.AlreadyExistsError
   :members:
   :show-inheritance:
   :undoc-members:

Exception when trying to create an object (reference, etc) that already exists.

.. autoexception:: pygit2.InvalidSpecError
   :members:
   :show-inheritance:
   :undoc-members:

Exception when an input specification such as a reference name is invalid.