On +2022-06-27 13:23:15 +0200, b...@bokr.com wrote: > > > If this is all about capturing an environment as text, > how about > > --8<---------------cut here---------------start------------->8--- > xargs -0 < /proc/$$/environ > --8<---------------cut here---------------end--------------->8--- > > [...] > Actually, why fight shell stuff when guile can read it? Or are these modules not available in your context? --8<---------------cut here---------------start------------->8--- scheme@(guile-user)> (use-modules (ice-9 textual-ports)) scheme@(guile-user)> (define ep (open-input-file "/proc/12430/environ")) scheme@(guile-user)> (define es (get-string-all ep)) --8<---------------cut here---------------end--------------->8--- es from above got it all, when I tried manually as above.
FWIW I also did the same with (use-modules (rnrs bytevectors)) and the nulls show up as the expected zeroes. -- Regards, Bengt Richter