/** * @file version.hpp * @brief X.Y.Z version parsing * * @copyright Copyright (c) 2026 SILO GROUP LLC * @author Chris Punches * * Part of the Dark Horse Linux Package Manager (DPM) * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU Affero General Public License as * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU Affero General Public License for more details. * * You should have received a copy of the GNU Affero General Public License * along with this program. If not, see . */ #pragma once namespace dpmcore { /** * @brief Parses a strict X.Y.Z version string * * @param s The version string * @param out Receives the three parsed components * @return true on success; false on any malformation */ bool parse_version(const char* s, long out[3]); } // namespace dpmcore