| 
									
										
										
										
											2018-02-08 21:28:33 -05:00
										 |  |  | #include "revision_utils.hpp"
 | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | #include <cstring>
 | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | #include <QCoreApplication>
 | 
					
						
							|  |  |  | #include <QRegularExpression>
 | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | QString revision (QString const& svn_rev_string) | 
					
						
							|  |  |  | { | 
					
						
							| 
									
										
										
										
											2018-07-13 22:22:16 -04:00
										 |  |  |   return ""; | 
					
						
							| 
									
										
										
										
											2018-02-08 21:28:33 -05:00
										 |  |  | } | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | QString version (bool include_patch) | 
					
						
							|  |  |  | { | 
					
						
							|  |  |  | #if defined (CMAKE_BUILD)
 | 
					
						
							|  |  |  |   QString v {WSJTX_STRINGIZE (WSJTX_VERSION_MAJOR) "." WSJTX_STRINGIZE (WSJTX_VERSION_MINOR)}; | 
					
						
							|  |  |  |   if (include_patch) | 
					
						
							|  |  |  |     { | 
					
						
							|  |  |  |       v += "." WSJTX_STRINGIZE (WSJTX_VERSION_PATCH) | 
					
						
							| 
									
										
										
										
											2018-07-09 22:02:39 -04:00
										 |  |  | #if 0
 | 
					
						
							| 
									
										
										
										
											2018-02-08 21:28:33 -05:00
										 |  |  | # if defined (WSJTX_RC)
 | 
					
						
							|  |  |  |         + "-rc" WSJTX_STRINGIZE (WSJTX_RC) | 
					
						
							|  |  |  | # endif
 | 
					
						
							| 
									
										
										
										
											2018-07-09 22:02:39 -04:00
										 |  |  | #endif
 | 
					
						
							| 
									
										
										
										
											2018-02-08 21:28:33 -05:00
										 |  |  |         ; | 
					
						
							|  |  |  |     } | 
					
						
							|  |  |  | #else
 | 
					
						
							|  |  |  |   QString v {"Not for Release"}; | 
					
						
							|  |  |  | #endif
 | 
					
						
							| 
									
										
										
										
											2018-07-06 02:53:31 -04:00
										 |  |  | 
 | 
					
						
							| 
									
										
										
										
											2018-02-08 21:28:33 -05:00
										 |  |  |   return v; | 
					
						
							|  |  |  | } | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | QString program_title (QString const& revision) | 
					
						
							|  |  |  | { | 
					
						
							| 
									
										
										
										
											2018-07-06 20:14:09 -04:00
										 |  |  |   QString id {"FT8Call de KN4CRD (v%1) a derivative of WSJT-X by K1JT"}; | 
					
						
							| 
									
										
										
										
											2018-07-06 02:53:31 -04:00
										 |  |  |   return id.arg(QCoreApplication::applicationVersion ()); | 
					
						
							| 
									
										
										
										
											2018-02-08 21:28:33 -05:00
										 |  |  | } |