extracted downloaded archive

This commit is contained in:
Blue 2023-09-04 18:45:01 -03:00
parent 76bd9a0497
commit 5ee7ae7f73
Signed by: blue
GPG key ID: 9B203B252A63EE38
3 changed files with 123 additions and 6 deletions

View file

@ -8,6 +8,8 @@
#include <nlohmann/json.hpp>
#include <curl/curl.h>
#include <archive.h>
#include <archive_entry.h>
class Dependency {
public:
@ -54,6 +56,9 @@ private:
);
CURLcode httpGet(const std::string& url, std::string& result, const std::list<std::string_view>& headers = {});
bool extract(const std::filesystem::path& source, const std::filesystem::path& destination) const;
int copy(struct archive *ar, struct archive *aw) const;
private:
Type type;
std::optional<std::string> name;