settings

package
v0.0.0-...-835c9c4 Latest Latest
Warning

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

Go to latest
Published: Mar 6, 2021 License: MIT Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Host

func Host() string

Host returns the host of the application

func Initialize

func Initialize() error

Initialize should only be called at the start of the program

func OneTimeSyncSlug

func OneTimeSyncSlug() string

OneTimeSyncSlug returns the current sync_once settings

func RegenerateOneTimeSyncSlug

func RegenerateOneTimeSyncSlug(c buffalo.Context) (string, error)

RegenerateOneTimeSyncSlug updates the sync_once global settings

func Script

func Script() string

Script returns the current script settings

func SetHost

func SetHost(url string)

SetHost stores the host application

func Sheet

func Sheet() string

Sheet returns the current sheet settings

func UpdateScript

func UpdateScript(c buffalo.Context, script string) error

UpdateScript updates the script global settings

func UpdateSheet

func UpdateSheet(c buffalo.Context, sheet string) error

UpdateSheet updates the sheet global settings

Types

type Serializable

type Serializable interface {
	json.Marshaler
	json.Unmarshaler
}

Serializable ensures that settings implement the json.Marshaler and json.Unmarshaler interfaces

func SerializableSettings

func SerializableSettings() Serializable

SerializableSettings returns a reference to the settings that can be used (only) for serialization -- the serialization functions are already guarded by a mutex, so this should be ok to pass around.

Jump to

Keyboard shortcuts

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