blob: 95f74f525ea0816ca3ac49d754b3a1ee898ae8bd (
plain) (
blame)
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
|
import future.utils as fu
cdef extern from "library/cpp/svnversion/svnversion.h":
cdef const char* GetVCS() except +;
cdef const char* GetProgramSvnVersion() except +;
cdef int GetProgramSvnRevision() except +;
cdef int GetArcadiaLastChangeNum() except +;
cdef const char* GetProgramCommitId() except +;
cdef const char* GetProgramHash() except +;
cdef const char* GetBranch() except +;
cdef const char* GetTag() except +;
cdef int GetArcadiaPatchNumber() except +;
def svn_version():
return fu.bytes_to_native_str(GetProgramSvnVersion())
def svn_revision():
return GetProgramSvnRevision()
def svn_last_revision():
return GetArcadiaLastChangeNum()
def commit_id():
return fu.bytes_to_native_str(GetProgramCommitId())
def hash():
return fu.bytes_to_native_str(GetProgramHash())
def svn_branch():
return fu.bytes_to_native_str(GetBranch())
def svn_tag():
return fu.bytes_to_native_str(GetTag())
def patch_number():
return GetArcadiaPatchNumber()
def vcs():
return fu.bytes_to_native_str(GetVCS())
|