mirror of
https://github.com/coolsnowwolf/packages.git
synced 2025-05-02 05:10:41 +08:00
23 lines
545 B
C++
23 lines
545 B
C++
#include <iostream>
|
|
#include <mutex>
|
|
#include <string>
|
|
#include <string_view>
|
|
#include <vector>
|
|
|
|
#include "uci-cxx.hpp"
|
|
|
|
auto main() -> int
|
|
{
|
|
uci::element p = uci::package{"nginx"};
|
|
std::cout << "package " << p.name() << "\n\n";
|
|
for (auto s : p) {
|
|
std::cout << "config " << s.type() << " '" << s.name() << "'\n";
|
|
for (auto o : s) {
|
|
for (auto i : o) {
|
|
std::cout << "\t" << o.type() << " " << o.name() << " '" << i.name() << "'\n";
|
|
}
|
|
}
|
|
std::cout << "\n";
|
|
}
|
|
}
|