add correct example for pg's url (#857)
This commit is contained in:
@@ -456,7 +456,7 @@ var (
|
|||||||
Flags: []cli.Flag{
|
Flags: []cli.Flag{
|
||||||
cli.StringFlag{
|
cli.StringFlag{
|
||||||
Name: "url",
|
Name: "url",
|
||||||
Usage: `the data source of database,like "root:password@tcp(127.0.0.1:3306)/database`,
|
Usage: `the data source of database,like "root:password@tcp(127.0.0.1:3306)/database"`,
|
||||||
},
|
},
|
||||||
cli.StringFlag{
|
cli.StringFlag{
|
||||||
Name: "table, t",
|
Name: "table, t",
|
||||||
@@ -497,7 +497,7 @@ var (
|
|||||||
Flags: []cli.Flag{
|
Flags: []cli.Flag{
|
||||||
cli.StringFlag{
|
cli.StringFlag{
|
||||||
Name: "url",
|
Name: "url",
|
||||||
Usage: `the data source of database,like "root:password@tcp(127.0.0.1:3306)/database`,
|
Usage: `the data source of database,like "postgres://root:password@127.0.0.1:54332/database?sslmode=disable"`,
|
||||||
},
|
},
|
||||||
cli.StringFlag{
|
cli.StringFlag{
|
||||||
Name: "table, t",
|
Name: "table, t",
|
||||||
|
|||||||
@@ -199,7 +199,7 @@ func fromMysqlDataSource(url, pattern, dir string, cfg *config.Config, cache, id
|
|||||||
func fromPostgreSqlDataSource(url, pattern, dir, schema string, cfg *config.Config, cache, idea bool) error {
|
func fromPostgreSqlDataSource(url, pattern, dir, schema string, cfg *config.Config, cache, idea bool) error {
|
||||||
log := console.NewConsole(idea)
|
log := console.NewConsole(idea)
|
||||||
if len(url) == 0 {
|
if len(url) == 0 {
|
||||||
log.Error("%v", "expected data source of mysql, but nothing found")
|
log.Error("%v", "expected data source of postgresql, but nothing found")
|
||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user