Skip to content

Commit

Permalink
3.0.0
Browse files Browse the repository at this point in the history
  • Loading branch information
psemiletov committed Apr 8, 2023
1 parent ba8464c commit a143d22
Show file tree
Hide file tree
Showing 4 changed files with 23 additions and 20 deletions.
2 changes: 1 addition & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ if(USE_CLANG)
endif(USE_CLANG)


project (logfilegen VERSION 2.3.0 LANGUAGES CXX)
project (logfilegen VERSION 3.0.0 LANGUAGES CXX)
add_definitions(-DVERSION_NUMBER="\\"${PROJECT_VERSION_MAJOR}.${PROJECT_VERSION_MINOR}.${PROJECT_VERSION_PATCH}\\"")


Expand Down
4 changes: 4 additions & 0 deletions ChangeLog
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
+ multithread support
* win and mac support fixed
- prometheus_cpp library support (logfilegen built-in code covers all needs)

+ CMake support optimization
+ HaikuOS support (compile with make --makefile=Makefile.Haiku
+ Mac ARM support (compile with make --makefile=Makefile.macarm
Expand Down
7 changes: 3 additions & 4 deletions NEWS
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
+ CMake support optimization
+ HaikuOS support (compile with make --makefile=Makefile.Haiku
+ Mac ARM support (compile with make --makefile=Makefile.macarm
* randomization engine take less resources
logfilegen 3.0.0

This release introduces the multithread support (performance improved), fixes mac and win building, and many more.
30 changes: 15 additions & 15 deletions main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -41,11 +41,10 @@


#ifndef VERSION_NUMBER
#define VERSION_NUMBER "2.3.0"
#define VERSION_NUMBER "3.0.0"
#endif



#define RED "\x1B[31m"
#define GRN "\x1B[32m"
#define YEL "\x1B[33m"
Expand Down Expand Up @@ -78,7 +77,6 @@ std::string find_config_in_paths (const std::string &fname)
}



void show_version()
{
std::cout << "logfilegen v." << VERSION_NUMBER << std::endl;
Expand All @@ -90,19 +88,21 @@ void show_help()
printf (GRN "logfilegen v%s by Peter Semiletov\n" RESET, VERSION_NUMBER);
printf (YEL "Please read the full Manual at https://psemiletov.github.io/logfilegen/\n" RESET);
printf (MAG "Parameters short list:\n");
printf (CYN"--pure" RESET " - Generate lines in memory or output them to the log file, disabled by default.\n");
printf (CYN"--benchmark" RESET " - Perfrom benchmark to test logs generation performance of the current system, disabled by default.\n");
printf (CYN"--duration" RESET " - Logs generation duration in seconds, default is 0 and it means unlimited.\n");
printf (CYN"--rate" RESET " - Generation speed, default is 0 and it means unlimited.\n");
printf (CYN"--lines" RESET " - Generate number of lines and exit, overrides duration.\n");
printf (CYN"--size" RESET " - Generate specific log file size and exit, overrides duration and lines. Default units are bytes and we can specify k/m/g etc.\n");
printf (CYN"--template" RESET " - Template file name that is used for log file generation. See documentation for more details about template file format.\n");
printf (CYN"--logfile" RESET " - File name for the resulting logfile. We can also use 'stdout' to output lines to the console.\n");
printf (CYN"--logsize" RESET " - Maximum log file size, if exceeded, the log file rotation will happen. Default is 16m, default units are bytes and we can specify k/m/g\n");
printf (CYN"--pure" RESET " - Generate lines in memory or output them to the log file, disabled by default.\n");
printf (CYN"--benchmark" RESET " - Perfrom benchmark to test logs generation performance of the current system, disabled by default.\n");
printf (CYN"--duration=n" RESET " - Logs generation duration in seconds, default is 0 and it means unlimited.\n");
printf (CYN"--rate=n" RESET " - Generation speed, default is 0 and it means unlimited.\n");
printf (CYN"--lines=n" RESET " - Generate number of lines and exit, overrides duration.\n");
printf (CYN"--size=n" RESET " - Generate specific log file size and exit, overrides duration and lines. Default units are bytes and we can specify k/m/g etc.\n");
printf (CYN"--template=s" RESET " - Template file name that is used for log file generation. See documentation for more details about template file format.\n");
printf (CYN"--logfile=s" RESET " - File name for the resulting logfile. We can also use 'stdout' to output lines to the console.\n");
printf (CYN"--logsize=n" RESET " - Maximum log file size, if exceeded, the log file rotation will happen. Default is 16m, default units are bytes and we can specify k/m/g\n");
printf ("etc.\n");
printf (CYN"--logcount" RESET " - Number of the files to retain during rotation.\n");
printf (CYN"--gzip" RESET " - Use external gzip to compress rotated log files, disabled by default.\n");
printf (CYN"--debug" RESET " - Enable or disable debug, disabled by default.\n");
printf (CYN"--logcount=n" RESET " - Number of the files to retain during rotation.\n");
printf (CYN"--gzip" RESET " - Use external gzip to compress rotated log files, disabled by default.\n");
printf (CYN"--debug" RESET " - Enable or disable debug, disabled by default.\n");
printf (CYN"--threads=n" RESET " - Number of threads in unrated mode, 2 by default.\n");

printf ("\n");
printf (MAG "Examples:\n" RESET);
printf ("\n");
Expand Down

0 comments on commit a143d22

Please sign in to comment.