go-dlv-manager

command module
v0.0.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 14, 2022 License: MIT Imports: 8 Imported by: 0

README

go-dlv-manager

go-delve DAP remote debugger process manager

Make sure that you have same file path or it wont debug/compile.

You can use rsync, or similar software.

Install

go install github.com/go-delve/delve/cmd/dlv@latest
go install github.com/ii64/go-dlv-manager@latest

Example

File launch.json

{
    "configurations": [
    {
        "name": "Launch file",
        "type": "go",
        "request": "launch",
        "mode": "exec",        // exec, debug, see more at `dlv dap --help`
        "program": "${file}",
        "showRegisters": true,  // unecessary
        "logOutput": "rpc",     // unecessary
        "port": 7456,
        "host": "127.0.0.1"
    }
    ]
}

File .dlvman.toml

[conf]
  Addr = "0.0.0.0:7456"
  Program = "dlv"
  ProcessArgs = ["dap", "--check-go-version=false", "--log-dest=3"]
  Debug = false

Figure

Both running on the same computer, arm64 running on top of QEMU emulation. It took some time to build the program inside the emulator, but this can be avoided by compiling it on the host machine.

GOARCH=arm64 go build -gcflags "all=-N -l" main.go

On launch.json, you just need to change these line:

    "mode": "exec",
    "program": "${workspaceFolder}/main",
amd64 arm64 (Cortex-A53)
amd64 arm64

License

The go-dlv-manager is under the MIT license.

Documentation

The Go Gopher

There is no documentation for this package.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL