From e4bc541ba5c3224f242c9d251d19c01c9e6c3037 Mon Sep 17 00:00:00 2001 From: Teemu Murtola Date: Sun, 27 Jul 2014 07:31:56 +0300 Subject: [PATCH] Remove unnecessary extensions in t_filenm defaults Several tools had an extension specified for the default file name in t_filenm, but that extension matched either the only accepted extension for the file type, or to the default extension for that type. To keep the code more uniform, remove those unnecessary declarations. This leaves <10 instances where t_filenm specifies a non-default extension for the default file name (which doesn't currently work). Probably some of those could also be removed, but at least a few are justified, so a subsequent commit will add support for that. Change-Id: I28053b6b407783b515144aad5351f27bbc2b6ba7 --- src/gromacs/gmxana/gmx_cluster.c | 2 +- src/gromacs/gmxana/gmx_confrms.c | 6 +++--- src/gromacs/gmxana/gmx_current.c | 12 ++++++------ src/gromacs/gmxana/gmx_enemat.c | 6 +++--- src/gromacs/gmxana/gmx_sorient.c | 10 +++++----- src/gromacs/gmxana/gmx_spol.c | 2 +- src/gromacs/gmxana/gmx_traj.c | 26 +++++++++++++------------- 7 files changed, 32 insertions(+), 32 deletions(-) diff --git a/src/gromacs/gmxana/gmx_cluster.c b/src/gromacs/gmxana/gmx_cluster.c index 4632a5900a..d1984d58e5 100644 --- a/src/gromacs/gmxana/gmx_cluster.c +++ b/src/gromacs/gmxana/gmx_cluster.c @@ -1517,7 +1517,7 @@ int gmx_cluster(int argc, char *argv[]) { efXVG, "-sz", "clust-size", ffOPTWR}, { efXPM, "-tr", "clust-trans", ffOPTWR}, { efXVG, "-ntr", "clust-trans", ffOPTWR}, - { efXVG, "-clid", "clust-id.xvg", ffOPTWR}, + { efXVG, "-clid", "clust-id", ffOPTWR}, { efTRX, "-cl", "clusters.pdb", ffOPTWR } }; #define NFILE asize(fnm) diff --git a/src/gromacs/gmxana/gmx_confrms.c b/src/gromacs/gmxana/gmx_confrms.c index c0876922bb..8923544657 100644 --- a/src/gromacs/gmxana/gmx_confrms.c +++ b/src/gromacs/gmxana/gmx_confrms.c @@ -516,9 +516,9 @@ int gmx_confrms(int argc, char *argv[]) { efTPS, "-f1", "conf1.gro", ffREAD }, { efSTX, "-f2", "conf2", ffREAD }, { efSTO, "-o", "fit.pdb", ffWRITE }, - { efNDX, "-n1", "fit1.ndx", ffOPTRD }, - { efNDX, "-n2", "fit2.ndx", ffOPTRD }, - { efNDX, "-no", "match.ndx", ffOPTWR } + { efNDX, "-n1", "fit1", ffOPTRD }, + { efNDX, "-n2", "fit2", ffOPTRD }, + { efNDX, "-no", "match", ffOPTWR } }; #define NFILE asize(fnm) diff --git a/src/gromacs/gmxana/gmx_current.c b/src/gromacs/gmxana/gmx_current.c index 1f41368c1a..42d316bb2e 100644 --- a/src/gromacs/gmxana/gmx_current.c +++ b/src/gromacs/gmxana/gmx_current.c @@ -858,12 +858,12 @@ int gmx_current(int argc, char *argv[]) { efTPS, NULL, NULL, ffREAD }, /* this is for the topology */ { efNDX, NULL, NULL, ffOPTRD }, { efTRX, "-f", NULL, ffREAD }, /* and this for the trajectory */ - { efXVG, "-o", "current.xvg", ffWRITE }, - { efXVG, "-caf", "caf.xvg", ffOPTWR }, - { efXVG, "-dsp", "dsp.xvg", ffWRITE }, - { efXVG, "-md", "md.xvg", ffWRITE }, - { efXVG, "-mj", "mj.xvg", ffWRITE}, - { efXVG, "-mc", "mc.xvg", ffOPTWR } + { efXVG, "-o", "current", ffWRITE }, + { efXVG, "-caf", "caf", ffOPTWR }, + { efXVG, "-dsp", "dsp", ffWRITE }, + { efXVG, "-md", "md", ffWRITE }, + { efXVG, "-mj", "mj", ffWRITE }, + { efXVG, "-mc", "mc", ffOPTWR } }; #define NFILE asize(fnm) diff --git a/src/gromacs/gmxana/gmx_enemat.c b/src/gromacs/gmxana/gmx_enemat.c index 8abd1f3abc..bae15a8ae0 100644 --- a/src/gromacs/gmxana/gmx_enemat.c +++ b/src/gromacs/gmxana/gmx_enemat.c @@ -172,9 +172,9 @@ int gmx_enemat(int argc, char *argv[]) t_filenm fnm[] = { { efEDR, "-f", NULL, ffOPTRD }, - { efDAT, "-groups", "groups.dat", ffREAD }, - { efDAT, "-eref", "eref.dat", ffOPTRD }, - { efXPM, "-emat", "emat", ffWRITE }, + { efDAT, "-groups", "groups", ffREAD }, + { efDAT, "-eref", "eref", ffOPTRD }, + { efXPM, "-emat", "emat", ffWRITE }, { efXVG, "-etot", "energy", ffWRITE } }; #define NFILE asize(fnm) diff --git a/src/gromacs/gmxana/gmx_sorient.c b/src/gromacs/gmxana/gmx_sorient.c index 5a66da9cfa..5c37813228 100644 --- a/src/gromacs/gmxana/gmx_sorient.c +++ b/src/gromacs/gmxana/gmx_sorient.c @@ -185,11 +185,11 @@ int gmx_sorient(int argc, char *argv[]) { efTRX, NULL, NULL, ffREAD }, { efTPS, NULL, NULL, ffREAD }, { efNDX, NULL, NULL, ffOPTRD }, - { efXVG, NULL, "sori.xvg", ffWRITE }, - { efXVG, "-no", "snor.xvg", ffWRITE }, - { efXVG, "-ro", "sord.xvg", ffWRITE }, - { efXVG, "-co", "scum.xvg", ffWRITE }, - { efXVG, "-rc", "scount.xvg", ffWRITE } + { efXVG, NULL, "sori", ffWRITE }, + { efXVG, "-no", "snor", ffWRITE }, + { efXVG, "-ro", "sord", ffWRITE }, + { efXVG, "-co", "scum", ffWRITE }, + { efXVG, "-rc", "scount", ffWRITE } }; #define NFILE asize(fnm) diff --git a/src/gromacs/gmxana/gmx_spol.c b/src/gromacs/gmxana/gmx_spol.c index 9642214a43..af6ed8cc0d 100644 --- a/src/gromacs/gmxana/gmx_spol.c +++ b/src/gromacs/gmxana/gmx_spol.c @@ -207,7 +207,7 @@ int gmx_spol(int argc, char *argv[]) { efTRX, NULL, NULL, ffREAD }, { efTPX, NULL, NULL, ffREAD }, { efNDX, NULL, NULL, ffOPTRD }, - { efXVG, NULL, "scdist.xvg", ffWRITE } + { efXVG, NULL, "scdist", ffWRITE } }; #define NFILE asize(fnm) diff --git a/src/gromacs/gmxana/gmx_traj.c b/src/gromacs/gmxana/gmx_traj.c index 2c20807355..86e9a006f9 100644 --- a/src/gromacs/gmxana/gmx_traj.c +++ b/src/gromacs/gmxana/gmx_traj.c @@ -685,19 +685,19 @@ int gmx_traj(int argc, char *argv[]) { efTRX, "-f", NULL, ffREAD }, { efTPS, NULL, NULL, ffREAD }, { efNDX, NULL, NULL, ffOPTRD }, - { efXVG, "-ox", "coord.xvg", ffOPTWR }, - { efTRX, "-oxt", "coord.xtc", ffOPTWR }, - { efXVG, "-ov", "veloc.xvg", ffOPTWR }, - { efXVG, "-of", "force.xvg", ffOPTWR }, - { efXVG, "-ob", "box.xvg", ffOPTWR }, - { efXVG, "-ot", "temp.xvg", ffOPTWR }, - { efXVG, "-ekt", "ektrans.xvg", ffOPTWR }, - { efXVG, "-ekr", "ekrot.xvg", ffOPTWR }, - { efXVG, "-vd", "veldist.xvg", ffOPTWR }, - { efPDB, "-cv", "veloc.pdb", ffOPTWR }, - { efPDB, "-cf", "force.pdb", ffOPTWR }, - { efXVG, "-av", "all_veloc.xvg", ffOPTWR }, - { efXVG, "-af", "all_force.xvg", ffOPTWR } + { efXVG, "-ox", "coord", ffOPTWR }, + { efTRX, "-oxt", "coord", ffOPTWR }, + { efXVG, "-ov", "veloc", ffOPTWR }, + { efXVG, "-of", "force", ffOPTWR }, + { efXVG, "-ob", "box", ffOPTWR }, + { efXVG, "-ot", "temp", ffOPTWR }, + { efXVG, "-ekt", "ektrans", ffOPTWR }, + { efXVG, "-ekr", "ekrot", ffOPTWR }, + { efXVG, "-vd", "veldist", ffOPTWR }, + { efPDB, "-cv", "veloc", ffOPTWR }, + { efPDB, "-cf", "force", ffOPTWR }, + { efXVG, "-av", "all_veloc", ffOPTWR }, + { efXVG, "-af", "all_force", ffOPTWR } }; #define NFILE asize(fnm) -- 2.22.0