Skip to content
Snippets Groups Projects
Commit 15b1eaaf authored by Rob Swindell's avatar Rob Swindell :speech_balloon:
Browse files

Replace CVS Revision keywords with Git branch/hash

parent 37fbcb54
No related branches found
No related tags found
1 merge request!463MRC mods by Codefenix (2024-10-20)
Pipeline #1217 passed
......@@ -35,6 +35,8 @@
#include "js_rtpool.h"
#include "js_request.h"
#include "jsdebug.h"
#include "git_branch.h"
#include "git_hash.h"
#define DEFAULT_LOG_LEVEL LOG_INFO
#define DEFAULT_ERR_LOG_LVL LOG_WARNING
......@@ -56,7 +58,6 @@ FILE* confp;
FILE* errfp;
FILE* nulfp;
FILE* statfp;
char revision[16];
char compiler[32];
char* host_name=NULL;
char host_name_buf[128];
......@@ -84,11 +85,11 @@ BOOL debugger=FALSE;
void banner(FILE* fp)
{
fprintf(fp,"\n" PROG_NAME " v%s%c-%s (rev %s)%s - "
fprintf(fp,"\n" PROG_NAME " v%s%c-%s %s/%s%s - "
"Execute Synchronet JavaScript Module\n"
,VERSION,REVISION
,PLATFORM_DESC
,revision
,GIT_BRANCH, GIT_HASH
#ifdef _DEBUG
," Debug"
#else
......@@ -971,12 +972,11 @@ long js_exec(const char *fname, char** args)
,NULL,NULL,JSPROP_READONLY|JSPROP_ENUMERATE);
JS_DefineProperty(js_cx, js_glob, PROG_NAME_LC "_revision"
,STRING_TO_JSVAL(JS_NewStringCopyZ(js_cx,revision))
,STRING_TO_JSVAL(JS_NewStringCopyZ(js_cx, GIT_BRANCH "/" GIT_HASH))
,NULL,NULL,JSPROP_READONLY|JSPROP_ENUMERATE);
sprintf(rev_detail,PROG_NAME " %s%s "
safe_snprintf(rev_detail, sizeof(rev_detail), PROG_NAME " " GIT_BRANCH "/" GIT_HASH "%s "
"Compiled %s %s with %s"
,revision
#ifdef _DEBUG
," Debug"
#else
......@@ -1167,7 +1167,6 @@ int main(int argc, char **argv, char** env)
cb.gc_interval=JAVASCRIPT_GC_INTERVAL;
cb.auto_terminate=TRUE;
sscanf("$Revision: 1.217 $", "%*s %s", revision);
DESCRIBE_COMPILER(compiler);
memset(&scfg,0,sizeof(scfg));
......
......@@ -22,6 +22,8 @@
#include "sbbs.h"
#include "wordwrap.h"
#include "utf8.h"
#include "git_branch.h"
#include "git_hash.h"
#define MAX_LINES 10000
#define MAX_LINE_LEN (cols - 1)
......@@ -507,7 +509,7 @@ bool sbbs_t::writemsg(const char *fname, const char *top, char *subj, long mode,
if(console&CON_RAW_IN) {
if(editor != NULL)
*editor = "Synchronet writemsg $Revision: 1.175 $";
*editor = "Synchronet writemsg " GIT_BRANCH "/" GIT_HASH;
bprintf(text[EnterMsgNowRaw]
,(ulong)cfg.level_linespermsg[useron_level]*MAX_LINE_LEN);
......@@ -644,7 +646,7 @@ bool sbbs_t::writemsg(const char *fname, const char *top, char *subj, long mode,
else {
if(editor != NULL)
*editor = "Synchronet msgeditor $Revision: 1.175 $";
*editor = "Synchronet msgeditor " GIT_BRANCH "/" GIT_HASH;
buf[0]=0;
if(linesquoted || draft_restored) {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment