summaryrefslogtreecommitdiff
path: root/configure
diff options
context:
space:
mode:
authorvutral <vutral@vutral.ano>2011-02-03 08:58:44 +0100
committervutral <vutral@vutral.ano>2011-02-03 08:58:44 +0100
commit503c1603d591817d8d02d66f5dfdf5132bb42fd3 (patch)
treedbb0eb3889f845f5f02b4f418dc6a1bc213990b7 /configure
parente540c8edbfccbfa3201f1387c0864de94f4384ff (diff)
parent3266eb68b87721a5dca7b54cabc1e866b48828a8 (diff)
downloadresdb-503c1603d591817d8d02d66f5dfdf5132bb42fd3.tar.gz
resdb-503c1603d591817d8d02d66f5dfdf5132bb42fd3.zip
Merge branch 'master' of git://1.0.27.102
Diffstat (limited to 'configure')
-rwxr-xr-xconfigure32
1 files changed, 31 insertions, 1 deletions
diff --git a/configure b/configure
index c8823dc..9f6c8c0 100755
--- a/configure
+++ b/configure
@@ -1,6 +1,6 @@
#!/bin/sh
-vars="gitd_ip gitd_basepath tinydns_config tinydns__tldsrvrname tinydns__tldsrvrip"
+vars="gitd_ip gitd_basepath git_name git_email tinydns_config tinydns__tldsrvrname tinydns__tldsrvrip"
echo "Welcome to the resdb configurator!" >&2
echo >&2
@@ -11,6 +11,12 @@ done
if [ x"$gitd_basepath" = x ]; then
gitd_basepath="$(pwd)/"
fi
+if [ x"$git_name" = x ]; then
+ git_name="Anonymous Coward"
+fi
+if [ x"$git_email" = x ]; then
+ git_email="nobody@nowhere"
+fi
if [ x"$tinydns_config" = x ]; then
tinydns_config=n
fi
@@ -37,6 +43,22 @@ if [ x"$new_gitd_basepath" != x ]; then
gitd_basepath="$new_gitd_basepath"
fi
+echo "Please enter your name." >&2
+echo "(Default: $git_name)" >&2
+echo -n "Name? " >&2
+read new_git_name
+if [ x"$new_git_name" != x ]; then
+ git_name="$new_git_name"
+fi
+
+echo "Please enter your email." >&2
+echo "(Default: $git_email)" >&2
+echo -n "Email? " >&2
+read new_git_email
+if [ x"$new_git_email" != x ]; then
+ git_email="$new_git_email"
+fi
+
echo -n "Would you like to configure the tinydns datafile generator? " >&2
read new_tinydns_config
if [ x"$new_tinydns_config" != x ]; then
@@ -67,7 +89,15 @@ done
echo -n "To write the configuration, hit RETURN. To abort, hit ^C: " >&2
read write_config
+echo -n "Writing configuration... " >&2
mkdir -p conf || exit 1
for var in $vars ; do
echo "${!var}" > conf/"$var" || exit 1
done
+echo "Done" >&2
+
+echo -n "Updating git configuration... " >&2
+cd "$(cat ./conf/gitd_basepath)" || exit 1
+git config user.name "$(cat ./conf/git_name)" || exit 1
+git config user.email "$(cat ./conf/git_email)" || exit 1
+echo "Done" >&2