launchctl export missing on 10.14.6

I use the "launchctl setenv" command to set shell environment variables used by launchd launch daemons.


The man pages "man launchctl" say that "launchctl export" will show all variables used by launchd:

export Export all of the environment variables of launchd for use in a

shell eval statement.


But "sudo launchctl export" throws an error":

Unrecognized subcommand: export


What commnd shows all shell environment variables set and used by launchd launch daemonds?


This is on macOS 10.14.6.

Replies

Couldn't you just create a little test task that runs "env"?

The

export
subcommand hasn’t been supported since the introduction of
launchd
2 in 10.10. I’d appreciate you filing a bug against the man page for it continuing to mention it. Please post your bug number, just for the record.

Share and Enjoy

Quinn “The Eskimo!”
Apple Developer Relations, Developer Technical Support, Core OS/Hardware

let myEmail = "eskimo" + "1" + "@apple.com"