Skip to content
Snippets Groups Projects
Commit 8563a66f authored by Christophe Geuzaine's avatar Christophe Geuzaine
Browse files

startup info log

parent fcd102ab
Branches
Tags
No related merge requests found
// $Id: Main.cpp,v 1.28 2001-05-30 13:53:50 geuzaine Exp $ // $Id: Main.cpp,v 1.29 2001-05-30 15:22:41 geuzaine Exp $
#include <signal.h> #include <signal.h>
#include <time.h> #include <time.h>
...@@ -25,12 +25,16 @@ GUI *WID = NULL; ...@@ -25,12 +25,16 @@ GUI *WID = NULL;
int main(int argc, char *argv[]){ int main(int argc, char *argv[]){
int i, nbf; int i, nbf;
char tmp[1000]=""; char cmdline[1000]="";
time_t now; time_t now;
// log the starting time // log some info
time(&now); time(&now);
for(i=0;i<argc;i++){
if(i) strcat(cmdline, " ");
strcat(cmdline, argv[i]);
}
// Gmsh default options // Gmsh default options
...@@ -81,10 +85,7 @@ int main(int argc, char *argv[]){ ...@@ -81,10 +85,7 @@ int main(int argc, char *argv[]){
// Non-interactive Gmsh // Non-interactive Gmsh
if(CTX.batch){ if(CTX.batch){
for(i=0;i<argc;i++){ Msg(DIRECT, "Command line : %s", cmdline);
strcat(tmp, argv[i]); strcat(tmp, " ");
}
Msg(DIRECT, "Command line : %s", tmp);
OpenProblem(CTX.filename); OpenProblem(CTX.filename);
if(yyerrorstate) if(yyerrorstate)
exit(1); exit(1);
...@@ -139,6 +140,8 @@ int main(int argc, char *argv[]){ ...@@ -139,6 +140,8 @@ int main(int argc, char *argv[]){
Msg(LOG_INFO, gmsh_host); Msg(LOG_INFO, gmsh_host);
Msg(LOG_INFO, gmsh_packager); Msg(LOG_INFO, gmsh_packager);
Msg(LOG_INFO, "Home directory : '%s'", CTX.home_dir); Msg(LOG_INFO, "Home directory : '%s'", CTX.home_dir);
Msg(LOG_INFO, "Launch date : %s", ctime(&now));
Msg(LOG_INFO, "Command line : '%s'", cmdline);
Msg(LOG_INFO, "-------------------------------------------------------"); Msg(LOG_INFO, "-------------------------------------------------------");
// Display the GUI immediately to have a quick "a la Windows" launch time // Display the GUI immediately to have a quick "a la Windows" launch time
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment