initialize

package
v0.47.0 Latest Latest
Warning

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

Go to latest
Published: Apr 21, 2025 License: MIT Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var AllAppTypes = []AppType{
	AppTypeAPI,
	AppTypeWeb,
}

Functions

func Run added in v0.35.0

func Run(cfg *Config) error

Types

type AppType

type AppType string
const (
	AppTypeAPI AppType = "api"
	AppTypeWeb AppType = "web"
)

func (AppType) IsValid

func (t AppType) IsValid() bool

type BackgroundJob added in v0.40.0

type BackgroundJob string
const (
	BackgroundJobBasic BackgroundJob = "basic"
	BackgroundJobSQS   BackgroundJob = "sqs"
	BackgroundJobAsynq BackgroundJob = "asynq"
	BackgroundJobNone  BackgroundJob = "none"
)

func (BackgroundJob) IsValid added in v0.40.0

func (t BackgroundJob) IsValid() bool

type Command

type Command struct {
	Message string
	Name    string
	Args    []string
}

type Config

type Config struct {
	Quiet         bool
	Name          string
	Database      Database
	AppType       AppType
	BackgroundJob BackgroundJob
	OutputDir     string

	NoSMTP    bool
	NoStorage bool
	NoAuth    bool
	NoGit     bool
	NoRedis   bool
}

type Database

type Database string
const (
	DatabaseSQLite3  Database = "sqlite3"
	DatabasePostgres Database = "postgres"
	DatabaseMySQL    Database = "mysql"
	DatabaseNone     Database = "none"
)

func (Database) ConnString

func (d Database) ConnString(projectName string) string

func (Database) Driver

func (d Database) Driver() string

func (Database) Import

func (d Database) Import() string

func (Database) IsValid

func (d Database) IsValid() bool

func (Database) SQLCEngine

func (d Database) SQLCEngine() string

func (Database) String

func (d Database) String() string

type FileExclusions

type FileExclusions struct {
	NoSMTP          []string
	NoStorage       []string
	NoRedis         []string
	NoAuth          []string
	ByAppType       map[AppType][]string
	ByDatabase      map[Database][]string
	ByBackgroundJob map[BackgroundJob][]string
}

type FileRenames

type FileRenames struct {
	ByAppType map[AppType]map[string]string
}

type Project

type Project struct {
	Name          string
	Database      Database
	BackgroundJob BackgroundJob
	AppType       AppType
	SMTP          bool
	Storage       bool
	Auth          bool
	Redis         bool
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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