From afa092638250c72a92136b0b440bb6bb7c070702 Mon Sep 17 00:00:00 2001 From: Carl Hetherington Date: Wed, 5 Oct 2022 00:51:09 +0200 Subject: Add contains_assetmap() --- src/lib/util.cc | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'src/lib/util.cc') diff --git a/src/lib/util.cc b/src/lib/util.cc index cfeacdb92..609e92850 100644 --- a/src/lib/util.cc +++ b/src/lib/util.cc @@ -1187,3 +1187,11 @@ error_details(boost::system::error_code ec) { return String::compose("%1:%2:%3", ec.category().name(), ec.value(), ec.message()); } + + +bool +contains_assetmap(boost::filesystem::path dir) +{ + return boost::filesystem::is_regular_file(dir / "ASSETMAP") || boost::filesystem::is_regular_file(dir / "ASSETMAP.xml"); +} + -- cgit v1.2.3