ReproNim / reproman

ReproMan (AKA NICEMAN, AKA ReproNim TRD3)
https://reproman.readthedocs.io
Other
24 stars 14 forks source link

env -0 not supported on macOS #501

Closed chaselgrove closed 4 years ago

chaselgrove commented 4 years ago

reproman/resource/session.py uses env -0 to get the environment, but -0 is not a supported option to env on macOS.

yarikoptic commented 4 years ago

my workaround idea was to dump + parse /proc/PID/environ - but it seems there is no /proc on osx (mach), so would be only linux specific

yarikoptic commented 4 years ago

@kyleam : perl -e "print %ENV"

kyleam commented 4 years ago

@chaselgrove and I discussed this a bit on the call. A couple of points:

Anyway, here are my two snippets to imitate env -0:

yarikoptic commented 4 years ago

perl is the winner! ;-) @chaselgrove please run perl version if env -0 fails