From 922e31f7e45bf3dfb5ef3ef92ca971fe3d03f76f Mon Sep 17 00:00:00 2001 From: Magnus Lundborg Date: Wed, 24 Apr 2024 16:00:30 +0000 Subject: [PATCH] Fix tool names (e.g., g_energy to gmx energy) in some commands Fixes #5074 --- docs/reference-manual/file-formats.rst | 2 +- docs/release-notes/2023/2023.5.rst | 8 ++++++++ src/gromacs/gmxana/gmx_anaeig.cpp | 5 +++-- src/gromacs/gmxana/gmx_bar.cpp | 2 +- src/gromacs/gmxana/gmx_chi.cpp | 4 ++-- src/gromacs/gmxana/gmx_density.cpp | 2 +- src/gromacs/gmxana/gmx_energy.cpp | 6 +++--- src/gromacs/gmxana/gmx_h2order.cpp | 2 +- src/gromacs/gmxana/gmx_hbond.cpp | 2 +- src/gromacs/gmxana/gmx_hydorder.cpp | 2 +- src/gromacs/gmxana/gmx_make_edi.cpp | 9 +++++---- src/gromacs/gmxana/gmx_mindist.cpp | 2 +- src/gromacs/gmxana/gmx_order.cpp | 2 +- src/gromacs/gmxana/gmx_potential.cpp | 2 +- src/gromacs/gmxana/gmx_wham.cpp | 2 +- src/gromacs/gmxana/gmx_xpm2ps.cpp | 2 +- src/gromacs/mdlib/energyoutput.cpp | 2 +- src/gromacs/mdlib/mdebin_bar.cpp | 2 +- src/gromacs/mdlib/mdebin_bar.h | 2 +- src/gromacs/tools/eneconv.cpp | 4 ++-- 20 files changed, 37 insertions(+), 27 deletions(-) diff --git a/docs/reference-manual/file-formats.rst b/docs/reference-manual/file-formats.rst index 049de7f6ae2..6cdd35e1e53 100644 --- a/docs/reference-manual/file-formats.rst +++ b/docs/reference-manual/file-formats.rst @@ -877,7 +877,7 @@ The C-comment delimiters and the colon in the extra fields are optional. :: /* XPM */ - /* This matrix is generated by g_rms. */ + /* This matrix is generated by gmx rms. */ /* title: "Backbone RMSD matrix" */ /* legend: "RMSD (nm)" */ /* x-label: "Time (ps)" */ diff --git a/docs/release-notes/2023/2023.5.rst b/docs/release-notes/2023/2023.5.rst index cd54fff8397..7fc86bee422 100644 --- a/docs/release-notes/2023/2023.5.rst +++ b/docs/release-notes/2023/2023.5.rst @@ -110,6 +110,14 @@ the output group names had empty prefix). :issue:`5050` +Fixed references to old tool names in some commands +""""""""""""""""""""""""""""""""""""""""""""""""""" + +There were references to old tool names, e.g., g_energy and g_bar in some +commands. + +:issue:`5074` + Fixes that affect portability ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ diff --git a/src/gromacs/gmxana/gmx_anaeig.cpp b/src/gromacs/gmxana/gmx_anaeig.cpp index aaa0c48493c..7739beaca90 100644 --- a/src/gromacs/gmxana/gmx_anaeig.cpp +++ b/src/gromacs/gmxana/gmx_anaeig.cpp @@ -1317,10 +1317,11 @@ int gmx_anaeig(int argc, char* argv[]) if (xref1 == nullptr) { printf("\nNote: the structure in %s should be the same\n" - " as the one used for the fit in g_covar\n", + " as the one used for the fit in gmx covar\n", topfile); } - printf("\nSelect the index group that was used for the least squares fit in g_covar\n"); + printf("\nSelect the index group that was used for the least squares fit in gmx " + "covar\n"); get_index(atoms, indexfile, 1, &nfit, &ifit, &grpname); snew(w_rls, atoms->nr); diff --git a/src/gromacs/gmxana/gmx_bar.cpp b/src/gromacs/gmxana/gmx_bar.cpp index 3901729f3f2..eaa4b7da031 100644 --- a/src/gromacs/gmxana/gmx_bar.cpp +++ b/src/gromacs/gmxana/gmx_bar.cpp @@ -1150,7 +1150,7 @@ static barres_t* barres_list_create(sim_data_t* sd, int* nres, gmx_bool use_dhdl gmx_fatal(FARGS, "There is no path between the states X & Y below that is covered by foreign " "lambdas:\ncannot proceed with BAR.\nUse thermodynamic integration of dH/dl " - "by calculating the averages of dH/dl\nwith g_analyze and integrating " + "by calculating the averages of dH/dl\nwith gmx analyze and integrating " "them.\nAlternatively, use the -extp option if (and only if) the " "Hamiltonian\ndepends linearly on lambda, which is NOT normally the " "case.\n\n%s\n%s\n", diff --git a/src/gromacs/gmxana/gmx_chi.cpp b/src/gromacs/gmxana/gmx_chi.cpp index 82629e343d0..62d6a6ceaa9 100644 --- a/src/gromacs/gmxana/gmx_chi.cpp +++ b/src/gromacs/gmxana/gmx_chi.cpp @@ -1179,7 +1179,7 @@ static void order_params(FILE* log, } fp = gmx_ffopen(pdbfn, "w"); - fprintf(fp, "REMARK generated by g_chi\n"); + fprintf(fp, "REMARK generated by gmx chi\n"); fprintf(fp, "REMARK " "B-factor field contains negative of dihedral order parameters\n"); @@ -1430,7 +1430,7 @@ int gmx_chi(int argc, char* argv[]) { efXVG, "-jc", "Jcoupling", ffWRITE }, { efXVG, "-corr", "dihcorr", ffOPTWR }, { efLOG, "-g", "chi", ffWRITE }, - /* add two more arguments copying from g_angle */ + /* add two more arguments copying from gmx angle */ { efXVG, "-ot", "dihtrans", ffOPTWR }, { efXVG, "-oh", "trhisto", ffOPTWR }, { efXVG, "-rt", "restrans", ffOPTWR }, diff --git a/src/gromacs/gmxana/gmx_density.cpp b/src/gromacs/gmxana/gmx_density.cpp index 975d0ccc625..332bb1501fa 100644 --- a/src/gromacs/gmxana/gmx_density.cpp +++ b/src/gromacs/gmxana/gmx_density.cpp @@ -667,7 +667,7 @@ int gmx_density(int argc, char* argv[]) int** index; /* indices for all groups */ t_filenm fnm[] = { - /* files for g_density */ + /* files for gmx density */ { efTRX, "-f", nullptr, ffREAD }, { efNDX, nullptr, nullptr, ffOPTRD }, { efTPR, nullptr, nullptr, ffREAD }, diff --git a/src/gromacs/gmxana/gmx_energy.cpp b/src/gromacs/gmxana/gmx_energy.cpp index 99c25166383..a86688b52d6 100644 --- a/src/gromacs/gmxana/gmx_energy.cpp +++ b/src/gromacs/gmxana/gmx_energy.cpp @@ -821,10 +821,10 @@ if (tt != NOTSET) fprintf(fp, "\nTemperature dependent fluctuation properties at T = %g.\n", tt); fprintf(fp, "\nHeat capacities obtained from fluctuations do *not* include\n"); fprintf(fp, "quantum corrections. If you want to get a more accurate estimate\n"); - fprintf(fp, "please use the g_dos program.\n\n"); + fprintf(fp, "please use the gmx dos program.\n\n"); fprintf(fp, "WARNING: Please verify that your simulations are converged and perform\n" - "a block-averaging error analysis (not implemented in g_energy yet)\n"); + "a block-averaging error analysis (not implemented in gmx energy yet)\n"); if (debug != nullptr) { @@ -1502,7 +1502,7 @@ static void do_dhdl(t_enxframe* fr, call open_dhdl to open the file */ /* TODO this is an ugly hack that needs to be fixed: this will only work if the order of data is always the same and if we're - only using the g_energy compiled with the mdrun that produced + only using the gmx energy compiled with the mdrun that produced the ener.edr. */ *fp_dhdl = open_dhdl(filename, ir, oenv); } diff --git a/src/gromacs/gmxana/gmx_h2order.cpp b/src/gromacs/gmxana/gmx_h2order.cpp index f4e609346ee..12ae75f9882 100644 --- a/src/gromacs/gmxana/gmx_h2order.cpp +++ b/src/gromacs/gmxana/gmx_h2order.cpp @@ -313,7 +313,7 @@ int gmx_h2order(int argc, char* argv[]) *micelle = nullptr; gmx_bool bMicel = FALSE; /* think we're a micel */ t_filenm fnm[] = { - /* files for g_order */ + /* files for gmx order */ { efTRX, "-f", nullptr, ffREAD }, /* trajectory file */ { efNDX, nullptr, nullptr, ffREAD }, /* index file */ { efNDX, "-nm", nullptr, ffOPTRD }, /* index with micelle atoms */ diff --git a/src/gromacs/gmxana/gmx_hbond.cpp b/src/gromacs/gmxana/gmx_hbond.cpp index ae1777cf96e..f7f41bb0190 100644 --- a/src/gromacs/gmxana/gmx_hbond.cpp +++ b/src/gromacs/gmxana/gmx_hbond.cpp @@ -414,7 +414,7 @@ static int donor_index_function(t_donors* d, int grp, int i, const char* file, i static gmx_bool isInterchangable(HydrogenBondData* hb, int d, int a, int grpa, int grpd) { - /* g_hbond doesn't allow overlapping groups */ + /* gmx hbond doesn't allow overlapping groups */ if (grpa != grpd) { return FALSE; diff --git a/src/gromacs/gmxana/gmx_hydorder.cpp b/src/gromacs/gmxana/gmx_hydorder.cpp index bd426f95be2..0817e99113d 100644 --- a/src/gromacs/gmxana/gmx_hydorder.cpp +++ b/src/gromacs/gmxana/gmx_hydorder.cpp @@ -627,7 +627,7 @@ int gmx_hydorder(int argc, char* argv[]) }; t_filenm fnm[] = { - /* files for g_order */ + /* files for gmx order */ { efTRX, "-f", nullptr, ffREAD }, /* trajectory file */ { efNDX, "-n", nullptr, ffREAD }, /* index file */ { efTPR, "-s", nullptr, ffREAD }, /* topology file */ diff --git a/src/gromacs/gmxana/gmx_make_edi.cpp b/src/gromacs/gmxana/gmx_make_edi.cpp index 364255275db..87b0b70eece 100644 --- a/src/gromacs/gmxana/gmx_make_edi.cpp +++ b/src/gromacs/gmxana/gmx_make_edi.cpp @@ -1029,15 +1029,16 @@ int gmx_make_edi(int argc, char* argv[]) { if (bFit1) { - /* if g_covar used different coordinate groups to fit and to do the PCA */ + /* if gmx covar used different coordinate groups to fit and to do the PCA */ printf("\nNote: the structure in %s should be the same\n" - " as the one used for the fit in g_covar\n", + " as the one used for the fit in gmx covar\n", ftp2fn(efTPS, NFILE, fnm)); - printf("\nSelect the index group that was used for the least squares fit in g_covar\n"); + printf("\nSelect the index group that was used for the least squares fit in gmx " + "covar\n"); } else { - printf("\nNote: Apparently no fitting was done in g_covar.\n" + printf("\nNote: Apparently no fitting was done in gmx covar.\n" " However, you need to select a reference group for fitting in mdrun\n"); } get_index(atoms, indexfile, 1, &nfit, &ifit, &grpname); diff --git a/src/gromacs/gmxana/gmx_mindist.cpp b/src/gromacs/gmxana/gmx_mindist.cpp index bb5ea0e7c46..cc1d62c25e2 100644 --- a/src/gromacs/gmxana/gmx_mindist.cpp +++ b/src/gromacs/gmxana/gmx_mindist.cpp @@ -83,7 +83,7 @@ periodic_dist(PbcType pbcType, matrix box, rvec x[], int n, const int index[], r } else { - gmx_fatal(FARGS, "pbc = %s is not supported by g_mindist", c_pbcTypeNames[pbcType].c_str()); + gmx_fatal(FARGS, "pbc = %s is not supported by gmx mindist", c_pbcTypeNames[pbcType].c_str()); } nshift = 0; diff --git a/src/gromacs/gmxana/gmx_order.cpp b/src/gromacs/gmxana/gmx_order.cpp index 59b3512e2c9..5df9a4858f9 100644 --- a/src/gromacs/gmxana/gmx_order.cpp +++ b/src/gromacs/gmxana/gmx_order.cpp @@ -994,7 +994,7 @@ int gmx_order(int argc, char* argv[]) PbcType pbcType; /* type of periodic boundary conditions */ t_filenm fnm[] = { - /* files for g_order */ + /* files for gmx order */ { efTRX, "-f", nullptr, ffREAD }, /* trajectory file */ { efNDX, "-n", nullptr, ffREAD }, /* index file */ { efNDX, "-nr", nullptr, ffOPTRD }, /* index for radial axis calculation */ diff --git a/src/gromacs/gmxana/gmx_potential.cpp b/src/gromacs/gmxana/gmx_potential.cpp index b337ed5c583..31a352fed34 100644 --- a/src/gromacs/gmxana/gmx_potential.cpp +++ b/src/gromacs/gmxana/gmx_potential.cpp @@ -604,7 +604,7 @@ int gmx_potential(int argc, char* argv[]) int ncenter; /* size of centering group */ int** index; /* indices for all groups */ t_filenm fnm[] = { - /* files for g_order */ + /* files for gmx order */ { efTRX, "-f", nullptr, ffREAD }, /* trajectory file */ { efNDX, nullptr, nullptr, ffREAD }, /* index file */ { efTPR, nullptr, nullptr, ffREAD }, /* topology file */ diff --git a/src/gromacs/gmxana/gmx_wham.cpp b/src/gromacs/gmxana/gmx_wham.cpp index 9785458d441..05fc7c29805 100644 --- a/src/gromacs/gmxana/gmx_wham.cpp +++ b/src/gromacs/gmxana/gmx_wham.cpp @@ -1081,7 +1081,7 @@ static void create_synthetic_histo(t_UmbrellaWindow* synthWindow, "autocorrelation times (ACTs) are required. Otherwise the statistical error\n" "cannot be predicted. You have 3 options:\n" "1) Make gmx wham estimate the ACTs (options -ac and -acsig).\n" - "2) Calculate the ACTs by yourself (e.g. with g_analyze) and provide them\n"); + "2) Calculate the ACTs by yourself (e.g. with gmx analyze) and provide them\n"); std::strcat(errstr, " with option -iiact for all umbrella windows.\n" "3) If all ACTs are identical and know, you can define them with -bs-tau.\n" diff --git a/src/gromacs/gmxana/gmx_xpm2ps.cpp b/src/gromacs/gmxana/gmx_xpm2ps.cpp index 233426792ed..fe3db0d0148 100644 --- a/src/gromacs/gmxana/gmx_xpm2ps.cpp +++ b/src/gromacs/gmxana/gmx_xpm2ps.cpp @@ -1203,7 +1203,7 @@ static void write_combined_matrix(int ecombine, { gmx_fatal(FARGS, "Could not extract real data from %s xpm matrices. Note that, e.g.,\n" - "g_rms and g_mdmat provide such data.\n", + "gmx rms and gmx mdmat provide such data.\n", (nullptr == rmat1 && nullptr == rmat2) ? "both" : "one of the"); } rlo = 1e38; diff --git a/src/gromacs/mdlib/energyoutput.cpp b/src/gromacs/mdlib/energyoutput.cpp index 6fbd4238b0e..224345a0f87 100644 --- a/src/gromacs/mdlib/energyoutput.cpp +++ b/src/gromacs/mdlib/energyoutput.cpp @@ -785,7 +785,7 @@ FILE* open_dhdl(const char* filename, const t_inputrec* ir, const gmx_output_env if (fep->n_lambda > 0) { - /* g_bar has to determine the lambda values used in this simulation + /* gmx bar has to determine the lambda values used in this simulation * from this xvg legend. */ diff --git a/src/gromacs/mdlib/mdebin_bar.cpp b/src/gromacs/mdlib/mdebin_bar.cpp index 880fd90817e..f151429c6d5 100644 --- a/src/gromacs/mdlib/mdebin_bar.cpp +++ b/src/gromacs/mdlib/mdebin_bar.cpp @@ -482,7 +482,7 @@ t_mde_delta_h_coll::t_mde_delta_h_coll(const t_inputrec& inputrec) /* now initialize them */ /* the order, for now, must match that of the dhdl.xvg file because of - how g_energy -odh is implemented */ + how gmx energy -odh is implemented */ n = 0; if (bExpanded) { diff --git a/src/gromacs/mdlib/mdebin_bar.h b/src/gromacs/mdlib/mdebin_bar.h index f1c4991bb96..77e17f8f5ab 100644 --- a/src/gromacs/mdlib/mdebin_bar.h +++ b/src/gromacs/mdlib/mdebin_bar.h @@ -43,7 +43,7 @@ #include "gromacs/utility/real.h" /* The functions & data structures here describe writing - energy differences (or their histogram )for use with g_bar */ + energy differences (or their histogram )for use with gmx bar */ class delta_h_history_t; struct t_enxframe; diff --git a/src/gromacs/tools/eneconv.cpp b/src/gromacs/tools/eneconv.cpp index a9cc20f9349..f2f8b7999f0 100644 --- a/src/gromacs/tools/eneconv.cpp +++ b/src/gromacs/tools/eneconv.cpp @@ -745,8 +745,8 @@ int gmx_eneconv(int argc, char* argv[]) "want.\n" " Use the -rmdh option to throw all delta H " "samples away.\n" - " Use g_energy -odh option to extract these " - "samples.\n", + " Use gmx energy -odh option to extract " + "these samples.\n", files[f].c_str(), size); warned_about_dh = TRUE;