node-dbus-next icon indicating copy to clipboard operation
node-dbus-next copied to clipboard

Generalized fetching of uid and add support for DBUS_UID env var

Open martenjacobs opened this issue 4 years ago • 2 comments

Solves #75

martenjacobs avatar May 12 '21 09:05 martenjacobs

I don't like the idea of an env var. Does process.getuid() not give you the right value?

acrisci avatar May 20 '21 13:05 acrisci

I don't like the idea of an env var. Does process.getuid() not give you the right value?

No it doesn’t, because the process is running under macOS and is connecting to DBus on another machine through TCP. A nicer solution could be to add the uid to the params of the bus constructor. I just choose the env var approach because it was simpler to do.

martenjacobs avatar May 20 '21 13:05 martenjacobs