aboutsummaryrefslogtreecommitdiffstats
path: root/main.go
diff options
context:
space:
mode:
Diffstat (limited to 'main.go')
-rw-r--r--main.go5
1 files changed, 5 insertions, 0 deletions
diff --git a/main.go b/main.go
index 29693eb..f21de41 100644
--- a/main.go
+++ b/main.go
@@ -74,6 +74,11 @@ func warning() {
}
func main() {
+ if len(os.Args) == 2 && os.Args[1] == "--version" {
+ fmt.Printf("wireguard-go v%s\n\nUserspace WireGuard daemon for %s-%s.\nInformation available at https://www.wireguard.com.\nCopyright (C) Jason A. Donenfeld <Jason@zx2c4.com>.\n", WireGuardGoVersion, runtime.GOOS, runtime.GOARCH)
+ return
+ }
+
warning()
// parse arguments