File tree 4 files changed +27
-6
lines changed
4 files changed +27
-6
lines changed Original file line number Diff line number Diff line change @@ -31,7 +31,7 @@ ignored = ["github.com/Azure/go-ansiterm*"]
31
31
32
32
[[constraint ]]
33
33
name = " github.com/fnproject/fn_go"
34
- version = " 0.2.11 "
34
+ version = " 0.2.12 "
35
35
36
36
[[constraint ]]
37
37
name = " github.com/giantswarm/semver-bump"
Original file line number Diff line number Diff line change @@ -2,8 +2,11 @@ package main
2
2
3
3
import (
4
4
"bytes"
5
+ "crypto/rand"
6
+ "encoding/base32"
5
7
"fmt"
6
8
"io"
9
+ "log"
7
10
"os"
8
11
"sort"
9
12
"strings"
@@ -18,6 +21,16 @@ import (
18
21
"github.com/urfave/cli"
19
22
)
20
23
24
+ func getRequestID () string {
25
+ byteArr := make ([]byte , 16 )
26
+ _ , err := rand .Read (byteArr )
27
+ if err != nil {
28
+ log .Fatalf ("failed to generate random number for requestID" )
29
+ }
30
+
31
+ return base32 .StdEncoding .WithPadding (base32 .NoPadding ).EncodeToString (byteArr )
32
+ }
33
+
21
34
func newFn () * cli.App {
22
35
app := cli .NewApp ()
23
36
app .Name = "fn"
@@ -30,7 +43,6 @@ func newFn() *cli.App {
30
43
if err != nil {
31
44
return err
32
45
}
33
-
34
46
viper .Set (common .RequestID , common .GetRequestID ())
35
47
commandArgOverrides (c )
36
48
return nil
Original file line number Diff line number Diff line change @@ -12,7 +12,7 @@ import (
12
12
13
13
"github.com/fnproject/cli/client"
14
14
"github.com/fnproject/cli/common"
15
- fnclient "github.com/fnproject/fn_go/client"
15
+ fnclient "github.com/fnproject/fn_go/client"
16
16
apiapps "github.com/fnproject/fn_go/client/apps"
17
17
"github.com/fnproject/fn_go/models"
18
18
"github.com/fnproject/fn_go/provider"
You can’t perform that action at this time.
0 commit comments