-
Notifications
You must be signed in to change notification settings - Fork 25
Command Line Interface
Mayan Jean edited this page Jun 29, 2018
·
19 revisions
| name(min) | name | needed ? | args needed ?(=*) | global | Default | handeled | description |
|---|---|---|---|---|---|---|---|
| i | input | Y | {PATH}(s) | Y | Missing, Bad Paths + Folders | {PATH} to an input file to parse. This option can be specified more than once | |
| o | output | N | {PATH}(s)(cr) | Y | Missing & Count(if ets=5) CanCreate | {PATH} to an ouput file where to generate code. This option can be specified more than once | |
| d | diagnostics | N | {PATH}(cr) | Y | CanCreateFile | {PATH} to the error diagnostics file | |
| s | skeletons | N (Y if ets=5) | {PATH} | Y | Missing (if ets=5) Bad Path | {PATH} to the skeletons file | |
| a | autoremarks | N | ---- | Y | Enable automatic remarks creation while parsing and generating Cobol | ||
| hc | haltonmissingcopy | N | {PATH}(cr) | Y | CanCreateFile | HaltOnMissing Copy will generate a file to list all the absent copies | |
| ets | exectostep | N | [0-5] | strings | Y | Generate(5) | Match[0-5] |
| e | encoding | N | "rdz" | "zos" | "utf8" | Y | rdz |
| y | intrinsic | N | {PATH}(s) | Y | Bad Paths + Folders | {PATH} to intrinsic definitions to load. This option can be specified more than once | |
| c | copies | N | {PATH}(s) | Y | Bad Paths + Folders | Folder where COBOL copies can be found. This option can be specified more than once | |
| dp | dependencies | N | {PATH}(s) | Y | Bad Paths + Folders | Path to folder containing programs to load and to use for parsing a generating the input program | |
| t | telemetry | N | ---- | Y | If set to true telemetry will send automatic email in case of bug and it will provide to TypeCobol Team data on your usage | ||
| md | maximumdiagnostics | N | int | Y | Parsable to int | Wait for an int value that will represent the maximum number of diagnostics that TypeCobol have to return | |
| f | outputFormat | N | "0" | "1" | strings | Y | Cobol85 |
| ec | expandingcopy | N | {PATH}(cr) | Y | CanCreateFile | Generate a file with all COPY directives expanded in the source code. This option will be executed if the Preprocessor step is enabled. | |
| exc | extractusedcopy | N | {PATH}(cr) | Y | CanCreateFile | Generate a file with all COPIES detected by the parser | |
| k | startServer | N | "hidden" | N | NormalWindow | Start the server if not already started, and executes commandline. By default the server is started in window mode '{hidden}' hide the window. | |
| 1 | once | N | ---- | N | Parse one set of files and exit. If present, this option does NOT launch the server. | ||
| h | help | N | ---- | N | Output a usage message and exit. | ||
| V | version | N | ---- | N | Output the version number of " + PROGNAME + " and exit. | ||
| p | pipename | N | string | N | TypeCobol.Server | Pipename used if running as server. Default: "TypeCobol.Server" | |
| cmr | copymovereport | N | {PATH} | {PATH} to Report all Move and Initialize statements that target a COPY. |
TypeCobol.CLI.exe -1 -i PGM1.tcbl -o PGM1.cbl -e rdz -d error.txt -s config\skeletons.xmlTypeCobol.CLI.exe -1 -i PGM1.tcbl -o PGM1.cbl -e rdz -d error.txt -s config\skeletons.xml -c .\copyFolderTypeCobol.CLI.exe -1 -i PGM1.cbl -o PGM1.out.cbl -e rdz -d error.txt --haltonmissingcopy=MissingCopy.txt --exectostep=Preprocessor--haltonmissingcopy=MissingCopy.txt will tell the parser to write all missing COPY into file "MissingCopy.txt" and to stop after preprocessor phase.
--exectostep=Preprocessor if no copy are missing, this parameter make sure the parser only execute to phase Preprocessor.
| Error code | Name | Message |
|---|---|---|
| 0 | Success | |
| 1 | Warning | |
| 1000 | ParsingDiagnostics | Syntax or semantic error in one or more input file. |
| 1001 | OutputFileError | The number of output files must be equal to the number of input files. |
| 1002 | MissingCopy | Use of option --haltonmissingcopy and at least one COPY is missing. |
| 1003 | GenerationError | Error during Code generatio. |
| 1004 | FatalError | Not managed error. |
| 1005 | UnexpectedParamError | Unexpected parameter given. |
| 1010 | InputFileMissing | Input file(s) are required. |
| 1011 | OutputFileMissing | Output are required in execution to generate step. |
| 1012 | SkeletonMissing | Skeleton file is required in execution to generate step. |
| 1020 | InputFileError | Input files given are unreachable. |
| 1021 | OutputFileErrorBis | Output paths given are unreachable. |
| 1022 | ErrorFileError | Error diagnostics path is unreachable. |
| 1023 | SkeletonFileError | Skeleton file is unreachable. |
| 1024 | HaltOnMissingCopyError | Missing copy path given is unreachable. |
| 1025 | ExecToStepError | Unexpected parameter given for ExecToStep. Accepted parameters are "Scanner"/0, "Preprocessor"/1, "SyntaxCheck"/2, "SemanticCheck"/3, "CrossCheck"/4, "Generate"/5(default). |
| 1026 | EncodingError | Unexpected parameter given for encoding option. Accepted parameters are "rdz"(default), "zos", "utf8". |
| 1027 | IntrinsicError | Intrinsic files given are unreachable. |
| 1028 | CopiesError | Copies files given are unreachable. |
| 1029 | DependenciesError | Dependencies files given are unreachable. |
| 1030 | MaxDiagnosticsError | Maximum diagnostics have to be an integer. |
| 1031 | OutputFormatError | Unexpected parameter given for Output format option. Accepted parameters are Cobol85/0(default), PublicSignature/1, MixedTransform/3. |
| 1032 | ExpandingCopyError | Expanding copy path given is unreachable. |
| 1033 | ExtractusedCopyError | Extractused copy path given is unreachable. |
| 9999 | MultipleErrors |
Introduction
TypeCobol language
-
In a nutshell
-
TypeCobol concepts
TypeCobol Editor
(Type)Cobol parser API
TypeCobol architecture
- Glossary
- Main phases
- How to extend the grammar and semantic check (full example)
- File
- Text
- Code analysis steps
- Program class parser
- Type checker
- Error handler
- Grammars Composition
- Code generation
- Compilation process
(Type)Cobol concepts / reference doc
Contributing