Process execution and environment-variable access. More...
#include <optional>#include <string>Go to the source code of this file.
Namespaces | |
| namespace | notex |
| namespace | notex::system |
Functions | |
| std::string | notex::system::run_command (const std::string &command) |
Runs command through the shell and returns everything it wrote to standard output (and standard error, since the two are merged so that a failing command's diagnostics end up in the error message below). | |
| std::optional< std::string > | notex::system::get_env (const std::string &name) |
| Reads an environment variable. | |
Process execution and environment-variable access.
Every place in notex_core that needs to shell out to an external tool (kpsewhich, mktexlsr, ...) or read an environment variable goes through this one choke point, so that the rest of the library never touches ::popen or std::getenv directly.
Definition in file system.hpp.