From e3f74dc319d32b866b40264cc2ff71ba92fec227 Mon Sep 17 00:00:00 2001 From: Jon Siwek Date: Fri, 22 Nov 2013 14:37:07 -0600 Subject: [PATCH] Change Broxygen config file format. " " seems a more natural order for specifying targets. --- doc/broxygen.conf.in | 2 +- doc/ext/broxygen.py | 2 +- src/broxygen/Configuration.cc | 2 +- testing/btest/doc/broxygen/all_scripts.test | 2 +- testing/btest/doc/broxygen/enums.bro | 2 +- testing/btest/doc/broxygen/example.bro | 2 +- testing/btest/doc/broxygen/func-params.bro | 2 +- testing/btest/doc/broxygen/records.bro | 2 +- testing/btest/doc/broxygen/type-aliases.bro | 2 +- 9 files changed, 9 insertions(+), 9 deletions(-) diff --git a/doc/broxygen.conf.in b/doc/broxygen.conf.in index b27ba6248d..1e70445f58 100644 --- a/doc/broxygen.conf.in +++ b/doc/broxygen.conf.in @@ -1 +1 @@ -script @BROXYGEN_SCRIPT_OUTPUT@/ * +script * @BROXYGEN_SCRIPT_OUTPUT@/ diff --git a/doc/ext/broxygen.py b/doc/ext/broxygen.py index d7a4e57c21..adea390642 100644 --- a/doc/ext/broxygen.py +++ b/doc/ext/broxygen.py @@ -76,7 +76,7 @@ def generate_config(env, type, pattern): prefix = "{0}-{1}-".format(type, pattern_to_filename_component(pattern)) (fd, cfg) = tempfile.mkstemp(suffix=".cfg", prefix=prefix, dir=work_dir) generated_file = "{0}.rst".format(cfg) - config = "{0}\t{1}\t{2}".format(type, generated_file, pattern) + config = "{0}\t{1}\t{2}".format(type, pattern, generated_file) f = os.fdopen(fd, "w") f.write(config) f.close() diff --git a/src/broxygen/Configuration.cc b/src/broxygen/Configuration.cc index 9d0c0f7015..19dc61aa1a 100644 --- a/src/broxygen/Configuration.cc +++ b/src/broxygen/Configuration.cc @@ -457,7 +457,7 @@ Config::Config(const string& arg_file, const string& delim) reporter->FatalError("unkown Broxygen target type: %s", tokens[0].c_str()); - targets.push_back(it->second(tokens[1], tokens[2])); + targets.push_back(it->second(tokens[2], tokens[1])); } if ( f.bad() ) diff --git a/testing/btest/doc/broxygen/all_scripts.test b/testing/btest/doc/broxygen/all_scripts.test index cb746df9a9..56bb5313bb 100644 --- a/testing/btest/doc/broxygen/all_scripts.test +++ b/testing/btest/doc/broxygen/all_scripts.test @@ -6,5 +6,5 @@ # @TEST-EXEC: btest-diff .stderr @TEST-START-FILE broxygen.config -script scripts/ * +script * scripts/ @TEST-END-FILE diff --git a/testing/btest/doc/broxygen/enums.bro b/testing/btest/doc/broxygen/enums.bro index eeb393ebfb..e8b4c741c2 100644 --- a/testing/btest/doc/broxygen/enums.bro +++ b/testing/btest/doc/broxygen/enums.bro @@ -2,7 +2,7 @@ # @TEST-EXEC: btest-diff autogen-reST-enums.rst @TEST-START-FILE broxygen.config -identifier autogen-reST-enums.rst TestEnum* +identifier TestEnum* autogen-reST-enums.rst @TEST-END-FILE ## There's tons of ways an enum can look... diff --git a/testing/btest/doc/broxygen/example.bro b/testing/btest/doc/broxygen/example.bro index 6129c8d3b8..e7212f3c5f 100644 --- a/testing/btest/doc/broxygen/example.bro +++ b/testing/btest/doc/broxygen/example.bro @@ -2,7 +2,7 @@ # @TEST-EXEC: btest-diff example.rst @TEST-START-FILE broxygen.config -script example.rst broxygen/example.bro +script broxygen/example.bro example.rst @TEST-END-FILE @load broxygen/example.bro diff --git a/testing/btest/doc/broxygen/func-params.bro b/testing/btest/doc/broxygen/func-params.bro index cdb8760935..42d1308151 100644 --- a/testing/btest/doc/broxygen/func-params.bro +++ b/testing/btest/doc/broxygen/func-params.bro @@ -2,7 +2,7 @@ # @TEST-EXEC: btest-diff autogen-reST-func-params.rst @TEST-START-FILE broxygen.config -identifier autogen-reST-func-params.rst test_func_params* +identifier test_func_params* autogen-reST-func-params.rst @TEST-END-FILE ## This is a global function declaration. diff --git a/testing/btest/doc/broxygen/records.bro b/testing/btest/doc/broxygen/records.bro index 70dccecc58..0cc7d27500 100644 --- a/testing/btest/doc/broxygen/records.bro +++ b/testing/btest/doc/broxygen/records.bro @@ -2,7 +2,7 @@ # @TEST-EXEC: btest-diff autogen-reST-records.rst @TEST-START-FILE broxygen.config -identifier autogen-reST-records.rst TestRecord* +identifier TestRecord* autogen-reST-records.rst @TEST-END-FILE # undocumented record diff --git a/testing/btest/doc/broxygen/type-aliases.bro b/testing/btest/doc/broxygen/type-aliases.bro index 1ab83cc02a..28c2cc5568 100644 --- a/testing/btest/doc/broxygen/type-aliases.bro +++ b/testing/btest/doc/broxygen/type-aliases.bro @@ -2,7 +2,7 @@ # @TEST-EXEC: btest-diff autogen-reST-type-aliases.rst @TEST-START-FILE broxygen.config -identifier autogen-reST-type-aliases.rst BroxygenTest::* +identifier BroxygenTest::* autogen-reST-type-aliases.rst @TEST-END-FILE module BroxygenTest;