Skip to content

Commit

Permalink
Merge pull request #124 from ichiban/remove-pflag
Browse files Browse the repository at this point in the history
remove github.com/spf13/pflag
  • Loading branch information
ichiban authored Dec 14, 2021
2 parents 929e3f5 + 62fabe7 commit a81e15f
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 7 deletions.
8 changes: 4 additions & 4 deletions cmd/1pl/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ import (
"bufio"
"context"
"errors"
"flag"
"fmt"
"io"
"io/ioutil"
Expand All @@ -12,7 +13,6 @@ import (
"os/signal"
"strings"

"github.com/spf13/pflag"
"golang.org/x/crypto/ssh/terminal"

"github.com/ichiban/prolog"
Expand All @@ -25,8 +25,8 @@ var Version = "1pl/0.1"

func main() {
var verbose bool
pflag.BoolVarP(&verbose, "verbose", "v", false, `verbose`)
pflag.Parse()
flag.BoolVar(&verbose, "v", false, `verbose`)
flag.Parse()

oldState, err := terminal.MakeRaw(0)
if err != nil {
Expand Down Expand Up @@ -99,7 +99,7 @@ func main() {
return k(env)
})

for _, a := range pflag.Args() {
for _, a := range flag.Args() {
b, err := ioutil.ReadFile(a)
if err != nil {
log.Panicf("failed to read %s: %v", a, err)
Expand Down
1 change: 0 additions & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@ go 1.16
require (
github.com/davecgh/go-spew v1.1.1 // indirect
github.com/kr/pretty v0.1.0 // indirect
github.com/spf13/pflag v1.0.5
github.com/stretchr/objx v0.1.1 // indirect
github.com/stretchr/testify v1.7.0
golang.org/x/crypto v0.0.0-20201016220609-9e8e0b390897
Expand Down
2 changes: 0 additions & 2 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,6 @@ github.com/kr/text v0.1.0 h1:45sCR5RtlFHMR4UwH9sdQ5TC8v0qDQCHnXt+kaKSTVE=
github.com/kr/text v0.1.0/go.mod h1:4Jbv+DJW3UT/LiOwJeYQe1efqtUx/iVham/4vfdArNI=
github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM=
github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4=
github.com/spf13/pflag v1.0.5 h1:iy+VFUOCP1a+8yFto/drg2CJ5u0yRoB7fZw3DKv/JXA=
github.com/spf13/pflag v1.0.5/go.mod h1:McXfInJRrz4CZXVZOBLb0bTZqETkiAhM9Iw0y3An2Bg=
github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME=
github.com/stretchr/objx v0.1.1 h1:2vfRuCMp5sSVIDSqO8oNnWJq7mPa6KVP3iPIwFBuy8A=
github.com/stretchr/objx v0.1.1/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME=
Expand Down

0 comments on commit a81e15f

Please sign in to comment.