gitweb on Svarog
projekti pod git sistemom za održavanje verzija -- projects under the git version control systemdiff --git a/src-wsl/metrics.wsl b/src-wsl/metrics.wsl
--- a/src-wsl/metrics.wsl
+++ b/src-wsl/metrics.wsl
+C:"Doni Pracner (c) 2015";
+C:"
+This program is free software; you can redistribute it
+and/or modify it under the terms of the GNU General Public
+License as published by the Free Software Foundation; either
+version 3 of the License, or (at your option) any later
+version.
+
+This program is distributed in the hope that it will be
+useful, but WITHOUT ANY WARRANTY; without even the implied
+warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
+PURPOSE. See the GNU General Public License for more
+details.
+
+You should have received a copy of the GNU General Public
+License along with this program. If not, see
+<http://www.gnu.org/licenses/>.
+==========================================================";
+
C:"This program generates metrics for WSL programs,
including options for comparing two programs (mainly ment to
compare different versions) and output differences as direct
automation and creation of CSV files for collections of
programs.";
-C:"Doni Pracner (c) 2015";
-
-C:"Released under the terms of the GPL v3 or later";
-
C:"usage {option} {filename}";
C:"Options";
files in the specified file
";
-C:"
-This program is free software; you can redistribute it
-and/or modify it under the terms of the GNU General Public
-License as published by the Free Software Foundation; either
-version 3 of the License, or (at your option) any later
-version.
-
-This program is distributed in the hope that it will be
-useful, but WITHOUT ANY WARRANTY; without even the implied
-warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
-PURPOSE. See the GNU General Public License for more
-details.
-
-You should have received a copy of the GNU General Public
-License along with this program. If not, see
-<http://www.gnu.org/licenses/>.
-==========================================================";
-
Field_Separator := ",";
MW_PROC @Get_New_Name(VAR str) ==
PRINT("HELP - for now in the comments at the start of the script");
PRINT("options: --header or -H | -c | -HC | -o | -s");
SKIP
- ELSE IF filename = "-H" OR filename = "--header" THEN
+ ELSIF filename = "-H" OR filename = "--header" THEN
@WS("filename");@WS(Field_Separator);
@Write_Metrics_List();
@WL("");
- ELSE IF filename = "-HC" THEN
+ ELSIF filename = "-HC" THEN
C:"Header for comparison";
@WS("filename");@WS(Field_Separator);
@Write_Metrics_List();@WS(Field_Separator);
+ @WS("P2 ");
@Write_Metrics_List();@WS(Field_Separator);
- @WS("DIF");@Write_Metrics_List();@WS(Field_Separator);
- @WS("%");@Write_Metrics_List();
+ @WS("DIF ");
+ @Write_Metrics_List();@WS(Field_Separator);
+ @WS("% ");
+ @Write_Metrics_List();
@WL("");
- ELSE IF filename = "-o" THEN
+ ELSIF filename = "-o" THEN
C:"set output";
IF Argv = < > THEN
PRINT("argument needed after -o")
opened := opened + 1;
@Write_To(filename)
FI
- ELSE IF filename = "-s" THEN
+ ELSIF filename = "-s" THEN
C:"set separator";
IF Argv = < > THEN
PRINT("argument needed after -s")
ELSE
POP(Field_Separator, Argv);
FI
- ELSE IF filename = "-c" THEN
+ ELSIF filename = "-c" THEN
C:"compare two files and dump the comparison";
IF LENGTH(Argv) < 2 THEN
PRINT("two arguments needed after -c")
@Write_Metrics(metrics);
@WL("");
SKIP
- FI FI FI FI FI FI
+ FI
OD;
C:"be nice and close all the opened writes";
FOR count := 1 TO opened STEP 1 DO