configs

package
v1.0.3 Latest Latest
Warning

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

Go to latest
Published: Apr 1, 2024 License: Apache-2.0 Imports: 17 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetDefaultPrinter

func GetDefaultPrinter() pkg.Printer

func InitiateDatabaseConnection added in v0.2.0

func InitiateDatabaseConnection(ctx context.Context) error

Types

type DBConfigArangoDB

type DBConfigArangoDB struct {
	Name     string `json:"name" yaml:"name"`
	Host     string `json:"host" yaml:"host"`
	Port     string `json:"port" yaml:"port"`
	User     string `json:"user" yaml:"user"`
	Password string `json:"password" yaml:"password"`
}

type DBConfigPostgres

type DBConfigPostgres struct {
	Name     string `json:"name" yaml:"name"`
	Host     string `json:"host" yaml:"host"`
	Port     string `json:"port" yaml:"port"`
	User     string `json:"user" yaml:"user"`
	Password string `json:"password" yaml:"password"`
	SSLMode  string `json:"sslmode" yaml:"sslmode"`
}

func (DBConfigPostgres) String

func (cp DBConfigPostgres) String() string

type DBConfigSQLite added in v0.2.0

type DBConfigSQLite struct {
	SyncToDrive          bool          `json:"syncToDrive" yaml:"syncToDrive"`
	DisableSyncFromDrive bool          `json:"disableSyncFromDrive" yaml:"disableSyncFromDrive"`
	SyncInterval         time.Duration `json:"syncInterval" yaml:"syncInterval"`
}

type DatabaseConfig

type DatabaseConfig struct {
	Type DatabaseType `json:"type" yaml:"type"`

	//ArangoDB DBConfigArangoDB `json:"arangodb" yaml:"arangodb"`
	Postgres lib.PostgresConfig `json:"postgres" yaml:"postgres"`
	SQLite   DBConfigSQLite     `json:"sqlite" yaml:"sqlite"`
}

type DatabaseType

type DatabaseType string
const (
	DatabaseArangoDB DatabaseType = "arangodb"
	DatabasePostgres DatabaseType = "postgres"
	DatabaseSQLite   DatabaseType = "sqlite"
	DatabaseSupabase DatabaseType = "supabase"
)

type ExpenseConfiguration added in v0.2.0

type ExpenseConfiguration struct {
	Telegram Telegram       `json:"telegram" yaml:"telegram"`
	Database DatabaseConfig `json:"database" yaml:"database"`
}
var TrackerConfig ExpenseConfiguration

type Telegram added in v0.2.4

type Telegram struct {
	User   string `json:"user" yaml:"user"`
	Secret string `json:"secret" yaml:"secret"`
}

Jump to

Keyboard shortcuts

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