tree-sitter/test/helpers/file_helpers.h
2017-08-08 14:06:11 -07:00

15 lines
497 B
C++

#ifndef HELPERS_FILE_HELPERS_H_
#define HELPERS_FILE_HELPERS_H_
#include <string>
#include <vector>
#include <sys/stat.h>
bool file_exists(const std::string &path);
int get_modified_time(const std::string &path);
std::string read_file(const std::string &path);
void write_file(const std::string &path, const std::string &content);
std::vector<std::string> list_directory(const std::string &path);
std::string join_path(const std::vector<std::string> &parts);
#endif // HELPERS_FILE_HELPERS_H_