embed

package
v0.0.6 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 26, 2024 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Overview

Package embed provides utility functions for the embedded file system.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func PrintTableTemplate

func PrintTableTemplate(out io.Writer, args interface{}, dir, filename string) error

PrintTableTemplate renders a tabular data template and flushes it to stdout.

func ReadFile

func ReadFile(dir, filename string) ([]byte, error)

ReadFile reads a file from the embedded file system.

func RenderTemplate

func RenderTemplate(args interface{}, dir, filename, outputPath string) error

RenderTemplate renders a template from the embedded file system and writes it to disk.

func RenderTemplateBytes

func RenderTemplateBytes(args interface{}, dir, filename string) ([]byte, error)

RenderTemplateBytes renders a template from the embedded file system and returns the resulting bytes.

func WriteFile

func WriteFile(outFilename string, data []byte) error

WriteFile Writes bytes to the specified file.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL