Batch operation is possible with Python source code for both minidom and lxml brances, and from Windows and MacOS built applications (lxml branch).
Run as follows:
- Python source code (lxml, current version):
python arelleCmdLine.py arguments
- Python source code (minidom, prior version):
python -m arelle.CntlrCmdLine arguments
- Windows x64 or 32 bit (lxml):
"c:\Program Files\arelleCmdLine.exe" arguments
- MacOS App (lxml) is more tricky, because the app contents includes a GUI-only program, unless it is executed directly within the bundle. Terminal and shell parameters aren’t passed in to a Python app, so they are instead to be passed via the environment parameter, ARELLE_ARGS. (The first time ARELLE_ARGS is set, it is necessary to export ARELLE_ARGS.) This example is for a terminal window or shell script:
ARELLE_ARGS="arguments" export ARELLE_ARGS /Applications/arelle.app/Contents/MacOS/Arelle
where arguments are:
- -f or –file followed by file name (to be loaded, instance, schema, linkbase, inline XBRL instance, testcase file, or testcase index file). File may be local or a URI to a web-located file.
- -h or –help for a list of arguments
- -d or –diff followed by file name for a second DTS to be compared for versioning report generation. In this case the -f file is the fromDTS and the -d file is the toDTS.
- -v or –validate: perform validation according to the file type. If an XBRL file, it is validated according to XBRL validation 2.1, calculation linkbase validation if either –calcDecimals or –calcPrecision are specified, and SEC Edgar Filing Manual (if –efm selected) or Global Filer Manual disclosure system validation (if –gfm=XXX selected). If a test suite or testcase, the test case variations are individually so validated.
- –calcDecimals: select calculation linkbase validation, inferring decimals
- –calcPrecision: select calculation linkbase validation, inferring precision
- –efm: select Edgar Filing Manual (U.S. SEC) disclosure system rules validation
- –gfm followed by disclosure system name: specify the Global Filing Manual disclosure system name and select disclosure system rules validation
- –utr: select validation with respect to the Unit Types Registry
- –csvDTS followed by file name: store the DTS in specified CSV file
- –csvFacts followed by file name: store the fact list in specified CSV file
- –factListCols followed by a list of columns for a –csvFacts list, the columns may be blank separated and can be any of these: Label, Name, contextRef, unitRef, Dec, Prec, Lang, Value, EntityScheme, EntityIdentifier, Period, or Dimensions. The default columns list is “Label contextRef unitRef Dec Prec Lang Value“.
- –csvConcepts followed by file name: store the concepts listing in specified CSV file
- –csvPre followed by file name: store the presentation linkbase in specified CSV file
- –csvCal followed by file name: store the calculation linkbase in specified CSV file
- –csvDim followed by file name: store the dimensions in definition linkbase in specified CSV file
- –csvFormulae followed by file name: store the formula-related resources tree in specified CSV file
- –csvTestReport followed by file name: write a test report of validation (of test cases) in specified CSV file
- –formulaParamExprResult: formula tracing option
- –formulaParamInputValue: formula tracing option
- –formulaCallExprSource: formula tracing option
- –formulaCallExprCode: formula tracing option
- –formulaCallExprEval: formula tracing option
- –formulaCallExprResult: formula tracing option
- –formulaVarSetExprEval: formula tracing option
- –formulaVarSetExprResult: formula tracing option
- –formulaAsserResultCounts: formula tracing option
- –formulaFormulaRules: formula tracing option
- –formulaVarsOrder: formula tracing option
- –formulaVarExpressionSource: formula tracing option
- –formulaVarExpressionCode: formula tracing option
- –formulaVarExpressionEvaluation: formula tracing option
- –formulaVarExpressionResult: formula tracing option
- –formulaVarFiltersResult: formula tracing option
- -a or –about: show the about and license information
Batch Script Files
A set of batch script files are provided for convenience of running repetitive things. Contributors are encouraged to improve them and make them suitable for Mac and Linux (originally just Windows):
- runEFMTests.bat: Runs all of the EFM tests in the indicated source tree of test files. Outputs log with error messages, and an Excel-compatible file (.csv for the moment) with the same appearance as the tests tree grid GUI view.
- runUS-GFMTests.bat: Same, but runs tests in the Global Filer Manual, instead of Edgar, mode. Just for experimentation at this moment.
- runXDTTests.bat: Runs the XDT conformance suite, and outputs messages log and Excel report.
- runGenerateVersioningTestcases.bat: Generates a versioning creation/consumption test suite from the excel index file, such as 1000-2000-index.xml.
- runVersioningConsumptionTests.bat: Executes versioning consumption testcases from the index file noted in the settings.