-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
3 changed files
with
6 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -9,13 +9,13 @@ A command-line tool to generate constructor code for a struct. It don't need man | |
It don't need a manual installation. Just add this comment line to the struct you want to generate a constructor. | ||
|
||
```go | ||
//go:generate go run github.com/Bin-Huang/[email protected].0 | ||
//go:generate go run github.com/Bin-Huang/[email protected].1 | ||
``` | ||
|
||
For example: | ||
|
||
```go | ||
//go:generate go run github.com/Bin-Huang/[email protected].0 | ||
//go:generate go run github.com/Bin-Huang/[email protected].1 | ||
type UserService struct { | ||
baseService | ||
userRepository *repositories.UserRepository | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -11,13 +11,13 @@ Doc: [English](README.md) | **中文** | |
它的使用方式非常简单,不用专门手动安装,只需要在结构体添加下面这行代码注释就能工作。 | ||
|
||
```go | ||
//go:generate go run github.com/Bin-Huang/[email protected].0 | ||
//go:generate go run github.com/Bin-Huang/[email protected].1 | ||
``` | ||
|
||
举个例子: | ||
|
||
```go | ||
//go:generate go run github.com/Bin-Huang/[email protected].0 | ||
//go:generate go run github.com/Bin-Huang/[email protected].1 | ||
type UserService struct { | ||
baseService | ||
userRepository *repositories.UserRepository | ||
|
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.