Skip to content

Commit 6a4c0c5

Browse files
committed
Fixed Go Develop tutorial
1 parent 9e8b4c9 commit 6a4c0c5

File tree

1 file changed

+20
-20
lines changed

1 file changed

+20
-20
lines changed

docs/develop/golang/index-golang.mdx

Lines changed: 20 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -32,26 +32,26 @@ The `redigo` library is located in the `https://github.com/gomodule/redigo` that
3232

3333
### Step 1. Import the `redigo` module
3434

35-
```bash
36-
go get github.com/gomodule/redigo/redis
37-
```
38-
39-
```go
40-
import (
41-
"fmt"
42-
"context"
43-
"github.com/gomodule/redigo/redis"
44-
)
45-
```
35+
```bash
36+
go get github.com/gomodule/redigo/redis
37+
```
38+
39+
```go
40+
import (
41+
"fmt"
42+
"context"
43+
"github.com/gomodule/redigo/redis"
44+
)
45+
```
4646

4747
### Step 2. Create a connection pool
4848

49-
```go
50-
func newPool() *redis.Pool {
51-
return &redis.Pool{
52-
MaxIdle: 80,
53-
MaxActive: 12000,
54-
Dial: func() (redis.Conn, error) {
49+
```go
50+
func newPool() *redis.Pool {
51+
return &redis.Pool{
52+
MaxIdle: 80,
53+
MaxActive: 12000,
54+
Dial: func() (redis.Conn, error) {
5555
c, err := redis.Dial("tcp", ":6379")
5656
if err != nil {
5757
panic(err.Error())
@@ -60,11 +60,11 @@ The `redigo` library is located in the `https://github.com/gomodule/redigo` that
6060
},
6161
}
6262
}
63-
```
63+
```
6464

6565
### Step 3. Write your application code
6666

67-
```go
67+
```go
6868
package main
6969

7070
import (
@@ -123,7 +123,7 @@ The `redigo` library is located in the `https://github.com/gomodule/redigo` that
123123
},
124124
}
125125
}
126-
```
126+
```
127127

128128
Find more information about Golang & Redis connections in the "[Redis Connect](https://github.com/redis-developer/redis-connect/tree/master/golang/redigo)".
129129

0 commit comments

Comments
 (0)