summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHugo Hörnquist <hugo@lysator.liu.se>2022-10-11 02:25:41 +0200
committerHugo Hörnquist <hugo@lysator.liu.se>2022-10-11 02:25:41 +0200
commit066bcc649f175fc69b0e5476881618cf5b2b973a (patch)
tree2c1e9d10848aa4b5cda65d6257010f99df60a5e9
parentLoad public repos from file. (diff)
downloadcgit-filters-066bcc649f175fc69b0e5476881618cf5b2b973a.tar.gz
cgit-filters-066bcc649f175fc69b0e5476881618cf5b2b973a.tar.xz
Fix silly mistakes.
-rw-r--r--hugo-authentication.lua4
-rwxr-xr-xhugo-pre.sh2
2 files changed, 3 insertions, 3 deletions
diff --git a/hugo-authentication.lua b/hugo-authentication.lua
index 83a2c96..28343ef 100644
--- a/hugo-authentication.lua
+++ b/hugo-authentication.lua
@@ -24,8 +24,8 @@ local protected_repos = {
}
local public_repos = {}
-public_repo_file = open('/usr/local/var/public-repos')
-while data != nil do
+public_repo_file = io.open('/usr/local/var/public-repos')
+while data ~= nil do
public_repos[data] = true
data = public_repo_file:read()
end
diff --git a/hugo-pre.sh b/hugo-pre.sh
index dfc4a9a..e089d1d 100755
--- a/hugo-pre.sh
+++ b/hugo-pre.sh
@@ -4,7 +4,7 @@ name=$1
case $name in
*.md) pandoc -f gfm -t html ;;
- *.wiki) pandoc -f vimwiki -t html --table-of-contents
+ *.wiki) pandoc -f vimwiki -t html --table-of-contents ;;
*)
cat <<- EOF
<pre>$(cat -)</pre>