pgs

package
v1.13.1 Latest Latest
Warning

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

Go to latest
Published: Feb 19, 2024 License: MIT Imports: 52 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AssetRequest added in v1.10.0

func AssetRequest(w http.ResponseWriter, r *http.Request)

func CmsMiddleware

func CmsMiddleware(cfg *config.ConfigCms, urls config.ConfigURL) bm.Handler

func ImgAssetRequest added in v1.11.0

func ImgAssetRequest(w http.ResponseWriter, r *http.Request)

func NewConfigSite

func NewConfigSite() *shared.ConfigSite

func NewSpinner

func NewSpinner() spinner.Model

func ServeAsset added in v1.10.0

func ServeAsset(fname string, opts *storage.ImgProcessOpts, fromImgs bool, w http.ResponseWriter, r *http.Request)

func StartApiServer

func StartApiServer()

func StartSshServer

func StartSshServer()

func WishMiddleware

func WishMiddleware(handler *uploadassets.UploadAssetHandler) wish.Middleware

Types

type AssetHandler

type AssetHandler struct {
	Username       string
	Subdomain      string
	Filepath       string
	ProjectDir     string
	Cfg            *shared.ConfigSite
	Dbpool         db.DB
	Storage        storage.StorageServe
	Logger         *slog.Logger
	Cache          *gocache.Cache
	UserID         string
	Bucket         sst.Bucket
	ImgProcessOpts *storage.ImgProcessOpts
}

type Cmd

type Cmd struct {
	User    *db.User
	Session CmdSession
	Log     *slog.Logger
	Store   storage.StorageServe
	Dbpool  db.DB
	Write   bool
}

func (*Cmd) RmProjectAssets added in v1.6.0

func (c *Cmd) RmProjectAssets(projectName string) error

type CmdSession added in v1.6.0

type CmdSession interface {
	Write([]byte) (int, error)
	Exit(code int) error
	Close() error
	Stderr() io.ReadWriter
}

type CmdSessionLogger added in v1.6.0

type CmdSessionLogger struct {
	Log *slog.Logger
}

func (*CmdSessionLogger) Close added in v1.6.0

func (c *CmdSessionLogger) Close() error

func (*CmdSessionLogger) Exit added in v1.6.0

func (c *CmdSessionLogger) Exit(code int) error

func (*CmdSessionLogger) Stderr added in v1.6.0

func (c *CmdSessionLogger) Stderr() io.ReadWriter

func (*CmdSessionLogger) Write added in v1.6.0

func (c *CmdSessionLogger) Write(out []byte) (int, error)

type GotDBMsg

type GotDBMsg db.DB

type HttpReply

type HttpReply struct {
	Filepath string
	Query    map[string]string
	Status   int
}

type RedirectRule

type RedirectRule struct {
	From       string
	To         string
	Status     int
	Query      map[string]string
	Conditions map[string]string
	Force      bool
	Signed     bool
}

type RssData

type RssData struct {
	Contents template.HTML
}

type SSHServer

type SSHServer struct{}

type SubdomainProps

type SubdomainProps struct {
	ProjectName string
	Username    string
}

Jump to

Keyboard shortcuts

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