summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndrew Cady <d@cryptonomic.net>2021-10-25 06:29:07 -0400
committerAndrew Cady <d@cryptonomic.net>2021-10-25 10:03:35 -0400
commit7cbe854c63dc698e7bf9bb65d01f5f097ff08ea6 (patch)
treede4db8f5b7deef4e4044826dae10c1ebe0ee2786
parent895dc23f69939ce8c96a6aff55a798d8e204c75b (diff)
improve error message
-rwxr-xr-xEndoForge/src/AnonymousAccessCommand16
1 files changed, 15 insertions, 1 deletions
diff --git a/EndoForge/src/AnonymousAccessCommand b/EndoForge/src/AnonymousAccessCommand
index ffdc07a..082f185 100755
--- a/EndoForge/src/AnonymousAccessCommand
+++ b/EndoForge/src/AnonymousAccessCommand
@@ -12,6 +12,20 @@ default_msg()
12EOF 12EOF
13} 13}
14 14
15not_self_forge_message()
16{
17 cat <<EOF >&2
18Error: access denied. The specified directory is not a self-forge.
19
20 To enable anonymous access, use the following commands:
21
22 ssh $(id -un)@$(hostname)
23 cd "$1"
24 git config core.self-forge true
25
26EOF
27}
28
15get_sshfp_authline() 29get_sshfp_authline()
16{ 30{
17 ( 31 (
@@ -109,7 +123,7 @@ fi
109 123
110if ! is_self_forge "$dir" 124if ! is_self_forge "$dir"
111then 125then
112 echo 'Error: access denied. The specified directory is not a self-forge.' >&2 126 not_self_forge_message "$arg"
113 exit 127 exit
114fi 128fi
115 129