Initial gopher validator commit. - gopher-validator - Gopher validator and happ… | |
git clone git://git.codemadness.org/gopher-validator | |
Log | |
Files | |
Refs | |
README | |
LICENSE | |
--- | |
commit 152b7ffd60ace3f18a6cfd667432437c4e6aa69c | |
Author: Christoph Lohmann <[email protected]> | |
Date: Wed, 18 Jul 2018 23:21:41 +0200 | |
Initial gopher validator commit. | |
Diffstat: | |
A gopher-validator | 9 +++++++++ | |
1 file changed, 9 insertions(+), 0 deletions(-) | |
--- | |
diff --git a/gopher-validator b/gopher-validator | |
@@ -0,0 +1,9 @@ | |
+#!/bin/sh | |
+ | |
+result="$(sacc "$@" | grep "^!")" | |
+ | |
+[ -z "$result" ] && printf "valid\n" && exit 0 | |
+ | |
+printf "invalid\n" | |
+exit 1 | |
+ |