Customizable templates generator, inspired by Rails
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
.scaffold
app
domain
infra
.gitignore
.travis.yml
Gopkg.lock
Gopkg.toml
LICENSE
Makefile
README.md
cli.go
cli_test.go
main.go

README.md

scaffold

Build Status Coverage Status MIT License Version

https://gyazo.com/756d165b512a3d93c08e2094eedecd86

Usage

Example

.scaffold

$ tree .scaffold
.scaffold
├── command
│   ├── app
│   │   └── cmd
│   │       ├── {{name}}.go
│   │       └── {{name}}_test.go
│   └── meta.toml
└── usecase
    ├── app
    │   └── usecase
    │       ├── {{name}}.go
    │       └── {{name}}_test.go
    └── meta.toml

$ scaffold g command destroy
       exist  .
       exist  app/cmd
      create  app/cmd/destroy.go
      create  app/cmd/destroy_test.go

$ ls app/cmd/destroy*
app/cmd/destroy.go
app/cmd/destroy_test.go

Available filters

  • toUpper
  • toLower
  • camelizer
  • pascalize
  • underscore
  • dasherize

Installation

macOS

Homebrew formula is available at izumin5210/homebrew-tools

$ brew install izumin5210/tools/scaffold

Other platforms

Prebuilt binary is available at Releases

Development

# install dependencies
$ make deps

# build
$ make build

# run lint and test
$ make test

License

Licensed under MIT License.