git2wrapC++20 wrapper for libgit2 |
git clone git://git.dimitrijedobrota.com/git2wrap.git |
Log | Files | Refs | README | LICENSE | HACKING | CONTRIBUTING | CODE_OF_CONDUCT | BUILDING | |
libgit2.cpp (281B)
1 #include "git2wrap/libgit2.hpp" 2 3 #include "git2wrap/error.hpp" 4 5 namespace git2wrap 6 { 7 8 libgit2::libgit2() 9 { 10 if (m_cinit = git_libgit2_init(); m_cinit < 0) { 11 throw error<error_code_t::ERROR>(); 12 } 13 } 14 15 libgit2::~libgit2() 16 { 17 git_libgit2_shutdown(); 18 } 19 20 } // namespace git2wrap