Added Utils::getWorkingDirPath() function

This commit is contained in:
Sylar 2025-11-06 18:41:44 +01:00
parent bfa1ae048b
commit 09722f5990
3 changed files with 11 additions and 5 deletions

View file

@ -23,7 +23,7 @@ namespace ostd
}
return list;
}
std::vector<std::filesystem::path> Utils::listDirectory(const String& directoryPath)
{
std::vector<std::filesystem::path> list;
@ -53,7 +53,7 @@ namespace ostd
}
return list;
}
std::vector<std::filesystem::path> Utils::listDirectoryRecursive(const String& directoryPath)
{
std::vector<std::filesystem::path> list;
@ -74,5 +74,10 @@ namespace ostd
#endif
return home_path;
}
}
std::filesystem::path Utils::getWorkingDirPath(void)
{
return std::filesystem::current_path();
}
}

View file

@ -48,7 +48,7 @@ namespace ostd
};
typedef std::vector<Byte> ByteStream;
}
}

View file

@ -196,6 +196,7 @@ namespace ostd
static std::vector<std::filesystem::path> listDirectoriesInDirectoryRecursive(const String& directoryPath);
static std::vector<std::filesystem::path> listDirectoryRecursive(const String& directoryPath);
static ostd::String getHomeDirPath(void);
static std::filesystem::path getWorkingDirPath(void);
//Implemented in <ShuntingYard.cpp>
static int32_t solveIntegerExpression(const String& expr);