added packages to the prereq list since we are not building them with the global...
[lxqt-slackware.git] / slack-desc / make_slack-desc.sh
CommitLineData
73c8ba7d 1#!/bin/bash
2#
3# Parameter #1: packagename
4#
5if [ -z "$1" ]; then
6 echo "Need package name as 1st parameter!"
7 exit 1
8fi
9PRGNAM="$1"
10
11if [ -f "$PRGNAM" ]; then
12 echo "A slack-desc file with name '$PRGNAM' already exists, will not overwrite!"
13 exit 1
14fi
15
16HOMEPAGE=${HOMEPAGE:-"https://github.com/lxqt/lxqt"}
17DESCR=${DESCR:-"short description here"}
18MAXDESCR=$(( 70-3-${#PRGNAM} ))
19if [ ${#DESCR} -gt $MAXDESCR ]; then
20 DESCR=${DESCR:0:$MAXDESCR}
21fi
22
23SPCS=""; while [ ${#SPCS} -lt ${#PRGNAM} ]; do SPCS=" $SPCS";done
24
25cat <<EOT > "$PRGNAM"
26# HOW TO EDIT THIS FILE:
27# The "handy ruler" below makes it easier to edit a package description. Line
28# up the first '|' above the ':' following the base package name, and the '|'
29# on the right side marks the last column you can put a character in. You must
30# make exactly 11 lines for the formatting to be correct. It's also
31# customary to leave one space after the ':'.
32
33${SPCS}|-----handy-ruler------------------------------------------------------|
34${PRGNAM}: ${PRGNAM}
35${PRGNAM}: ${DESCR}
36${PRGNAM}:
37${PRGNAM}:
38${PRGNAM}:
39${PRGNAM}:
406a654f 40${PRGNAM}: This package is part of LXQT 0.16.0
73c8ba7d 41${PRGNAM}: Mantainer: danix < danix@danix.xyz >
42${PRGNAM}:
43${PRGNAM}: Home page: ${HOMEPAGE}
44${PRGNAM}:
45EOT