config

package module
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Dec 4, 2025 License: MIT Imports: 6 Imported by: 5

README

appsap-config

Getting Started

Config lib for appsap-core framework

Installation

Run the following command to install the package:

go get github.com/mortired/appsap-config

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetEnvAsBoolOrDefault

func GetEnvAsBoolOrDefault(key string, defaultValue bool) bool

GetEnvAsBoolOrDefault returns environment variable value as bool or default value

func GetEnvAsIntOrDefault

func GetEnvAsIntOrDefault(key string, defaultValue int) int

GetEnvAsIntOrDefault returns environment variable value as int or default value

func GetEnvAsIntRequired

func GetEnvAsIntRequired(key string) (int, error)

GetEnvAsIntRequired returns environment variable value as int or error if not set

func GetEnvOrDefault

func GetEnvOrDefault(key, defaultValue string) string

GetEnvOrDefault returns environment variable value or default value

func GetEnvRequired

func GetEnvRequired(key string) (string, error)

GetEnvRequired returns environment variable value or error if not set

func LoadEnv

func LoadEnv() error

LoadEnv loads environment variables from .env file if it exists This function is kept for backward compatibility

Types

This section is empty.

Jump to

Keyboard shortcuts

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