Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Generating HTML output from criterion

There is a nice example of HTML output from criterion at http://bos.github.com/criterion/.

Which command line option is used to generate this output?

An answer to a related question asserts that this output exits, but it does not seem to show up in the command line options when using --help.

like image 971
danr Avatar asked Mar 16 '12 16:03

danr


People also ask

What is HTML output tag in HTML?

HTML <output> Tag 1 Definition and Usage. The <output> tag is used to represent the result of a calculation (like one performed by a script). 2 Browser Support. The numbers in the table specify the first browser version that fully supports the element. 3 Attributes 4 Global Attributes. ... 5 Event Attributes. ... 6 Default CSS Settings

How does the HTML builder work?

Each HTML builder is atomic and knows what to build and where to place data It may call some additional builders to get HTML from there (f.e. for header and footer) It may have the functionality to get some common HTML or CSS from another file

How to generate HTML results from SQL query?

A SELECT query returns results as a rowset. You can optionally retrieve formal results of a SQL query as XML by specifying the FOR XML clause in the query. By using FOR XML clause we can also return results in HTML format, but need to tweak a query a bit. We can use this trick to generate some static HTML pages. Generate HTML table from SQL query.


2 Answers

Sorry I didn't get around to your comment-question.

The answer Jedai gives is right - just use -o. For example, here is a line from one of my Makefiles for running benchmarks using defaultMain from Criterion:

./Bench -g -u Bench.csv -o Bench.html -s $(SAMPLES)

Breaking that down, it says:

-g    run GC between each sample
-u    output CSV data to the given file
-o    output HTML data to the given file
-s    collect this many samples
like image 120
Thomas M. DuBuisson Avatar answered Sep 18 '22 12:09

Thomas M. DuBuisson


Well if you just want html output, then yourBench -o yourReport.html will generate some perfectly reasonable output. If you want to use your own template, look at the templates/report.tpl example in the distribution and use the -t option.

like image 38
Jedai Avatar answered Sep 22 '22 12:09

Jedai