ReleaseButler 1.0
😙 package manager on GitHub 😙
Loading...
Searching...
No Matches
pack_core.cpp File Reference
#include "core/pack_core.h"
#include <sys/wait.h>
#include <unistd.h>
#include <openssl/sha.h>
#include <array>
#include <cstdio>
#include <cstdlib>
#include <filesystem>
<<<<<<< HEAD #include <string>
#include <string_view>
#include "curl_cpp/cppcurl.h"
#include "tlog.h"
#include "utils/confile.h"
#include "utils/env.h"
#include "utils/os-detect.h"
======= #include <fstream>
#include <ios>
#include <iostream>
#include <sstream>
#include <string>
#include <string_view>
#include "tlog.h"
#include "utils/confile.h"
#include "utils/misc.h"
>>>>>>> dev

Functions

auto install (std::string_view url, std::string_view name, std::string_view pack_name, std::optional< std::string_view > sha256_val, const bool vmode, const bool install) -> bool
 Programs for download and installation.
 
auto install_core (std::string_view pack_name, const bool vmode) -> bool
 Core functions that implement the installation functionality.
 

Function Documentation

◆ install()

auto install ( std::string_view url,
std::string_view name,
std::string_view pack_name,
std::optional< std::string_view > sha256_val,
bool vmode,
bool install ) -> bool
nodiscard

Programs for download and installation.

But in fact install() does not perform all of the functions involved in installation that are permitted by the software's operation. It's the parsing of the file that implements all of the features allowed for installation.

Parameters
`url`The home page of the website where the program is hosted
`name`Name of the software
`pack_name`Name of the package to download, e.g. fastfetch-linux-amd64.deb
`sha256_val`SHA256 of the file to download.
`vmode`Whether to output more information (for debugging purposes)
`install`Whether to call the corresponding package manager to install after download
Returns
Returns a bool indicating whether the function was executed correctly.

◆ install_core()

auto install_core ( std::string_view pack_name,
bool vmode ) -> bool
nodiscard

Core functions that implement the installation functionality.

Parameters
`pack_name`Name of the package to download, e.g. fastfetch-linux-amd64.deb
`vmode`Whether to output more information (for debugging purposes)
Returns
Returns a bool indicating whether the function was executed correctly.