cmCTestGIT.h 1.4 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152
  1. /*============================================================================
  2. CMake - Cross Platform Makefile Generator
  3. Copyright 2000-2009 Kitware, Inc.
  4. Distributed under the OSI-approved BSD License (the "License");
  5. see accompanying file Copyright.txt for details.
  6. This software is distributed WITHOUT ANY WARRANTY; without even the
  7. implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
  8. See the License for more information.
  9. ============================================================================*/
  10. #ifndef cmCTestGIT_h
  11. #define cmCTestGIT_h
  12. #include "cmCTestGlobalVC.h"
  13. /** \class cmCTestGIT
  14. * \brief Interaction with git command-line tool
  15. *
  16. */
  17. class cmCTestGIT: public cmCTestGlobalVC
  18. {
  19. public:
  20. /** Construct with a CTest instance and update log stream. */
  21. cmCTestGIT(cmCTest* ctest, std::ostream& log);
  22. virtual ~cmCTestGIT();
  23. private:
  24. std::string GetWorkingRevision();
  25. virtual void NoteOldRevision();
  26. virtual void NoteNewRevision();
  27. virtual bool UpdateImpl();
  28. bool UpdateByPull();
  29. bool UpdateByCustom(std::string const& custom);
  30. bool UpdateInternal();
  31. void LoadRevisions();
  32. void LoadModifications();
  33. public: // needed by older Sun compilers
  34. // Parsing helper classes.
  35. class OneLineParser;
  36. class DiffParser;
  37. class CommitParser;
  38. friend class OneLineParser;
  39. friend class DiffParser;
  40. friend class CommitParser;
  41. };
  42. #endif