From 41bc6380d0a6f683fd8c8707eaa205e8bbd2339f Mon Sep 17 00:00:00 2001 From: unknown Date: Thu, 11 Aug 2011 15:29:27 -0500 Subject: [PATCH] Import version as of 2011-08-11 for ftp-addkey.sh --- ftp-addkey.sh | 35 +++++++++++++++++++++++++++++++++++ 1 file changed, 35 insertions(+) create mode 100755 ftp-addkey.sh diff --git a/ftp-addkey.sh b/ftp-addkey.sh new file mode 100755 index 0000000..6be3215 --- /dev/null +++ b/ftp-addkey.sh @@ -0,0 +1,35 @@ +#!/bin/bash +# +# Adds a specified user & their key to the maintainer keyring on +# ftp.gnu.org. +# + +PACKAGES=/home/gatekpr/packages + +if ( ([ "$1" = "" ]) || ([ "$2" = "" ]) || ([ "$3" = "" ]) ) +then + echo "ftp-addkey.sh " + exit +fi + +if ! [ -d $PACKAGES/$1 ] +then + echo "$1 is a new package. Creating a directory for it." + mkdir $PACKAGES/$1 +fi + +# Add email address to list of maintainers + +echo "Adding $2 to maintainer list." +echo $2 >> $PACKAGES/$1/email + +# Import keys + +echo "Adding key..." + +pgpg $1 --import $3 + +chmod -R 755 $PACKAGES/$1 + +echo "Done." + -- 2.25.1