- Notifications
You must be signed in to change notification settings - Fork 324
/
Copy pathfeatures.go
30 lines (22 loc) · 657 Bytes
/
features.go
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
package git
/*
#include <git2.h>
*/
import"C"
typeFeatureint
const (
// libgit2 was built with threading support
FeatureThreadsFeature=C.GIT_FEATURE_THREADS
// libgit2 was built with HTTPS support built-in
FeatureHTTPSFeature=C.GIT_FEATURE_HTTPS
// libgit2 was build with SSH support built-in
FeatureSSHFeature=C.GIT_FEATURE_SSH
// libgit2 was built with nanosecond support for files
FeatureNSecFeature=C.GIT_FEATURE_NSEC
)
// Features returns a bit-flag of Feature values indicating which features the
// loaded libgit2 library has.
funcFeatures() Feature {
features:=C.git_libgit2_features()
returnFeature(features)
}