From 3a147a8809893afcee9a52f8e37e83dce5bd26a2 Mon Sep 17 00:00:00 2001 From: Michael Orlitzky Date: Thu, 2 Jun 2016 10:42:34 -0400 Subject: [PATCH 2/4] eclass-writing: add documentation to the first existing example. Now that we have guidelines for documenting eclasses, the "Simple Common Functions Eclass Example" section is under-documented. This commit adds the minimum required documentation (eclass and function headers) to that example. Gentoo-Bug: 373145 --- eclass-writing/text.xml | 21 +++++++++++---------- 1 file changed, 11 insertions(+), 10 deletions(-) diff --git a/eclass-writing/text.xml b/eclass-writing/text.xml index 488230d..518cf2a 100644 --- a/eclass-writing/text.xml +++ b/eclass-writing/text.xml @@ -251,18 +251,19 @@ a single function, domacosapp. # Distributed under the terms of the GNU General Public License v2 # $Id$ -# -# Original Author: Ciaran McCreesh <ciaranm@gentoo.org> -# Purpose: install macos .app files to the relevant location. -# -# Bugs to osx@gentoo.org -# - -# domacosapp: install a macos .app file. Usage is 'domacosapp file' or -# 'domacosapp file newfile'. +# @ECLASS: macosapp.eclass +# @MAINTAINER: +# Ciaran McCreesh <ciaranm@gentoo.org> +# @BLURB: install macos .app files to the relevant location. +# @FUNCTION: domacosapp +# @USAGE: <app-file> [new-file] +# @DESCRIPTION: +# Install the given .app file into the appropriate location. If +# [new-file] is given, it will be used as the new (installed) name of +# the file. Otherwise <app-file> is installed as-is. domacosapp() { - [[ -z "${1}" ]] && die "usage: domacosapp <file> <new file>" + [[ -z "${1}" ]] && die "usage: domacosapp <file> [new file]" if use ppc-macos ; then insinto /Applications newins "$1" "${2:-${1}}" || die "Failed to install ${1}" -- 2.7.3