Changeset 77 in code


Ignore:
Timestamp:
Dec 4, 2023, 5:21:08 PM (18 months ago)
Author:
Izuru Yakumo
Message:

Passed through golint only to get a load of garbage

Signed-off-by: Izuru Yakumo <yakumo.izuru@…>

Location:
trunk
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • trunk/LICENSE

    r56 r77  
    11The MIT License (MIT)
    22
    3 Copyright (c) 2014 zserge
    4 Copyright (c) 2023 Izuru Yakumo
     3Copyright (c) 2014 Serge Zaitsev <hello@zserge.com>
     4Copyright (c) 2023 Izuru Yakumo <yakumo.izuru@chaotic.ninja>
    55
    66Permission is hereby granted, free of charge, to any person obtaining a copy
     
    2121OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
    2222SOFTWARE.
    23 
  • trunk/cmd/aya/main.go

    r76 r77  
    1 // $TheSupernovaDuo: marisa.chaotic.ninja/aya/cmd/aya, v0.6.7 2023-12-04 01:55:36+0000, yakumo_izuru Exp $
     1// $TheSupernovaDuo: marisa.chaotic.ninja/aya/cmd/aya, v0.6.8 2023-12-04 15:43:44+0000, yakumo_izuru Exp $
    22package main
    33
     
    142142// Render expanding aya plugins and variables
    143143func render(s string, vars Vars) (string, error) {
    144         delim_open := "{{"
    145         delim_close := "}}"
     144        delimOpen := "{{"
     145        delimClose := "}}"
    146146
    147147        out := &bytes.Buffer{}
    148148        for {
    149                 if from := strings.Index(s, delim_open); from == -1 {
     149                if from := strings.Index(s, delimOpen); from == -1 {
    150150                        out.WriteString(s)
    151151                        return out.String(), nil
    152152                } else {
    153                         if to := strings.Index(s, delim_close); to == -1 {
    154                                 return "", fmt.Errorf("Close delim not found")
     153                        if to := strings.Index(s, delimClose); to == -1 {
     154                                return "", fmt.Errorf("Closing delimiter not found")
    155155                        } else {
    156156                                out.WriteString(s[:from])
    157                                 cmd := s[from+len(delim_open) : to]
    158                                 s = s[to+len(delim_close):]
     157                                cmd := s[from+len(delimOpen) : to]
     158                                s = s[to+len(delimClose):]
    159159                                m := strings.Fields(cmd)
    160160                                if len(m) == 1 {
     
    309309        if ext == ".md" || ext == ".mkd" || ext == ".markdown" {
    310310                return buildMarkdown(path, w, vars)
    311         } else if ext == ".html" || ext == ".xml" {
     311        } else if ext == ".htm" || ext == ".html" || ext == ".xht" || ext == ".xhtml" {
    312312                return buildHTML(path, w, vars)
    313313        } else if ext == ".amber" {
  • trunk/doc.go

    r72 r77  
    1717// This one (re)incorporates the features removed in the former from the latter
    1818
    19 // Copyright (c) 2014 Serge Zaitsev
    20 // Copyright (c) 2023 Izuru Yakumo
     19// Copyright (c) 2014 Serge Zaitsev <hello@zserge.com>
     20// Copyright (c) 2023 Izuru Yakumo <yakumo.izuru@chaotic.ninja>
    2121
    2222// Ayaya~
  • trunk/version.go

    r76 r77  
    99var (
    1010        // Set to current tag
    11         Version = "v0.6.7"
     11        Version = "v0.6.8"
    1212        Time = time.Now()
    1313)
Note: See TracChangeset for help on using the changeset viewer.