Gromacs
2024.3
|
#include "gmxpre.h"
#include "gromacs/utility/path.h"
#include "config.h"
#include <cctype>
#include <cerrno>
#include <cstddef>
#include <cstdio>
#include <cstdlib>
#include <cstring>
#include <algorithm>
#include <filesystem>
#include <string>
#include <string_view>
#include <utility>
#include <vector>
#include <sys/stat.h>
#include "gromacs/utility/exceptions.h"
#include "gromacs/utility/futil.h"
#include "gromacs/utility/stringutil.h"
Implements functions in path.h.
Functions | |
bool | anonymous_namespace{path.cpp}::isDirSeparator (char chr) |
Check whether a given character is a directory separator. | |
bool | gmx::extensionMatches (const std::filesystem::path &path, std::string_view extension) |
Check if file extension of path without final '.' matches extension . | |
std::filesystem::path | gmx::stripExtension (const std::filesystem::path &path) |
Remove extension from file path. | |
std::filesystem::path | gmx::concatenateBeforeExtension (const std::filesystem::path &path, const std::string &addition) |
Concatenate before extension. | |
std::string | gmx::stripSourcePrefix (const char *path) |
Strip source prefix from path. | |
std::vector < std::filesystem::path > | gmx::splitPathEnvironment (const std::string &pathEnv) |
Split PATH environment variable into search paths. More... | |
std::vector < std::filesystem::path > | gmx::getSystemExecutablePaths () |
Get collection of possible executable paths. | |
Variables | |
const char | anonymous_namespace{path.cpp}::cDirSeparators [] = "/\\" |
Directory separators to use when parsing paths. | |
const char | anonymous_namespace{path.cpp}::cPathSeparator = ':' |
Separator to use to split the PATH environment variable. More... | |