| 538 | } |
| 539 | |
| 540 | po::options_description CommandLineParser::optionsDescription() |
| 541 | { |
| 542 | // Declare the supported options. |
| 543 | po::options_description desc((R"(solc, the Solidity commandline compiler. |
| 544 | |
| 545 | This program comes with ABSOLUTELY NO WARRANTY. This is free software, and you |
| 546 | are welcome to redistribute it under certain conditions. See 'solc --)" + g_strLicense + R"(' |
| 547 | for details. |
| 548 | |
| 549 | Usage: solc [options] [input_file...] |
| 550 | Compiles the given Solidity input files (or the standard input if "-" is |
| 551 | used as a file name) and outputs the components specified in the options |
| 552 | at standard output or in files in the output directory, if specified. |
| 553 | Imports are automatically read from the filesystem, but it is also possible to |
| 554 | remap paths using the context:prefix=path syntax. |
| 555 | Example: |
| 556 | solc --)" + CompilerOutputs::componentName(&CompilerOutputs::binary) + R"( -o /tmp/solcoutput dapp-bin=/usr/local/lib/dapp-bin contract.sol |
| 557 | |
| 558 | General Information)").c_str(), |
| 559 | po::options_description::m_default_line_length, |
| 560 | po::options_description::m_default_line_length - 23 |
| 561 | ); |
| 562 | desc.add_options() |
| 563 | (g_strHelp.c_str(), "Show help message and exit.") |
| 564 | (g_strVersion.c_str(), "Show version and exit.") |
| 565 | (g_strLicense.c_str(), "Show licensing information and exit.") |
| 566 | ; |
| 567 | |
| 568 | po::options_description inputOptions("Input Options"); |
| 569 | inputOptions.add_options() |
| 570 | ( |
| 571 | g_strBasePath.c_str(), |
| 572 | po::value<std::string>()->value_name("path"), |
| 573 | "Use the given path as the root of the source tree instead of the root of the filesystem." |
| 574 | ) |
| 575 | ( |
| 576 | g_strIncludePath.c_str(), |
| 577 | po::value<std::vector<std::string>>()->value_name("path"), |
| 578 | "Make an additional source directory available to the default import callback. " |
| 579 | "Use this option if you want to import contracts whose location is not fixed in relation " |
| 580 | "to your main source tree, e.g. third-party libraries installed using a package manager. " |
| 581 | "Can be used multiple times. " |
| 582 | "Can only be used if base path has a non-empty value." |
| 583 | ) |
| 584 | ( |
| 585 | g_strAllowPaths.c_str(), |
| 586 | po::value<std::string>()->value_name("path(s)"), |
| 587 | "Allow a given path for imports. A list of paths can be supplied by separating them with a comma." |
| 588 | ) |
| 589 | ( |
| 590 | g_strIgnoreMissingFiles.c_str(), |
| 591 | "Ignore missing files." |
| 592 | ) |
| 593 | ( |
| 594 | g_strNoImportCallback.c_str(), |
| 595 | "Disable the default import callback to prevent the compiler from loading any source " |
| 596 | "files not listed on the command line or given in the Standard JSON input." |
| 597 | ) |
nothing calls this directly
no test coverage detected