Faker C++
Loading...
Searching...
No Matches
Git.h
Go to the documentation of this file.
1#pragma once
2
3#include <optional>
4#include <string>
5
6#include "faker-cxx/Export.h"
7#include "faker-cxx/types/Country.h"
8
9namespace faker::git
10{
11struct FAKER_CXX_EXPORT Author
12{
13 std::string name;
14 std::string email;
15};
16
27FAKER_CXX_EXPORT std::string branch(unsigned maxIssueNum = 100);
28
39FAKER_CXX_EXPORT std::string commitDate(unsigned years = 15);
40
58FAKER_CXX_EXPORT std::string commitEntry(std::optional<unsigned> dateYears = std::nullopt,
59 std::optional<unsigned> shaLength = std::nullopt, Country country = Country::England);
60
70FAKER_CXX_EXPORT std::string commitMessage();
71
83FAKER_CXX_EXPORT std::string commitSha(unsigned length = 40);
84}
Definition Git.h:10
FAKER_CXX_EXPORT std::string commitMessage()
Generates a random commit message.
FAKER_CXX_EXPORT std::string commitSha(unsigned length=40)
Returns a random SHA hash.
FAKER_CXX_EXPORT std::string commitEntry(std::optional< unsigned > dateYears=std::nullopt, std::optional< unsigned > shaLength=std::nullopt, Country country=Country::England)
Generates a random commit entry in form of string.
FAKER_CXX_EXPORT std::string branch(unsigned maxIssueNum=100)
Returns a random branch name.
FAKER_CXX_EXPORT std::string commitDate(unsigned years=15)
Generates a random date in form of string.
Definition Git.h:12
std::string name
Definition Git.h:13
std::string email
Definition Git.h:14