2016-02-22 17:32:12 +01:00
|
|
|
#!/bin/bash
|
|
|
|
#
|
|
|
|
# This program is free software; you can redistribute it and/or modify
|
|
|
|
# it under the terms of the GNU General Public License as published by
|
|
|
|
# the Free Software Foundation; version 2 of the License.
|
|
|
|
#
|
|
|
|
# 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 General Public License for more details.
|
|
|
|
|
|
|
|
version=@version@
|
|
|
|
|
|
|
|
LIBDIR='@libdir@'
|
|
|
|
|
|
|
|
[[ -r ${LIBDIR}/util-msg.sh ]] && source ${LIBDIR}/util-msg.sh
|
|
|
|
|
|
|
|
import ${LIBDIR}/util.sh
|
|
|
|
|
2017-04-20 15:24:23 +02:00
|
|
|
load_user_info
|
|
|
|
|
2017-04-19 20:37:01 +02:00
|
|
|
load_vars "${PAC_USERCONFDIR}/makepkg.conf" || load_vars "$USER_HOME/.makepkg.conf"
|
2016-02-22 17:32:12 +01:00
|
|
|
load_vars /etc/makepkg.conf
|
|
|
|
|
|
|
|
if [ ! -e "$1" ]; then
|
2016-09-15 23:58:18 +02:00
|
|
|
error "%s does not exist!" "$1"
|
|
|
|
exit 1
|
2016-02-22 17:32:12 +01:00
|
|
|
fi
|
|
|
|
|
2016-06-08 23:02:51 +02:00
|
|
|
msg2 "Signing [%s] with key %s" "${1##*/}" "${GPGKEY}..."
|
2016-02-22 17:32:12 +01:00
|
|
|
gpg --detach-sign --use-agent -u "${GPGKEY}" "$1"
|