diff options
| author | Felix Morgner <felix.morgner@gmail.com> | 2018-12-08 10:43:50 +0100 |
|---|---|---|
| committer | Felix Morgner <felix.morgner@gmail.com> | 2018-12-08 10:43:50 +0100 |
| commit | 0c1d1a0f24655c22a373c19aac90a6a225a353e6 (patch) | |
| tree | e65fe3c5f8b80bb59910c81c700eb3ed545848bb /src/filesystem.hpp | |
| parent | f22d1b76c9a957a679b57ddcb67b33cc73a15de1 (diff) | |
| download | wanda-0c1d1a0f24655c22a373c19aac90a6a225a353e6.tar.xz wanda-0c1d1a0f24655c22a373c19aac90a6a225a353e6.zip | |
wanda: reformat source code
Diffstat (limited to 'src/filesystem.hpp')
| -rw-r--r-- | src/filesystem.hpp | 21 |
1 files changed, 10 insertions, 11 deletions
diff --git a/src/filesystem.hpp b/src/filesystem.hpp index bcc9e5e..5b2334a 100644 --- a/src/filesystem.hpp +++ b/src/filesystem.hpp @@ -7,29 +7,28 @@ namespace wanda { - -/** + /** * @brief Covenience alias for path lists */ -using path_list = std::vector<std::filesystem::path>; + using path_list = std::vector<std::filesystem::path>; -/** + /** * @brief The default scan filter, allowing only regular files to pass */ -constexpr inline auto default_filter = [](std::filesystem::path const &path) { + constexpr inline auto default_filter = [](std::filesystem::path const & path) { return is_regular_file(path); -}; + }; -/** + /** * @brief Scan the given folder for files */ -std::optional<path_list> scan(std::filesystem::path folder, bool(filter)(std::filesystem::path const &) = default_filter); + std::optional<path_list> scan(std::filesystem::path folder, bool(filter)(std::filesystem::path const &) = default_filter); -/** + /** * @brief Pick a random path from the given list */ -std::filesystem::path random_pick(path_list const &paths); + std::filesystem::path random_pick(path_list const & paths); -} // namespace wanda +} // namespace wanda #endif
\ No newline at end of file |
