shirou / gopsutil

psutil for golang
Other
10.28k stars 1.56k forks source link

Get current working directory on openbsd #1648

Closed mikygee closed 1 month ago

mikygee commented 1 month ago

Hello,

I opened a request on Stork another opensource project and the developper tells me this "Stork uses the shirou/gopsutil library to read the process details. Unfortunately, it doesn't fully support OpenBSD."

The initial problem is described here https://gitlab.isc.org/isc-projects/stork/-/issues/1382#note_458694

The stork developper points line 70 here https://github.com/shirou/gopsutil/blob/4be51ffb01ed5c28a085a013b42d518b145e8ee0/process/process_openbsd.go#L70

Actually, Openbsd doesn't support cwd, it supports pwd.

Thank you

mikygee commented 1 month ago

Hello,

Have you been able to test the solution on openbsd ?

I have modified the files on my system locally but I don't get it working. But I'm not so familiar with Go, so it might be me.

Thank you for this push.

shirou commented 1 month ago

Your question is regarding PR #1649, right? As I mentioned in that PR, it worked at least in my environment (OpenBSD 7.5 on VirtualBox).

mikygee commented 1 month ago

Hello, Thank you very much for your feedback.