Categorygithub.com/nielskrijger/goutils
modulepackage
0.0.0-20210824130942-9d149b61c5e2
Repository: https://github.com/nielskrijger/goutils.git
Documentation: pkg.go.dev

# README

gotils

WARNING: This repo not intended for public use and has no versioning applied. So be warned: things can break between commits.

goutils is a collection of random bits & pieces I've been using across projects.

Development

This codebase contains a combination of integration and unit tests.

To run all of them in a human-readable way use:

$ make humantest

This requires richgo to be installed.

See the project's Makefile for other (more standard) commands.

# Packages

nolint:wrapcheck.
Package validator implements value validations Copyright 2014 Roberto Teixeira <[email protected]> Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License.

# Functions

Close is a simple utility used to log error messages riased during a deferred closing function.
GenerateRandomBytes returns securely generated random bytes.
GenerateRandomString returns a URL-safe, base64 encoded random string.
GenerateShortID returns a base58-encoded UUID which is 22 characters long.
No description provided by the author
NewTemplateLoader creates a Loader with the recommended layouts directory "/layouts" and partials directory "/partials".

# Structs

No description provided by the author
Loader loads layout, partial and template files from a specified directory.
No description provided by the author