changeset 76:e8eb1fdb4b03 draft

Passed through golint only to get a load of garbage Signed-off-by: Izuru Yakumo <yakumo.izuru@chaotic.ninja>
author yakumo.izuru
date Mon, 04 Dec 2023 17:21:08 +0000
parents 84270933ac8d
children e1f9fda6986a
files LICENSE cmd/aya/main.go doc.go version.go
diffstat 4 files changed, 14 insertions(+), 15 deletions(-) [+]
line wrap: on
line diff
--- a/LICENSE	Mon Dec 04 02:21:03 2023 +0000
+++ b/LICENSE	Mon Dec 04 17:21:08 2023 +0000
@@ -1,7 +1,7 @@
 The MIT License (MIT)
 
-Copyright (c) 2014 zserge
-Copyright (c) 2023 Izuru Yakumo
+Copyright (c) 2014 Serge Zaitsev <hello@zserge.com>
+Copyright (c) 2023 Izuru Yakumo <yakumo.izuru@chaotic.ninja>
 
 Permission is hereby granted, free of charge, to any person obtaining a copy
 of this software and associated documentation files (the "Software"), to deal
@@ -20,4 +20,3 @@
 LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
 OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
 SOFTWARE.
-
--- a/cmd/aya/main.go	Mon Dec 04 02:21:03 2023 +0000
+++ b/cmd/aya/main.go	Mon Dec 04 17:21:08 2023 +0000
@@ -1,4 +1,4 @@
-// $TheSupernovaDuo: marisa.chaotic.ninja/aya/cmd/aya, v0.6.7 2023-12-04 01:55:36+0000, yakumo_izuru Exp $
+// $TheSupernovaDuo: marisa.chaotic.ninja/aya/cmd/aya, v0.6.8 2023-12-04 15:43:44+0000, yakumo_izuru Exp $
 package main
 
 import (
@@ -141,21 +141,21 @@
 
 // Render expanding aya plugins and variables
 func render(s string, vars Vars) (string, error) {
-	delim_open := "{{"
-	delim_close := "}}"
+	delimOpen := "{{"
+	delimClose := "}}"
 
 	out := &bytes.Buffer{}
 	for {
-		if from := strings.Index(s, delim_open); from == -1 {
+		if from := strings.Index(s, delimOpen); from == -1 {
 			out.WriteString(s)
 			return out.String(), nil
 		} else {
-			if to := strings.Index(s, delim_close); to == -1 {
-				return "", fmt.Errorf("Close delim not found")
+			if to := strings.Index(s, delimClose); to == -1 {
+				return "", fmt.Errorf("Closing delimiter not found")
 			} else {
 				out.WriteString(s[:from])
-				cmd := s[from+len(delim_open) : to]
-				s = s[to+len(delim_close):]
+				cmd := s[from+len(delimOpen) : to]
+				s = s[to+len(delimClose):]
 				m := strings.Fields(cmd)
 				if len(m) == 1 {
 					if v, ok := vars[m[0]]; ok {
@@ -308,7 +308,7 @@
 	ext := filepath.Ext(path)
 	if ext == ".md" || ext == ".mkd" || ext == ".markdown" {
 		return buildMarkdown(path, w, vars)
-	} else if ext == ".html" || ext == ".xml" {
+	} else if ext == ".htm" || ext == ".html" || ext == ".xht" || ext == ".xhtml" {
 		return buildHTML(path, w, vars)
 	} else if ext == ".amber" {
 		return buildAmber(path, w, vars)
--- a/doc.go	Mon Dec 04 02:21:03 2023 +0000
+++ b/doc.go	Mon Dec 04 17:21:08 2023 +0000
@@ -16,8 +16,8 @@
 // This is a hard fork of git.mills.io/prologic/zs, which in turn is a fork of zserge's zs
 // This one (re)incorporates the features removed in the former from the latter
 
-// Copyright (c) 2014 Serge Zaitsev
-// Copyright (c) 2023 Izuru Yakumo
+// Copyright (c) 2014 Serge Zaitsev <hello@zserge.com>
+// Copyright (c) 2023 Izuru Yakumo <yakumo.izuru@chaotic.ninja>
 
 // Ayaya~
 package aya
--- a/version.go	Mon Dec 04 02:21:03 2023 +0000
+++ b/version.go	Mon Dec 04 17:21:08 2023 +0000
@@ -8,7 +8,7 @@
 
 var (
 	// Set to current tag
-	Version = "v0.6.7"
+	Version = "v0.6.8"
 	Time = time.Now()
 )