Run in Batch Mode
Verissimo can be invoked in batch mode by running:
$DVT_HOME/bin/verissimo.sh ...
Main Use Cases
Generate the HTML documentation of all the available rules:
verissimo.sh -gen_rulepool_doc
Generate the XML ruleset of all the available rules:
verissimo.sh -gen_rulepool_xml
Generate the XML ruleset of all the available rules, displaying id, default title and parameters for each rule:
verissimo.sh -gen_rulepool_xml -rulepool_xml_include id,title,parameters
Run the predefined Basic ruleset:
verissimo.sh -cmd my_compile.args
Run the predefined Basic ruleset and generate HTML lint report:
verissimo.sh -cmd my_compile.args -gen_html_report
Open HTML lint report in DVT as Verissimo GUI report:
verissimo.sh -open_html_report /path/to/verissimo_html_report
Run a specific ruleset:
verissimo.sh -cmd my_compile.args -ruleset my_ruleset.xml
Run the XVM compliance ruleset:
verissimo.sh -cmd my_compile.args -compliance
Generate the HTML documentation for a specific ruleset:
verissimo.sh -gen_ruleset_doc -ruleset my_ruleset.xml
Use a previously generated HTML report to pre-waive unchanged files:
Step 1: Generate an HTML report for the project:
verissimo.sh -cmd my_compile.args -ruleset my_ruleset.xml -gen_html_report -html_report_location /path/to/baseline_report
Step 2: After editing the project use the previously generated HTML report to pre-waive unchanged files:
verissimo.sh -cmd my_compile.args -ruleset my_ruleset.xml -baseline_report /path/to/baseline_report/verissimo_html_report -prewaive_unchanged_files
Arguments
Argument |
Description |
---|---|
all |
Optional. Run “All Rules”. |
autocorrect |
Optional. Auto-correct failures for all checks enabled in the ruleset when running in batch mode. |
autocorrect_checkout <perforce> |
Optional. Checkout files using specified revision control system to enable editing when using autocorrect. |
autocorrect_files_location |
Optional. Destination directory for the autocorrected files. |
autocorrect_generate_modified_files |
Optional. Generate new files after performing autocorrect with the modified code. |
autocorrect_reruns <number> |
Optional. Specify the maximum number of reruns when performing autocorrect in batch mode. |
autocorrect_rule <rule name> |
Optional. Autocorrect a rule name from specified ruleset. |
baseline_report |
Optional. Directory of the baseline HTML report that is used to pre-waive unchanged files. |
basic |
Optional. Run the “Basic Rules”. |
check_timeout <seconds> |
Optional. Set the timeout value of a check. |
cmd <command file> |
Mandatory. Compile using the specified compilation arguments file. |
compare <directory> |
Optional. Directory of the HTML report to be compared with the report specified by the next ‘compare’ argument. |
compare_baseline <directory> |
Optional. Directory of the baseline HTML report to be compared with the current report specified by the ‘compare_current’ argument. |
compare_current <directory> |
Optional. Directory of the current HTML report to be compared with the baseline report specified by the ‘compare_baseline’ argument. |
compare_html_report_location <directory> |
Optional. Destination directory for the compare HTML lint report. |
compile_waivers <file> |
Optional. Waive compilation errors using the waivers specified in the XML file. Waivers specified with this flag will have the highest precedence. See Compile Waivers. |
compliance |
Optional. Run the “XVM Compliance Rules”. |
current_html_report_location <directory> |
Optional. Destination directory for the current HTML lint report. |
custom_report_location |
Optional. Destination directory for the custom lint report. |
custom_rules <jars> |
Optional. Path to jars containing custom rules. |
dead_code |
Optional. Run the “Dead Code Rules”. |
debug_custom_rules <class> |
Optional. Name of the custom rule class to be debugged. |
debug_custom_rules_from_files <files> |
Optional. Path of the file containing custom rule class names to be debugged. |
diff <directory> |
Optional. Directory of the HTML report to be differentiated with other reports specified by subsequent ‘diff’ arguments. |
dry_run |
Optional. Execute a dry run of the verissimo.sh command. Arguments are validated, however linting is not done. |
eclipsespace <directory> |
Optional. Directory of the Eclipse configuration and user area when running Verissimo in GUI Mode. Default value: /home/user/.eclipse. |
fail_on_severity <error | warning | info> |
Optional. Fail if the result contains checks with severities equal or higher than the specified severity. Default: info. |
force |
Optional. Overwrite existing project when running Verissimo in GUI Mode. |
gen_compare_html_report |
Optional. Generate the HTML compare report between baseline html report and current lint report. The baseline report is required. |
gen_current_html_report |
Optional. Generate the current HTML lint report. The baseline report is required. |
gen_custom_report <FTL file> |
Optional, one or more. Generate a custom report using the specified template. This can be user defined or one of the predefined templates: FAILURES_TEXT, FAILURES_JSON, FAILURES_XML, LINTED_FILES_TEXT, AUTOCORRECT_EDITS_TEXT, WAIVED_FAILURES_CSV, AVAILABLE_CHECKS_CSV, AUTOCORRECT_MODIFIED_FILES_SH. See Custom Report. |
gen_custom_report_ftl <name> |
Optional, one or more. Generate a custom report template using the specified option. Available values are: FAILURES_TEXT, FAILURES_JSON, FAILURES_XML, LINTED_FILES_TEXT, AUTOCORRECT_EDITS_TEXT, WAIVED_FAILURES_CSV, AVAILABLE_CHECKS_CSV, AUTOCORRECT_MODIFIED_FILES_SH |
gen_progress_report |
Optional. Generate the HTML Progress Report with all the given HTML Reports. |
gen_html_report |
Optional. Generates the HTML lint report. |
gen_rulepool_doc |
Optional. Generate the HTML documentation with all available rules. |
gen_rulepool_xml |
Optional. Generate the XML ruleset with all available rules. |
gen_ruleset_doc |
Optional. Generate the HTML documentation with all the rules from the specified ruleset. |
gen_ruleset_xml |
Optional. Generate the XML ruleset with all the rules from the specified predefined ruleset (if no predefined ruleset is specified, an XML with all available rules will be generated). |
gen_txt_report |
Optional. Print lint failures in the Verissimo output. |
gui |
Optional. Run Verissimo in GUI mode. |
heap_size <size> |
Optional. Set the Java heap size. Default is 3072m. |
help |
Print help and exit. |
histogram_dump_rules <rules> |
Optional. Comma separated list of rule names for which histogram dumps will be generated. |
html_report_location |
Optional. Destination directory for the HTML lint report. |
ignore_build_config_errors |
Optional. Ignore build configuration errors. |
ignore_compile_errors |
Optional. Ignore compile errors, disable printing of compilation errors and continue with linting. |
ignore_lint_errors |
Optional. Ignore lint errors and disable printing of lint errors. |
ignore_lint_infos |
Optional. Ignore lint infos and disable printing of lint infos. |
ignore_lint_warnings |
Optional. Ignore lint warnings and disable printing of lint warnings. |
include_code_date |
Optional. Include the committer date in the generated lint report. |
include_creation_date |
Optional. Include the creation date of each failure in the generated lint report based on GIT, SVN or Perforce blame information or using the file’s last modification date. |
include_html_code |
Optional. Include the linted source code as HTML files in the generated lint report. |
info <key=value> |
Optional. Place a ‘key=value’ annotation on all hits from a generated HTML report, in order to create filters based on them after a merge of reports. |
license_queue_timeout <timeout> |
Optional. Maximum time in seconds to wait in queue for a license when one is not available. |
list_unused_available_rules |
Optional. List available rules not used in current ruleset. |
log <log file> |
Optional. Log to specified file. |
manual_checks_status <XML file> |
Optional. Manual checks status file. |
map <mapping> |
Optional. Create a mapping between linted files from current and baseline reports. The mapping has the format ‘type+current_report_path_pattern=baseline_report_path_pattern’, where the type is one of PERL or SIMPLE (if not specified PERL is used). |
merge <directory> |
Optional. Directory of the HTML report to be merged with other reports specified by subsequent ‘merge’ arguments. |
noexit |
Optional. If the script starts a new DVT do not exit until DVT is closed. Only works when running Verissimo in GUI Mode. (Not supported on Windows) |
non_standard |
Optional. Run the “Non-standard Rules”. |
open_report <directory> |
Optional. Open the specified Verissimo HTML report in the DVT Verissimo GUI report. |
ovm |
Optional. Run Verissimo XVM rules as OVM (if not specified UVM will be used). |
parent_folder <name> |
Optional. Directory that contains HTML reports which are used to generate the HTML Progress Report. |
performance |
Optional. Run the “Performance Rules”. |
prewaive_unchanged_files |
Optional. Pre-waives the unchanged files based on the baseline report. |
print_all_compile_problems |
Optional. Print all compile problems. Include waived problems if used with “-print_compile_waivers_info”. |
print_compile_waivers_info |
Optional. Prints how many problems each compile waiver has matched. |
process_timeout <seconds> |
Optional. Set the timeout value of the complete linting process, including building. |
progress_name <name> |
Optional. Customize the name of the generated HTML Progress Report. |
project <directory> |
Optional. Directory of the project to be created when running Verissimo in GUI Mode. |
project_name <name> |
Optional. Name of the project to be created when running Verissimo in GUI Mode. Default value: “project”. |
report_folder <directory> |
Optional. Name of the HTML report directory used to generate the HTML Progress Report. |
rtl |
Optional. Run the “RTL Rules”. |
rulepool_xml_include <rule_attributes> |
Optional. Used with -gen_rulepool_xml or -gen_ruleset_xml to specify what rule attributes should be displayed in the generated XML ruleset. Comma separated list of: complete_rule_info, id, name, title, severity, disable, description, parameters, commented_parameters, parameters_info. |
ruleset <XML file> |
Optional. XML ruleset file. See Rulesets. |
run_rule <rule name> |
Optional. Run only rule name from specified ruleset. |
session_timeout <seconds> |
Optional. Set the timeout value of the linting session, without building. |
silent |
Optional. Turn on minimal output. |
since <yyyy-MM-dd> |
Optional. Show only rules added since yyyy-MM-dd when generating rulepool HTML and XML or listing unused rules. |
stack_size <size> |
Optional. Set the Java thread stack size. Default is 4m. |
thread_dump_interval <milliseconds> |
Optional. Set the interval of thread dumps for a rule. Default value: 200ms. |
thread_dump_delay <milliseconds> |
Optional. Set the delay before a rule will generate thread dumps. Default value: 0ms. |
thread_dump_rules <rules> |
Optional. Comma separated list of rule names for which thread dumps will be generated. |
uvm_ieee |
Optional. Run the “UVM IEEE 1800.2-2020 Compliance Rules”. |
version <size> |
Print version and exit. |
waivers <XML file> |
Optional. XML waivers file. See Lint Waivers. |
workspace <directory> |
Optional. Directory of the eclipse workspace (temporary eclipse directory) when running Verissimo in GUI Mode. |
zero_exit_on_lint_failures |
Optional. Return exit code zero even if some checks fail. Non-zero exit code is returned only when an internal error occurs (execution exceptions or wrong arguments). |
Exit code
The exit code is calculated with a bitwise OR operation between the following codes:
0 - OK
1 - Internal Error
2 - Errors
4 - Warnings
8 - Infos
16 - Build config or compile error
The codes for errors, warnings and infos indicate the presence of such failures in the lint report or in the New Failures/Added Rules categories of the compare report.
The exit code can be filtered using the following arguments:
-fail_on severity: E.g. if the fail_on severity is set on “error”, the codes for warnings(4) and infos(8) will be filtered out;
-zero_exit_on_lint_failures: filters everything with the exception of the internal error(1);
-ignore_build_config_errors: if there are build configuration errors(16) they will be ignored and the exit code will be filtered;
-ignore_compile_errors: if there are compile errors(16) they will be ignored and the exit code will be filtered;
-ignore_lint_errors: if there are linting errors(2) they will be ignored and the exit code will be filtered;
-ignore_lint_warnings: if there are linting warnings(4) they will be ignored and the exit code will be filtered;
-ignore_lint_infos: if there are linting infos(8) they will be ignored and the exit code will be filtered.