mirror of
https://github.com/hyprwm/Hyprland.git
synced 2025-08-06 15:11:57 -07:00
hyprpm: Add support for specifying exact git revisions for plugin repo (#4983)
* hyprpm(feat): support specifying exact git revs * Mention git rev argument in help * Mention git rev arg is optional * Wrap text
This commit is contained in:
@@ -45,7 +45,8 @@ void DataState::addNewPluginRepo(const SPluginRepository& repo) {
|
||||
{"repository", toml::table{
|
||||
{"name", repo.name},
|
||||
{"hash", repo.hash},
|
||||
{"url", repo.url}
|
||||
{"url", repo.url},
|
||||
{"rev", repo.rev}
|
||||
}}
|
||||
};
|
||||
for (auto& p : repo.plugins) {
|
||||
@@ -178,12 +179,14 @@ std::vector<SPluginRepository> DataState::getAllRepositories() {
|
||||
|
||||
const auto NAME = STATE["repository"]["name"].value_or("");
|
||||
const auto URL = STATE["repository"]["url"].value_or("");
|
||||
const auto REV = STATE["repository"]["rev"].value_or("");
|
||||
const auto HASH = STATE["repository"]["hash"].value_or("");
|
||||
|
||||
SPluginRepository repo;
|
||||
repo.hash = HASH;
|
||||
repo.name = NAME;
|
||||
repo.url = URL;
|
||||
repo.rev = REV;
|
||||
|
||||
for (const auto& [key, val] : STATE) {
|
||||
if (key == "repository")
|
||||
|
Reference in New Issue
Block a user