From 0b41a525f6b1a11f17323ba671f11557bc1731f9 Mon Sep 17 00:00:00 2001 From: Graham King Date: Thu, 25 Jan 2018 11:59:02 -0800 Subject: [PATCH] Documentation: Document passing flags with `--`. (#1096) Document how to pass flags to the cli program being debugged. --- Documentation/cli/getting_started.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Documentation/cli/getting_started.md b/Documentation/cli/getting_started.md index d2a2da1e..23a9d96c 100644 --- a/Documentation/cli/getting_started.md +++ b/Documentation/cli/getting_started.md @@ -27,7 +27,8 @@ For example given this project layout: If you are in the directory `github.com/me/foo/cmd/foo` you can simple run `dlv debug` from the command line. From anywhere else, say the project root, you can simply -provide the package: `dlv debug github.com/me/foo/cmd/foo`. +provide the package: `dlv debug github.com/me/foo/cmd/foo`. To pass flags to your program +separate them with `--`: `dlv debug github.com/me/foo/cmd/foo -- -arg1 value`. Invoking that command will cause Delve to compile the program in a way most suitable for debugging, then it will execute and attach to the program and begin