github.com/titpetric/microservice/cmd/db-schema-cli
No package summary is available.
Package
Files: 4. Third party imports: 4. Imports from organisation: 0. Tests: 0. Benchmarks: 0.
Vars
ColumnFields lists database columns from Column{}
TableFields lists database columns from Table{}
Types
Column
Column is an information_schema record
| Field name | Field type | Comment |
|---|---|---|
| Name |
|
No comment on field. |
| Type |
|
No comment on field. |
| Key |
|
No comment on field. |
| Comment |
|
No comment on field. |
| DataType |
|
Holds the clean data type |
Table
Table is an information_schema record
| Field name | Field type | Comment |
|---|---|---|
| Name |
|
No comment on field. |
| Comment |
|
No comment on field. |
| Columns |
|
No comment on field. |
specialType
This type doesn't have documentation.
| Field name | Field type | Comment |
|---|---|---|
| Import |
|
No comment on field. |
| Type |
|
No comment on field. |
Private functions
func camel
References: snaker.SnakeToCamel.
func contains
func isNumeric
func isSimple
func isSpecial
func main
References: flag.BoolVar, flag.Parse, flag.StringVar, log.Fatal, log.Fatalf, log.Println, sqlx.Connect, strings.Join.
func renderGo
References: bytes.NewBuffer, fmt.Fprintf, fmt.Fprintln, fmt.Println, fmt.Sprintf, format.Source, ioutil.WriteFile, log.Println, os.MkdirAll, path.Join, strings.Contains, strings.Join, strings.Replace, strings.Split, strings.ToLower.
func renderMarkdown
References: fmt.Println, ioutil.WriteFile, os.MkdirAll, path.Join, strings.ToLower.
func renderMarkdownTable
References: bytes.NewBufferString, fmt.Sprintf, strings.Repeat, strings.Replace.
func resolveTypeGo
References: errors.Errorf, strings.Contains, strings.ToLower.