Commit Graph

171 Commits (234b6bc9b8fb4ecdf063e85e8cd84ee68f8a43dc)

Author SHA1 Message Date
Lomanic da12f10f63 Use w32.EnumerateProcesses instead of slower wmi in windows process.Processes()
Lomanic c9a24cf2d0 Handle case in Windows process.Pids() where buffer is too small to handle that many processes returned by w32.EnumProcesses
Lomanic 0314bc81f3 Use w32.EnumProcesses to get pids on Windows in process.Pids()
Sam Kleinman 4d92a03da8 fix cross compiles
tycho garen 08a382b207 make process.processes function public
mlkm b9ab45bcdd Implement Process.Times for Windows
John Liu d28c254aaf Improve performance of finding child processes on Windows
shirou fa0e9fd921 Merge pull request #428 from Leonid99/threads
Implement Threads() in Linux
Leonid Podolny 4269f19b1b process.go: reformat whitespaces to keep gofmt happy
Leonid Podolny 7ee4a4c6ff Fix Threads() signature to better match python original
Leonid Podolny 7ad3836ad3 Implement Threads() for Linux
Kemal Hadimli 826e63acbc Never divide by zero
Kemal Hadimli a3144a6850 Remove parens
Kemal Hadimli 696e1e0123 Fix NaN percentage if process was created too soon
shirou a452de7c73 Merge pull request #346 from phemmer/rlimit-current
add current values to rlimit retrieval
Shirou WAKAYAMA 3aa2ffab12 [process] linux: fix NumFD type inconversion.
Conor Branagan 7b058c7436 Just look at filenames for linux NumFDs call.
In NumFDs we don't care about the contents of the fields, just how many
there are.
WAKAYAMA Shirou 906b00fc23 add features to README. Thank you for all of great contributors!
shirou f6b70e303c Merge pull request #387 from tychoish/windows-data-collection
collect more data on windows
WAKAYAMA Shirou 5329f8ba79 [process] fix Document of CreatTime seconds -> milliseconds
shirou 1da5000996 Merge pull request #402 from chrisroberts/fix-exe-macos
Fix process.Exe() on macOS 10.12
Aditya Choudhary (c) 533161c2ed added funtion for calculation of CPU usage percentage of a process
Chris Roberts 9c998f664a Fix process.Exe() on macOS 10.12
The `lsof` command on macOS < 10.12 always selects the `p` field
when using the `-F` option. On macOS 10.12 the `f` field is also
always selected causing an incorrect result. This modification adds
both options which are always selected to maintain consistency.
Derek Brown a3ae2ed411 Add domain to username (rather than naked username)
tycho garen d522bf5b7e collect more data on windows
Derek Brown 5157f03748 [windows] add implementation for process.Username()
Sean Chittenden cb12fba4f4
windows.Syscall doesn't exist: use syscall.Syscall()
Sean Chittenden 3e79194fe2
windows.EINVAL doesn't exist, only syscall.EINVAL.
Sean Chittenden 635b971c0e
Move from the `syscall` package to the `golang.org/x/sys/{unix,windows}`
Patrick Hemmer 60c32eb847 add current values to rlimit retrieval
Sean Chittenden d0e40ff723
Fix issues reported by golint.
Sean Chittenden 3834908232
Improve Command() handling and signal handling for launched processes.
WAKAYAMA Shirou 30ebb9ca3a rename expected dir to testdata.
tycho garen 22c56d292e close open files
shirou 35c783ec7d Merge pull request #314 from tychoish/fix-ppid-darwin
error earlier on darwin for get parent pid
tycho garen 6110db7ab5 error earlier on darwin for get parent pid
shirou 53c0262e32 Merge pull request #310 from sparrc/go-fmt
run go fmt ./...
Cameron Sparr a213bf5e6d
run go fmt ./...
Sean Chittenden b68f0fdb25
Add native struct support for FreeBSD/arm.
This was ported by hand and not machine generated, but appears to get
software to build.  Material was sourced from the following and a pile
of `grep(1)`:

[1] https://wiki.freebsd.org/EdMaste/ArchitectureSpecifics
[2] https://svnweb.freebsd.org/base/head/sys/sys/user.h?revision=309676&view=markup#l119
Sam Kleinman 488c56586b add platform compatibility
Jorick Caberio c432d48337 fix truncated process name of linux
Vyacheslav Kuznetsov a35c32b028 Commented the constants origin.
Vyacheslav Kuznetsov 4de4e17f06 Added limit constants. Implemented function to parse process limits from /proc.
shirou 93564b3142 Merge pull request #271 from botherder/master
Obtain executable path from macOS process (fix #270)
Marco Pfatschbacher b4846b445b Add support for OpenBSD/amd64
This code is based on the FreeBSD version
and implements roughly the same feature set.
Nex 189b8e6d12 Fixed missing bin and unused stderr
Nex b6a7649aab Error handling
Nex d9b355f75e Added proper piping of commands
Nex dd3cbcc611 Trying remove single quotes
Nex 1534b109ae Fixing pid name