summaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
Diffstat (limited to 'lib')
-rw-r--r--lib/metadata.sh18
1 files changed, 17 insertions, 1 deletions
diff --git a/lib/metadata.sh b/lib/metadata.sh
index 30aa018..d635e8e 100644
--- a/lib/metadata.sh
+++ b/lib/metadata.sh
@@ -1,6 +1,6 @@
# Functions for parsing and validating package metadata
#
-# Copyright (C) 2012, 2014 Patrick McDermott
+# Copyright (C) 2012, 2014, 2018 Patrick McDermott
#
# This file is part of opkbuild.
#
@@ -29,6 +29,14 @@ _ob_metadata_do()
return ${?}
}
+## @brief Validate a source package name
+## @details \fBob_validate_source_name\fP validates a source package name
+## against the rules of the metadata plugin selected at libopkbuild's
+## build time.
+## @operand name req The source package name to validate.
+## @return Returns 0 if valid, 1 if invalid, or 125 if given an incorrect number
+## of arguments.
+## @pure yes This function has no side effects.
ob_validate_source_name()
{
local name=
@@ -44,6 +52,14 @@ ob_validate_source_name()
return ${?}
}
+## @brief Validate a binary package name
+## @details \fBob_validate_binary_name\fP validates a binary package name
+## against the rules of the metadata plugin selected at libopkbuild's
+## build time.
+## @operand name req The binary package name to validate.
+## @return Returns 0 if valid, 1 if invalid, or 125 if given an incorrect number
+## of arguments.
+## @pure yes This function has no side effects.
ob_validate_binary_name()
{
local name=