mirror of
https://github.com/trapexit/mergerfs.git
synced 2026-10-26 19:01:56 -04:00
Update submitting bug reports, improve collect-info (#1598)
Some checks failed
mkdocs / deploy (push) Has been cancelled
Some checks failed
mkdocs / deploy (push) Has been cancelled
This commit is contained in:
parent
9b046d9a34
commit
72fb6e4aba
5 changed files with 127 additions and 63 deletions
|
|
@ -1,5 +1,7 @@
|
|||
#include "mergerfs_api.hpp"
|
||||
|
||||
#include "fs_xattr.hpp"
|
||||
#include "fs_exists.hpp"
|
||||
#include "fs_lgetxattr.hpp"
|
||||
#include "str.hpp"
|
||||
|
||||
|
|
@ -33,6 +35,27 @@ _lgetxattr(const std::string &input_path_,
|
|||
return rv;
|
||||
}
|
||||
|
||||
bool
|
||||
mergerfs::api::is_mergerfs(const fs::path &mountpoint_)
|
||||
{
|
||||
fs::path dot_mergerfs_filepath;
|
||||
|
||||
dot_mergerfs_filepath = mountpoint_ / ".mergerfs";
|
||||
|
||||
return fs::exists(dot_mergerfs_filepath);
|
||||
}
|
||||
|
||||
int
|
||||
mergerfs::api::get_kvs(const fs::path &mountpoint_,
|
||||
std::map<std::string,std::string> *kvs_)
|
||||
{
|
||||
fs::path dot_mergerfs_filepath;
|
||||
|
||||
dot_mergerfs_filepath = mountpoint_ / ".mergerfs";
|
||||
|
||||
return fs::xattr::get(dot_mergerfs_filepath,kvs_);
|
||||
}
|
||||
|
||||
int
|
||||
mergerfs::api::allpaths(const std::string &input_path_,
|
||||
std::vector<std::string> &output_paths_)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue