cava bump: 0.10.2

Signed-off-by: Viktar Lukashonak <myxabeer@gmail.com>
master
Viktar Lukashonak 2024-05-23 16:14:06 +03:00
parent 35a9ca476d
commit 60a613ae51
No known key found for this signature in database
GPG Key ID: 08A413AA87200A6F
3 changed files with 6 additions and 17 deletions

View File

@ -464,7 +464,7 @@ if get_option('experimental')
endif endif
cava = dependency('cava', cava = dependency('cava',
version : '>=0.10.1', version : '>=0.10.2',
required: get_option('cava'), required: get_option('cava'),
fallback : ['cava', 'cava_dep'], fallback : ['cava', 'cava_dep'],
not_found_message: 'cava is not found. Building waybar without cava') not_found_message: 'cava is not found. Building waybar without cava')

View File

@ -8,18 +8,7 @@ waybar::modules::Cava::Cava(const std::string& id, const Json::Value& config)
char cfgPath[PATH_MAX]; char cfgPath[PATH_MAX];
cfgPath[0] = '\0'; cfgPath[0] = '\0';
if (config_["cava_config"].isString()) { if (config_["cava_config"].isString()) strcpy(cfgPath, config_["cava_config"].asString().data());
std::string strPath{config_["cava_config"].asString()};
const std::string fnd{"XDG_CONFIG_HOME"};
const std::string::size_type npos{strPath.find("$" + fnd)};
if (npos != std::string::npos) {
if (const char* xdg = getenv(fnd.c_str()))
strPath.replace(npos, fnd.length() + 1, xdg);
else
spdlog::warn("Module {0}. Environment variable \"${1}\" not found", name_, fnd);
}
strcpy(cfgPath, strPath.data());
}
// Load cava config // Load cava config
error_.length = 0; error_.length = 0;

View File

@ -1,7 +1,7 @@
[wrap-file] [wrap-file]
directory = cava-0.10.1 directory = cava-0.10.2
source_url = https://github.com/LukashonakV/cava/archive/0.10.1.tar.gz source_url = https://github.com/LukashonakV/cava/archive/0.10.2.tar.gz
source_filename = cava-0.10.1.tar.gz source_filename = cava-0.10.2.tar.gz
source_hash = ae8c7339908d6febeac5ab8df4576c03c9fdbca6c8e8975daf9ce68b57038bb5 source_hash = dff78c4787c9843583086408a0a6e5bde7a5dee1fa17ae526847366846cb19c3
[provide] [provide]
cava = cava_dep cava = cava_dep