MCPcopy Create free account
hub / github.com/argotorg/solidity / optionsDescription

Method optionsDescription

solc/CommandLineParser.cpp:540–959  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

538}
539
540po::options_description CommandLineParser::optionsDescription()
541{
542 // Declare the supported options.
543 po::options_description desc((R"(solc, the Solidity commandline compiler.
544
545This program comes with ABSOLUTELY NO WARRANTY. This is free software, and you
546are welcome to redistribute it under certain conditions. See 'solc --)" + g_strLicense + R"('
547for details.
548
549Usage: solc [options] [input_file...]
550Compiles the given Solidity input files (or the standard input if "-" is
551used as a file name) and outputs the components specified in the options
552at standard output or in files in the output directory, if specified.
553Imports are automatically read from the filesystem, but it is also possible to
554remap paths using the context:prefix=path syntax.
555Example:
556solc --)" + CompilerOutputs::componentName(&CompilerOutputs::binary) + R"( -o /tmp/solcoutput dapp-bin=/usr/local/lib/dapp-bin contract.sol
557
558General 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 )

Callers

nothing calls this directly

Calls 6

joinHumanReadableFunction · 0.85
addMethod · 0.80
isExperimentalMethod · 0.80
selectedNamesMethod · 0.80
toStringFunction · 0.50
nameMethod · 0.45

Tested by

no test coverage detected