jojomi / tplfuncs

Go module with some useful template.FuncMap goodies

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Go Report Card

tplfuncs

Go module with some useful template.FuncMap goodies

Documentation

Areas of concern

  • Spacing (newline and space)
  • Lines (line-wise processing of input string using trim, head, tail, and more)
  • Filesystem (glob, ensureDir, fileExists, dirExists, ensureDir, isMinFileSize)
  • Exec (command execution and output capturing)
  • Strings (string casing, making safe filenames and URLs, stringContains)
  • IO (readFile, include, writeFile)
  • Hashing (sha1, sha256)
  • Env (envIsSet, env, envEq)
  • HTML (safeHTML, safeCSS, safeJS)

Who uses it?

io

About

Go module with some useful template.FuncMap goodies

License:MIT License


Languages

Language:Go 91.1%Language:Smarty 7.5%Language:Shell 1.4%