Skip to content

Commit

Permalink
Move example program into examples folder
Browse files Browse the repository at this point in the history
Signed-off-by: hwipl <[email protected]>
  • Loading branch information
hwipl committed Jul 21, 2022
1 parent 2c450c3 commit c8ba407
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 12 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,5 +36,5 @@ func main() {
}
```

See [internal/cmd/cmd.go](internal/cmd/cmd.go) and
See [examples/tnd/main.go](examples/tnd/main.go) and
[scripts/tnd.sh](scripts/tnd.sh) for a complete example.
7 changes: 0 additions & 7 deletions cmd/tnd/main.go

This file was deleted.

5 changes: 2 additions & 3 deletions internal/cmd/cmd.go → examples/tnd/main.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package cmd
package main

import (
"flag"
Expand Down Expand Up @@ -36,8 +36,7 @@ func parseCommandLine() {
}
}

// Run is the main entry point
func Run() {
func main() {
// set log level
log.SetLevel(log.DebugLevel)

Expand Down
2 changes: 1 addition & 1 deletion scripts/tnd.sh
Original file line number Diff line number Diff line change
Expand Up @@ -12,5 +12,5 @@ HTTP2="https://your.second.trusted.http.server.com:443"
HASH2="SHA256 hash of HTTP2"
SERV2="$HTTP2:$HASH2"

go run ./cmd/tnd \
go run ./examples/tnd \
-httpsservers "$SERV1,$SERV2"

0 comments on commit c8ba407

Please sign in to comment.