Documentation ¶
Index ¶
- Constants
- type AddUIComponentOpts
- type MakeControllerOpts
- type MakeMigrationOpts
- type MakeModelOpts
- type MakeRepositoryOpts
- type MakeValidatorOpts
- type ReadFileContentsOpts
- type SetupAppOpts
- type ToolsWrapper
- func (wrapper *ToolsWrapper) AddUIComponent(opts AddUIComponentOpts) error
- func (wrapper *ToolsWrapper) Inform(level inform.Level, message string, noColor ...bool)
- func (wrapper *ToolsWrapper) ListFiles() error
- func (wrapper *ToolsWrapper) ListUiComponents() error
- func (wrapper *ToolsWrapper) MakeController(opts MakeControllerOpts) error
- func (wrapper *ToolsWrapper) MakeMigration(opts MakeMigrationOpts) error
- func (wrapper *ToolsWrapper) MakeModel(opts MakeModelOpts) error
- func (wrapper *ToolsWrapper) MakeRepository(opts MakeRepositoryOpts) error
- func (wrapper *ToolsWrapper) MakeValidator(opts MakeValidatorOpts) error
- func (wrapper *ToolsWrapper) ReadFileContents(opts ReadFileContentsOpts) error
- func (wrapper *ToolsWrapper) SetupApp(opts SetupAppOpts) error
- func (wrapper *ToolsWrapper) WriteContentsToFile(opts WriteContentsToFileOpts) error
- type WriteContentsToFileOpts
Constants ¶
View Source
const ( CAESAR_UI_GITHUB_RAW_BASE_URL = "https://raw.githubusercontent.com/caesar-rocks/ui/master" DEFAULT_CSS_PATH = "./views/app.css" DEFAULT_UI_COMPONENTS_BASE_PATH = "./views/ui" )
View Source
const (
EXCLUDED_PATHS = "node_modules|.git|.idea|vendor|.env|.DS_Store"
)
View Source
const (
REPOSITORIES_BASE_DIR = "./app/repositories"
)
View Source
const (
STARTER_KIT_GITHUB_REPO = "https://github.com/caesar-rocks/starter-kit.git"
)
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AddUIComponentOpts ¶
type AddUIComponentOpts struct {
ComponentName string `description:"The name of the component you want to add to your codebase (lowercase, matching the .templ file name)"`
}
type MakeControllerOpts ¶
type MakeControllerOpts struct {
Input string `description:"The name of the controller to create"`
}
type MakeMigrationOpts ¶
type MakeMigrationOpts struct {
MigrationName string `description:"The name of the migration to create"`
}
type MakeModelOpts ¶
type MakeRepositoryOpts ¶
type MakeRepositoryOpts struct {
ModelName string `description:"The name of the model to create a repository for"`
}
type MakeValidatorOpts ¶
type MakeValidatorOpts struct {
ValidatiorName string `description:"The name of the validator to create"`
}
type ReadFileContentsOpts ¶
type ReadFileContentsOpts struct {
FilePath string `description:"The path to the file whose contents should be read"`
}
type SetupAppOpts ¶
type SetupAppOpts struct {
AppName string `description:"The name of the app you want to create"`
}
type ToolsWrapper ¶
type ToolsWrapper struct {
// contains filtered or unexported fields
}
func NewToolsWrapper ¶
func NewToolsWrapper(w io.Writer) *ToolsWrapper
func (*ToolsWrapper) AddUIComponent ¶
func (wrapper *ToolsWrapper) AddUIComponent(opts AddUIComponentOpts) error
func (*ToolsWrapper) Inform ¶
func (wrapper *ToolsWrapper) Inform(level inform.Level, message string, noColor ...bool)
func (*ToolsWrapper) ListFiles ¶
func (wrapper *ToolsWrapper) ListFiles() error
ListFiles lists all files in the current directory recursively, excluding node_modules.
func (*ToolsWrapper) ListUiComponents ¶
func (wrapper *ToolsWrapper) ListUiComponents() error
func (*ToolsWrapper) MakeController ¶
func (wrapper *ToolsWrapper) MakeController(opts MakeControllerOpts) error
func (*ToolsWrapper) MakeMigration ¶
func (wrapper *ToolsWrapper) MakeMigration(opts MakeMigrationOpts) error
func (*ToolsWrapper) MakeModel ¶
func (wrapper *ToolsWrapper) MakeModel(opts MakeModelOpts) error
func (*ToolsWrapper) MakeRepository ¶
func (wrapper *ToolsWrapper) MakeRepository(opts MakeRepositoryOpts) error
func (*ToolsWrapper) MakeValidator ¶
func (wrapper *ToolsWrapper) MakeValidator(opts MakeValidatorOpts) error
func (*ToolsWrapper) ReadFileContents ¶
func (wrapper *ToolsWrapper) ReadFileContents(opts ReadFileContentsOpts) error
ReadFileContents reads the contents of the specified file and returns them as a string.
func (*ToolsWrapper) SetupApp ¶
func (wrapper *ToolsWrapper) SetupApp(opts SetupAppOpts) error
func (*ToolsWrapper) WriteContentsToFile ¶
func (wrapper *ToolsWrapper) WriteContentsToFile(opts WriteContentsToFileOpts) error
WriteContentsToFile replaces the contents of the specified file with newContents.
type WriteContentsToFileOpts ¶
Click to show internal directories.
Click to hide internal directories.