Skip to content

Commit

Permalink
update README.md with a few more descriptions.
Browse files Browse the repository at this point in the history
  • Loading branch information
刘超 committed Oct 8, 2019
1 parent b9ad15f commit 8f7e71b
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 1 deletion.
12 changes: 12 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,17 @@
## GPA: yet another Golang Persistence API

### Installation

```bash
go get github.com/liupangzi/gpa
```

### Document

#### 1. .sql to Go struct

`gpa mysql model -h` can translate mysql ddl file to Go struct respecting the data alignment, e.g.:

- .sql ddl file
![sql](./docs/images/sql.png "ddl")

Expand All @@ -10,6 +20,8 @@

#### 2. Interface to Implementation

`gpa mysql impl -h` will generate Go implementations from pre-defined interface based on [sqlx](https://github.com/jmoiron/sqlx), e.g.:

- Golang interface with annotations
![interface](./docs/images/interface.png "Golang interface with annotations")

Expand Down
2 changes: 1 addition & 1 deletion cmd/root.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ var RootCmd = &cobra.Command{
Use: "gpa",
Short: "Golang Persistence API",
Long: "Golang programming interface that describes the management of MySQL data in applications.",
Version: "0.1.0",
Version: "v1.0.2",
}

func init() {
Expand Down

0 comments on commit 8f7e71b

Please sign in to comment.